Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Sep 2016 13:01:26 +0300
From:      Andriy Gapon <avg@FreeBSD.org>
To:        John Baldwin <jhb@FreeBSD.org>
Cc:        freebsd-hackers <freebsd-hackers@FreeBSD.org>, FreeBSD Current <freebsd-current@FreeBSD.org>
Subject:   Re: kldload intpm
Message-ID:  <8bb32155-0365-bcd4-d487-b1932b34fb6f@FreeBSD.org>
In-Reply-To: <16067820.jTuOsBSZ6N@ralph.baldwin.cx>
References:  <9db20b27-254f-b0a5-8f6c-f1eeaadf7829@FreeBSD.org> <16067820.jTuOsBSZ6N@ralph.baldwin.cx>

next in thread | previous in thread | raw e-mail | index | archive | help
On 07/09/2016 20:49, John Baldwin wrote:
> You can request a specific ordering via DRIVER_MODULE_ORDERED (you can specify the
> SI_ORDER to use as an extra argument).  The typical practice is to load the "base"
> driver (the one that attaches highest up the device hierarchy) "last" so that all
> other drivers are registered once it tries to attach.  For example, in xl(4) this
> is used to to have the PCI attachment register last so that the miibus driver is
> registered when xl0 attaches:
> 
> DRIVER_MODULE_ORDERED(xl, pci, xl_driver, xl_devclass, NULL, NULL,
>     SI_ORDER_ANY);
> DRIVER_MODULE(miibus, xl, miibus_driver, miibus_devclass, NULL, NULL);
> 
> DRIVER_MODULE() uses SI_ORDER_MIDDLE by default.
> 
> This probably needs to be fixed in all of the smbus controller drivers.

Thank you for the advice.
I'm going to fix intpm.

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8bb32155-0365-bcd4-d487-b1932b34fb6f>