More tweaks for kernel 3.x support