- const int addrsize = (mmiobase>>1) & 3;
- if( addrsize == 0 ) {
- // Standard 32-bit
- card->MMIOBasePhys = mmiobase & ~0xF;
- }
- else if( addrsize == 2 ) {
- // 64-bit
- card->MMIOBasePhys = (mmiobase & ~0xF) | ((Uint64)PCI_GetBAR(id, 1)<<32);
- }
- else {
- Log_Warning("E1000", "Dev %i: Unknown memory address size %i", id, (mmiobase>>1)&3);
- continue;
- }