Work on debuging, some cleanup in kernel.