kthread: bring in some hammerhead code