On Mon, 2005-12-12 at 17:04 +0300, Gleb Smirnoff wrote: > On Sun, Dec 11, 2005 at 06:22:40PM +0000, Gavin Atkinson wrote: > G> I'm trying to use puc(4) under RELENG_6 to attach the two serial ports on > G> a PCI card I have, but it's not working. It also fails under 6.0-RELEASE, > G> I don't have the ability to test earlier versions. > G> > G> The card is developed, but as far as I can see, no attempt is made to > G> attach the sio(4) devices below it. > G> > G> puc0: <Dolphin Peripherals 4036> port 0x18c0-0x18df irq 25 at device 9.0 on > G> pci0 > G> puc0: Reserved 0x20 bytes for rid 0x10 type 4 at 0x18c0 > G> port rid 16 bst 0, start 18c0, end 18df > G> puc0: i 0, type sio, ressz 8, type 1 > G> puc: Using sio2 > G> puc: type 1, bar 10, offset 0 > G> puc0: i 1, type sio, ressz 8, type 1 > G> puc: Using sio3 > G> puc: type 1, bar 10, offset 8 > G> > G> Adding some printfs to the code, it turns out that device_probe_and_attach > G> around line 375 of sys/dev/puc/puc.c is returning 6. > G> > G> I have also added printfs to the probe and attach code of both the pci and > G> puc attachments of sio(4), and have determined that none of them get > G> called. > G> > G> How can I further diagnose why this card is not getting recognised? > > Afaik, you need 'device uart', that will attach to your pucs. No, as far as I can tell, it's sio that should be attaching. I've loaded the uart module anyway and it still fails. With BUS_DEBUG defined, I see the following: devclass_find_internal:761: looking for puc devclass_add_device:1356: (null) in devclass puc devclass_alloc_unit:1289: unit -1 in devclass puc devclass_alloc_unit:1329: now: unit 0 in devclass puc puc0: <Dolphin Peripherals 4036> port 0x18c0-0x18df irq 25 at device 9.0 on pci0 puc0: Reserved 0x20 bytes for rid 0x10 type 4 at 0x18c0 port rid 16 bst 0, start 18c0, end 18df puc0: i 0, type sio, ressz 8, type 1 devclass_find_internal:761: looking for sio puc: Using sio2 device_add_child_ordered:1542: sio at puc with order 0 as unit 2 make_device:1427: sio at puc as unit 2 devclass_find_internal:761: looking for sio devclass_add_device:1356: (null) in devclass sio devclass_alloc_unit:1289: unit 2 in devclass sio devclass_alloc_unit:1329: now: unit 2 in devclass sio puc: type 1, bar 10, offset 0 devclass_find_driver_internal:1019: sio in devclass puc devclass_find_driver_internal:1026: not found puc0: i 1, type sio, ressz 8, type 1 devclass_find_internal:761: looking for sio puc: Using sio3 device_add_child_ordered:1542: sio at puc with order 0 as unit 3 make_device:1427: sio at puc as unit 3 devclass_find_internal:761: looking for sio devclass_add_device:1356: (null) in devclass sio devclass_alloc_unit:1289: unit 3 in devclass sio devclass_alloc_unit:1329: now: unit 3 in devclass sio puc: type 1, bar 10, offset 8 devclass_find_driver_internal:1019: sio in devclass puc devclass_find_driver_internal:1026: not found I'm sure somebody with more newbus knowledge will know exactly what that means... Are we somehow missing a devclass_add_driver(9) call from the puc initialisation? I'm almost at the point now where I can't understand how it could possibly be working for anyone else. GavinReceived on Tue Dec 13 2005 - 12:39:00 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:49 UTC