Headers

I've split up the patches. This is the headers part only. Will post interrupt stuff next week.