git: 91431aa03605 - main - uether: Handle SIOCGIFXMEDIA

From: Ed Maste <emaste_at_FreeBSD.org>
Date: Fri, 30 Oct 2026 14:17:30 UTC
The branch main has been updated by emaste:

URL: https://cgit.FreeBSD.org/src/commit/?id=91431aa03605383ecfcbf1b9b2be69ab47e56a08

commit 91431aa03605383ecfcbf1b9b2be69ab47e56a08
Author:     Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2026-10-16 15:17:44 +0000
Commit:     Ed Maste <emaste@FreeBSD.org>
CommitDate: 2026-10-30 14:16:45 +0000

    uether: Handle SIOCGIFXMEDIA
    
    Commit eb7e25b22f1 ("ifmedia changes:") added SIOCGIFXMEDIA for extended
    Ethernet media subtypes, but uether_ioctl() was not updated to pass it
    to ifmedia_ioctl().  I believe no existing USB Ethernet devices used
    extended subtypes, so this went unnoticed.
    
    Without SIOCGIFXMEDIA ifconfig falls back to SIOCGIFMEDIA, which maps an
    extended subtype to IFM_OTHER, and ifconfig reports "Ethernet Other."
    
    Sponsored by:   The FreeBSD Foundation
    Differential Revision: https://reviews.freebsd.org/D60779
---
 sys/dev/usb/net/usb_ethernet.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sys/dev/usb/net/usb_ethernet.c b/sys/dev/usb/net/usb_ethernet.c
index 16235aa4e278..8fab6b2bf975 100644
--- a/sys/dev/usb/net/usb_ethernet.c
+++ b/sys/dev/usb/net/usb_ethernet.c
@@ -533,6 +533,7 @@ uether_ioctl(if_t ifp, u_long command, caddr_t data)
 		UE_UNLOCK(ue);
 		break;
 	case SIOCGIFMEDIA:
+	case SIOCGIFXMEDIA:
 	case SIOCSIFMEDIA:
 		if (ue->ue_miibus != NULL) {
 			mii = device_get_softc(ue->ue_miibus);