fwohci: report whether PhysicalUpperBound register is implemented
Please see section 5.15 of 1394 OHCI Specification. If the register is not implemented, then the physical response unit is limited to the first 4GB of the physical memory. In that case the non-cooperative debugging over firewire (using /dev/fwmem) can not be expected to work if a target has more RAM than that. The method is described in gdb.4 and the Developer's Handbook. It seems that most of the consumer hardware does not implement PhysicalUpperBound register. MFC after: 1 week
This commit is contained in:
parent
ae71125978
commit
be16523288
@ -1860,6 +1860,16 @@ fwohci_intr_core(struct fwohci_softc *sc, uint32_t stat, int count)
|
||||
prequpper = OHCI_PREQUPPER_MAX;
|
||||
}
|
||||
OWRITE(sc, OHCI_PREQUPPER, prequpper & 0xffffffff);
|
||||
if (OREAD(sc, OHCI_PREQUPPER) !=
|
||||
(prequpper & 0xffffffff)) {
|
||||
device_printf(fc->dev,
|
||||
"PhysicalUpperBound register is not "
|
||||
"implemented. Physical memory access "
|
||||
"is limited to the first 4GB\n");
|
||||
device_printf(fc->dev,
|
||||
"PhysicalUpperBound = 0x%08x\n",
|
||||
OREAD(sc, OHCI_PREQUPPER));
|
||||
}
|
||||
}
|
||||
/* Set ATRetries register */
|
||||
OWRITE(sc, OHCI_ATRETRY, 1<<(13 + 16) | 0xfff);
|
||||
|
Loading…
x
Reference in New Issue
Block a user