These bars are meant to be used for MMIO, so they should return void *.
Not sure why this was closed. This is an actual problem on 64-bit if an MMIO base address is returned that is greater than 4GB.
Suggest having this and related APIs return a uintptr_t since it is a physical address that will need to be mapped in the MMU.
I don't remember who fixed this but it returns a uintptr_t now, closing
Most helpful comment
Suggest having this and related APIs return a uintptr_t since it is a physical address that will need to be mapped in the MMU.