I'm trying to read one of the PIT (Perioditic Interrupt Timers) registers. For now, I don't really care which one I just want to run a test read from a Linux module. I've tried two methods:
unsigned int PIT_MCR = 0;
//PIT_MCR = *((unsigned int *)(void *)(0x40037000));
PIT_MCR = __raw_readl(0x40037000);
printk("PIT_MCR(0x4003_7000): %u\n", PIT_MCR);
Both of these attempts to access the register fail in the same way. An "Oops" message stating the memory can't be reached:
"Unable to handle kernel paging request at virtual address 40037000"
Is there anything special that has to be done in order to access/read from these registers?