huge overall kernel cleanup