HomeFreeBSD

mii: include missing sources in loadable module

Description

mii: include missing sources in loadable module

As of today, using 'kldload miibus' is not equivalent to using 'device
miibus' in a kernel config. Newly introduced PHY drivers (DP83822,
DP83867, VSCPHY) and source files/PHY driver for FDT-enabled kernels
are missing. Without including them, kernel modules using any function
from dev/mii/mii_fdt.c refuse to load. Additionally, miivar.h directly
includes opt_platform.h.

Add the missing sources to the module build, with the FDT-only files
gated behind an OPT_FDT check. Maintain the alphabetical listing of
SRCS, but move the required header files to a separate line to improve
readability.

Reviewed by: mhorne, mindal@semihalf.com
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D34256

Details

Provenance
bsd_dino.skAuthored on Apr 2 2022, 6:28 PM
mhorneCommitted on Apr 3 2022, 3:28 PM
Reviewer
mhorne
Differential Revision
D34256: Make miibus.ko module on par with using 'device miibus' in kernel config
Parents
rG242cd60a0a67: cgem: Support building as a loadable kernel module
Branches
Unknown
Tags
Unknown