Refactoring hw init macros
kmalloc added