Date: Tue, 13 Jun 2000 12:41:36 -0600 From: Warner Losh <imp@village.org> To: Terry Lambert <tlambert@primenet.com> Cc: mjacob@feral.com, arch@FreeBSD.ORG Subject: Re: cvs commit: src/sys/pci pci.c pcisupport.c pcivar.h Message-ID: <200006131841.MAA16197@harmony.village.org> In-Reply-To: Your message of "Tue, 13 Jun 2000 16:42:15 -0000." <200006131642.JAA08631@usr05.primenet.com> References: <200006131642.JAA08631@usr05.primenet.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <200006131642.JAA08631@usr05.primenet.com> Terry Lambert writes: : This is not the case for SBUS or PCI hardware, which can be data : driven using a table. I think that the active probe case still : needs to be dealt with. The trouble is generating this table. Right now none of the busses have any concept of a table driven approach to plug and play. That has all been moved down into the drivers' probe routines. And some of our probe routines will attach to generic things rather than to things with a certain ID (eg, the serial driver for pci should attach to all communication devices that are serial 16550 compatible). In pccard land, we ant all modems to attach to sio and all fixed disk to attach to ata. In the pccard world things also get complicated by the fact that there are multi-function cards that need some special help as well. These wrinkles make having a single table format for all busses difficult, and may make having some bus tables fairly complex. :-(. : Windows 95/98/2000/NT handle this by paging in the probe code, : running it, and if it probes true, paging in the driver and doing : the attach. The probe code is then discarded. : : Each severable section is in a seperate ELF section, on a 4k page : boundary (logical, not physical, in the ELF file). I like this idea. Too bad we don't have pagable kernel driver support (hint hint). The next best thign would be to load the driver, call its probe routines and then unload it if it didn't attach to anything. You'd want to do this in a lazy way. Load the driver while probing the bus if all drivers currently loaded reject the device as well as deferring unload until all devices on the bus have been probed so that you don't thrash on startup. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200006131841.MAA16197>