mirror of
https://github.com/akuker/RASCSI.git
synced 2024-06-02 11:41:34 +00:00
parent
31156d1a23
commit
c342c01da9
|
@ -144,6 +144,23 @@ uint32_t SBC_Version::GetPeripheralAddress(void)
|
||||||
|
|
||||||
return address;
|
return address;
|
||||||
}
|
}
|
||||||
|
#elif defined __NetBSD__
|
||||||
|
uint32_t SBC_Version::GetPeripheralAddress(void)
|
||||||
|
{
|
||||||
|
char buf[1024];
|
||||||
|
size_t len = sizeof(buf);
|
||||||
|
uint32_t address;
|
||||||
|
|
||||||
|
if (sysctlbyname("hw.model", buf, &len, NULL, 0) || strstr(buf, "ARM1176JZ-S") != buf) {
|
||||||
|
// Failed to get CPU model || Not BCM2835
|
||||||
|
// use the address of BCM283[67]
|
||||||
|
address = 0x3f000000;
|
||||||
|
} else {
|
||||||
|
// Use BCM2835 address
|
||||||
|
address = 0x20000000;
|
||||||
|
}
|
||||||
|
return address;
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
uint32_t SBC_Version::GetPeripheralAddress(void)
|
uint32_t SBC_Version::GetPeripheralAddress(void)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user