Skip to content

net: usb: lan78xx: add phy dependency for user tools

net: usb: lan78xx: add phy dependency for user tools

JIRA: https://issues.redhat.com/browse/RHEL-17582

Upstream Status: RHEL-only

For lan78xx driver, the related module for the phy is loaded dynamically depending on the current hardware. In this case, the associated phy is read using mdio bus and then the associated phy module is loaded during runtime (kernel function phy_request_driver_module). However, no software dependency is defined, so the user tools will no be able to get this dependency. For example, if dracut is used and the hardware is present, lan78xx will be included but no phy module will be added, and in the next restart the device will not work from boot because no related phy will be found during initramfs stage.

In order to solve this for this release, we are going to define a normal 'pre' software dependency in lan78xx module with the requested phy module (micrel) for the hardware requested by the customer.

A new procedure has been created in kmod, that is called 'weak' dependency: https://github.com/kmod-project/kmod/commit/05828b4a6e9327a63ef94df544a042b5e9ce4fe7 to optimize this, but the complete approval for kernel and dracut user package in upstream will take more time.

So, let's do it in this way for now and use the new procedure for the next release (then this commit will be reverted).

Signed-off-by: Jose Ignacio Tornos Martinez jtornosm@redhat.com

Merge request reports