Fix some warnings.
Fixed crash on kernel start.