Fix some kernel problems