Query on hardware register initialization by Bootloader and Kernel

view story

http://stackoverflow.com – Can someone clarify when and who does the hardware register initialization? I am currently working on u-boot in an embedded project and in u-boot i see that many hardware registers are being initialized. I thought that Bootloader initializes all the hardware registers and the kernel provides drivers to drive the hardware. But one of the test cases says that "Check that the value of the register set in the kernel is set correctly". Now I am confused whether Kernel also sets these registers again once the kernel is starting up. I do not have a clear picture on what happens once the device starts (HowTos)