git: 7aa34e12c9e1 - main - rge: fix multicast add/removal by using if_getdrvflags()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 12 Jul 2026 15:35:36 UTC
The branch main has been updated by adrian:
URL: https://cgit.FreeBSD.org/src/commit/?id=7aa34e12c9e198bf8b7e74370ff702def5ec2649
commit 7aa34e12c9e198bf8b7e74370ff702def5ec2649
Author: Adrian Chadd <adrian@FreeBSD.org>
AuthorDate: 2026-07-12 15:26:46 +0000
Commit: Adrian Chadd <adrian@FreeBSD.org>
CommitDate: 2026-07-12 15:26:46 +0000
rge: fix multicast add/removal by using if_getdrvflags()
Using if_getflags() to check IFF_DRV_RUNNING is wrong;
if_getdrvflags() is required. This issue resulted in the
multicast filter not being updated.
This was an oversight by me in my initial port.
Thanks to danilo@ for reporting it and Oleg <oleglelchuk@gmail.com>
for the fix.
PR: kern/295176
---
sys/dev/rge/if_rge.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys/dev/rge/if_rge.c b/sys/dev/rge/if_rge.c
index 61dcac390765..7c11da5c3f53 100644
--- a/sys/dev/rge/if_rge.c
+++ b/sys/dev/rge/if_rge.c
@@ -951,7 +951,7 @@ rge_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
case SIOCADDMULTI:
case SIOCDELMULTI:
RGE_LOCK(sc);
- if ((if_getflags(ifp) & IFF_DRV_RUNNING) != 0)
+ if ((if_getdrvflags(ifp) & IFF_DRV_RUNNING) != 0)
rge_iff_locked(sc);
RGE_UNLOCK(sc);
break;