debug device added
chip drivers/generic/debug device pnp 0.0 on end end
debug device will be sibling to PCI_DOMAIN and APIC_CLUSTER...
YH
CVS: ---------------------------------------------------------------------- CVS: Enter Log. Lines beginning with `CVS:' are removed automatically CVS: CVS: Committing in . CVS: CVS: Modified Files: CVS: src/mainboard/tyan/s2735/mainboard.c CVS: src/mainboard/tyan/s2850/mainboard.c CVS: src/mainboard/tyan/s2875/mainboard.c CVS: src/mainboard/tyan/s2880/mainboard.c CVS: src/mainboard/tyan/s2881/mainboard.c CVS: src/mainboard/tyan/s2882/mainboard.c CVS: src/mainboard/tyan/s2885/Config.lb CVS: src/mainboard/tyan/s2885/mainboard.c CVS: src/mainboard/tyan/s4880/mainboard.c CVS: src/mainboard/tyan/s4882/mainboard.c CVS: Added Files: CVS: src/drivers/generic/debug/Config.lb CVS: src/drivers/generic/debug/chip.h CVS: src/drivers/generic/debug/debug_dev.c CVS: ----------------------------------------------------------------------
-----Original Message----- From: Li-Ta Lo [mailto:ollie@lanl.gov] Sent: Thursday, November 04, 2004 1:35 PM To: YhLu Cc: LinuxBIOS Subject: RE: Removing device driver code in mainboard.c for Tyan boards?
On Thu, 2004-11-04 at 14:22, YhLu wrote:
I want to print PCI regs after PCI device initialization.
Where need to put the calling print_pci_regs_all? In hardwaremain ???
Why don't you put the debug device into device/generic/debug ? And in the mainboard Config.lb you added
chip device/generic/debug
as the last chip. The device emuleration will call the methods of the debug device last. And you probably can dump PCI CS registers in different stages of the enumeration.
Ollie
On Thu, 2004-11-04 at 15:44, YhLu wrote:
debug device added
chip drivers/generic/debug device pnp 0.0 on end end
debug device will be sibling to PCI_DOMAIN and APIC_CLUSTER...
Cool, that is exactly what I want. Actually by defining different debug devices, we can construct different 'probes' into the device space. We can either probe software data structures or the real hardware and we can do it at different phases of the device enumeration as we want. For example, the current debug device (pnp 0.0) dumps the PCI CS registers at the end of device enumeration. We can define another debug device to show the topology of the device tree or just print the famous .name field ;-).
The best thing about the debug device is it totally extensible and plug/unplugable. We don't have to add any code to the existing device driver nor the hardwaremain(). It is decoupled from the rest of LinuxBIOS. The operations we need to act on the (normal) devices are encapsulated in the debug device.
Ollie