HomeFreeBSD

LinuxKPI: pci.h MODULE_DEVICE_TABLE to MODULE_PNP_INFO

Description

LinuxKPI: pci.h MODULE_DEVICE_TABLE to MODULE_PNP_INFO

Implement MODULE_PNP_INFO() support in LinuxKPI for the Linux
MODULE_DEVICE_TABLE.

This will allow us to auto-load LinuxKPI PCI drivers (drm-kmod do
not currently as they attach to vgapci0 which in turn grabs the PCI
to my understanding) and make any loading from loader or kld_list in
rc.conf unnecessary; see devmatch(8) for more information.

We need to ensure there is a DRIVER_MODULE() (or probably just
a DECLARE_MODULE but that makes not much difference) before the
MODULE_PNP_INFO (which we otherwise would not need).

Approved by: re (gjb)
Sponsored by: The FreeBSD Foundation
Reviewed by: imp, hselasky, manu
Differential Revision: https://reviews.freebsd.org/D26651

(cherry picked from commit 5493c6277a264e91ea4bdc7e2d4ee69fe4210918)
(cherry picked from commit a94b233d5d718258e2e57e114aab00714441a79f)

Details

Provenance
bzAuthored on Mar 4 2022, 12:06 AM
Reviewer
imp
Differential Revision
D26651: linuxkpi: MODULE_DEVICE_TABLE to MODULE_PNP_INFO
Parents
rG3b4a991fa67f: iwlwifi: adjust the LinuxKPI pci return for now
Branches
Unknown
Tags
Unknown