Move board specific parts in board_$NAME.c/h for a little abstraction and less ifdef handling in common code.