cvs commit: src/sys/i386/i386 bios.c
M. Warner Losh
imp at bsdimp.com
Thu Jun 17 12:28:09 PDT 2004
In message: <200406171247.04461.jhb at FreeBSD.org>
John Baldwin <jhb at FreeBSD.org> writes:
: On Tuesday 15 June 2004 11:02 pm, M. Warner Losh wrote:
: > In message: <200406152008.50656.jhb at FreeBSD.org>
: > John Baldwin <jhb at freebsd.org> writes:
: > : On Monday 14 June 2004 10:12 pm, Nate Lawson wrote:
: > : > njl 2004-06-15 02:12:12 UTC
: > : >
: > : > FreeBSD src repository
: > : >
: > : > Modified files:
: > : > sys/i386/i386 bios.c
: > : > Log:
: > : > We only need the devclass_find() result, not the softc.
: > :
: > : The devclass still exists if there is no acpi0 device due to 'set
: > : hint.acpi.0.disabled=1'. Perhaps devclass_get_device() is more
: > : appropriate than devclass_get_softc() though.
: > The hint is insufficient to create the devclass, I believe. It exists
: > because there's a node in the tree or could be a node in the tree.
: > devclass_get_device() and checking to see if it is attached might be
: > even better.
: The devclass exists even if there is no acpi0 device is my point. If acpi.ko
: is loaded or compiled into the kernel, then the driver is going to be loaded
: and the devclass added to the kernel's list.
I think we're saying basically the same thing and arguing over how it
gets there :-)
Fetching the softc likely isn't the right answer.
device_is_attached(dev) is likely a better way to go.
More information about the cvs-all