Depmod is failing on allmodconfig for arm64 and x86_64
Hi,
The depmod is failing on 9f16d5e6f2206 (mainline) arm64 and x86_64 because of:
``` depmod: ERROR: Cycle detected: libphy depmod: ERROR: Cycle detected: lan969x_switch -> sparx5_switch -> lan969x_switch depmod: ERROR: Cycle detected: ptp depmod: ERROR: Cycle detected: stp depmod: ERROR: Cycle detected: ipv6 depmod: ERROR: Cycle detected: bridge depmod: ERROR: Found 2 modules in dependency cycles! make[2]: *** [scripts/Makefile.modinst:132: depmod] Error 1 make[1]: *** [/tmp/kci/linux/Makefile:1844: modules_install] Error 2 make: *** [Makefile:224: __sub-make] Error 2 ```
This issue wasn't present until c66fbc6c3df9.
[1] https://kcidb.kernelci.org/d/build/build?orgId=1&var-datasource=default&var-build_architecture=arm64&var-build_config_name=defconfig+allmodconfig&var-id=maestro:67427d2a923416c0c993033a
[2] https://kcidb.kernelci.org/d/build/build?orgId=1&var-datasource=default&var-build_architecture=x86_64&var-build_config_name=x86_64_defconfig%20allmodconfig&var-id=maestro:67427d2c923416c0c9930358&from=now-100y&to=now&timezone=browser&var-origin=$__all&var-test_path=&var-issue_presence=yes
Signature · 2 lines
BR, Muhammad Usama Anjum
Quoted 17 lines · Muhammad Usama Anjum
Hi,
The depmod is failing on
9f16d5e6f2206(mainline) arm64 andx86_64because of:``` depmod: ERROR: Cycle detected: libphy depmod: ERROR: Cycle detected: lan969x_switch -> sparx5_switch -> lan969x_switch depmod: ERROR: Cycle detected: ptp depmod: ERROR: Cycle detected: stp depmod: ERROR: Cycle detected: ipv6 depmod: ERROR: Cycle detected: bridge depmod: ERROR: Found 2 modules in dependency cycles! make[2]: *** [scripts/Makefile.modinst:132: depmod] Error 1 make[1]: *** [/tmp/kci/linux/Makefile:1844: modules_install] Error 2 make: *** [Makefile:224: __sub-make] Error 2 ```
Quoted 1 line
This issue wasn't present until
c66fbc6c3df9.
$ git show c66fbc6c3df9 commit c66fbc6c3df9ccefbb896695cfc4db279d517ff1 Merge: f103749785a7 1037d186edfc Author: Linus Torvalds <[email protected]> Date: Wed Nov 20 14:56:02 2024 -0800
Merge tag 'for-linus' of https://github.com/openrisc/linux
Pull OpenRISC update from Stafford Horne:
"A single fixup from me: Fix bug with earlycon being broken due to
removal of early_ioremap"
* tag 'for-linus' of https://github.com/openrisc/linux:
openrisc: Implement fixmap to fix earlycon
Are you sure?
Will
Quoted 32 lines · Will Deacon
Quoted 17 lines · Muhammad Usama Anjum
Hi,
The depmod is failing on
9f16d5e6f2206(mainline) arm64 andx86_64because of:``` depmod: ERROR: Cycle detected: libphy depmod: ERROR: Cycle detected: lan969x_switch -> sparx5_switch -> lan969x_switch depmod: ERROR: Cycle detected: ptp depmod: ERROR: Cycle detected: stp depmod: ERROR: Cycle detected: ipv6 depmod: ERROR: Cycle detected: bridge depmod: ERROR: Found 2 modules in dependency cycles! make[2]: *** [scripts/Makefile.modinst:132: depmod] Error 1 make[1]: *** [/tmp/kci/linux/Makefile:1844: modules_install] Error 2 make: *** [Makefile:224: __sub-make] Error 2 ```Quoted 1 line
This issue wasn't present until
c66fbc6c3df9.$ git show c66fbc6c3df9 commit c66fbc6c3df9ccefbb896695cfc4db279d517ff1 Merge: f103749785a7 1037d186edfc Author: Linus Torvalds <[email protected]> Date: Wed Nov 20 14:56:02 2024 -0800Merge tag 'for-linus' of https://github.com/openrisc/linux
Pull OpenRISC update from Stafford Horne:
"A single fixup from me: Fix bug with earlycon being broken due to
removal ofearly_ioremap"
Quoted 5 lines
* tag 'for-linus' of https://github.com/openrisc/linux:
openrisc: Implement fixmap to fix earlyconAre you sure?
The allmodconfig builds were successful until c66fbc3df9. [1] [2] Here is link to build results. They can be filtered [3].
Quoted 3 lines
Will
Signature · 2 lines
BR, Muhammad Usama Anjum
Calvin Owens
Reviewed-by Steen HegelundQuoted 17 lines · Muhammad Usama Anjum
Hi,
The depmod is failing on
9f16d5e6f2206(mainline) arm64 andx86_64because of:``` depmod: ERROR: Cycle detected: libphy depmod: ERROR: Cycle detected: lan969x_switch -> sparx5_switch -> lan969x_switch depmod: ERROR: Cycle detected: ptp depmod: ERROR: Cycle detected: stp depmod: ERROR: Cycle detected: ipv6 depmod: ERROR: Cycle detected: bridge depmod: ERROR: Found 2 modules in dependency cycles! make[2]: *** [scripts/Makefile.modinst:132: depmod] Error 1 make[1]: *** [/tmp/kci/linux/Makefile:1844: modules_install] Error 2 make: *** [Makefile:224: __sub-make] Error 2 ```
Quoted 1 line
This issue wasn't present until
c66fbc6c3df9.
I set up a bisect script to run overnight, it landed here:
98a01119608d21e0ed95a544071beabb353240ed is the first bad commit commit 98a01119608d21e0ed95a544071beabb353240ed
Author: Daniel Machon <[email protected]>
AuthorDate: Thu Oct 24 00:01:33 2024 +0200
Commit: Jakub Kicinski <[email protected]>
CommitDate: Wed Oct 30 18:08:06 2024 -0700
net: sparx5: add compatible string for lan969x
Add lan9691-switch compatible string to mchp_sparx5_match. Guard it with IS_ENABLED(CONFIG_LAN969X_SWITCH) to make sure Sparx5 can be compiled on its own.
drivers/net/ethernet/microchip/sparx5/sparx5_main.c | 5 +++++ 1 file changed, 5 insertions(+)
bisect found first bad commit
Thanks,
Calvin
Quoted 6 lines
[1] https://kcidb.kernelci.org/d/build/build?orgId=1&var-datasource=default&var-build_architecture=arm64&var-build_config_name=defconfig+allmodconfig&var-id=maestro:67427d2a923416c0c993033a
[2] https://kcidb.kernelci.org/d/build/build?orgId=1&var-datasource=default&var-build_architecture=x86_64&var-build_config_name=x86_64_defconfig%20allmodconfig&var-id=maestro:67427d2c923416c0c9930358&from=now-100y&to=now&timezone=browser&var-origin=$__all&var-test_path=&var-issue_presence=yesSignature · 2 lines
BR, Muhammad Usama Anjum
Hi Calvin, Muhammad,
Thanks for reporting this.
Took me a while to reproduce, turned out i needed a newer version of kmod in order to get the error print.
Quoted 40 lines · Muhammad Usama Anjum
Quoted 17 lines
Hi,
The depmod is failing on
9f16d5e6f2206(mainline) arm64 andx86_64because of:``` depmod: ERROR: Cycle detected: libphy depmod: ERROR: Cycle detected: lan969x_switch -> sparx5_switch -> lan969x_switch depmod: ERROR: Cycle detected: ptp depmod: ERROR: Cycle detected: stp depmod: ERROR: Cycle detected: ipv6 depmod: ERROR: Cycle detected: bridge depmod: ERROR: Found 2 modules in dependency cycles! make[2]: *** [scripts/Makefile.modinst:132: depmod] Error 1 make[1]: *** [/tmp/kci/linux/Makefile:1844: modules_install] Error 2 make: *** [Makefile:224: __sub-make] Error 2 ```Quoted 1 line
This issue wasn't present until
c66fbc6c3df9.I set up a bisect script to run overnight, it landed here:
98a01119608d21e0ed95a544071beabb353240edis the first bad commit commit98a01119608d21e0ed95a544071beabb353240ed
Author: Daniel Machon <[email protected]>
AuthorDate: Thu Oct 24 00:01:33 2024 +0200
Commit: Jakub Kicinski <[email protected]>
CommitDate: Wed Oct 30 18:08:06 2024 -0700net: sparx5: add compatible string for lan969x
Add lan9691-switch compatible string to
mchp_sparx5_match. Guard it withIS_ENABLED(CONFIG_LAN969X_SWITCH)to make sure Sparx5 can be compiled on its own.
Quoted 6 lines
drivers/net/ethernet/microchip/sparx5/sparx5_main.c| 5 +++++ 1 file changed, 5 insertions(+)
bisect found first bad commitThanks,
Calvin
So we have two modules: sparx5-switch.ko and lan969x-switch.ko. They both require symbols from each other, so the error makes sense. I think the solution here is to just ditch the lan969x-switch.ko module alltogether and compile the support into the sparx5-switch.ko module.
/Daniel