Page MenuHomeFreeBSD

net/if_media.c: avoid if_bge attach panic on Supermicro H13SSL-N
Needs ReviewPublic

Authored by mm on Oct 28 2024, 4:25 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Nov 27, 1:05 AM
Unknown Object (File)
Nov 1 2024, 4:32 PM
Subscribers

Details

Reviewers
zlei
glebius
kib
Summary

Exit on SIOCGIFMEDIA/SIOCGIFXMEDIA if ifm_status is unpopulated.

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=277849

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

mm requested review of this revision.Oct 28 2024, 4:25 PM

This is indeed a workaround, I remember fixing something similar for ports' variant of if_re. The fix was to move the ether_ifattach() after the media structures are initialized,
https://github.com/alexdupre/rtl_bsd_drv/commit/2a97cc982d0362b69040d1c849f697ff61e37106

I did not looked at the bge code to confirm that it is the case.

In D47314#1079145, @kib wrote:

This is indeed a workaround, I remember fixing something similar for ports' variant of if_re. The fix was to move the ether_ifattach() after the media structures are initialized,
https://github.com/alexdupre/rtl_bsd_drv/commit/2a97cc982d0362b69040d1c849f697ff61e37106

I did not looked at the bge code to confirm that it is the case.

I checked the source code of if_gbe, it appears that the media structures are initialized correctly.
It is better dig into the core dump to inspect what's going on.