git: 3d771e0db66d - main - dwc: cleanup
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 20 Jan 2026 10:27:08 UTC
The branch main has been updated by tuexen:
URL: https://cgit.FreeBSD.org/src/commit/?id=3d771e0db66da77da5a7f323df1c0638e6b586ea
commit 3d771e0db66da77da5a7f323df1c0638e6b586ea
Author: Michael Tuexen <tuexen@FreeBSD.org>
AuthorDate: 2026-01-20 10:25:31 +0000
Commit: Michael Tuexen <tuexen@FreeBSD.org>
CommitDate: 2026-01-20 10:25:31 +0000
dwc: cleanup
No functional change intended.
Reviewed by: Timo Völker
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D54788
---
sys/dev/dwc/if_dwc.c | 16 ++++++----------
1 file changed, 6 insertions(+), 10 deletions(-)
diff --git a/sys/dev/dwc/if_dwc.c b/sys/dev/dwc/if_dwc.c
index 5e2ca216b3c0..f57a19e8a112 100644
--- a/sys/dev/dwc/if_dwc.c
+++ b/sys/dev/dwc/if_dwc.c
@@ -265,18 +265,14 @@ dwc_ioctl(if_t ifp, u_long cmd, caddr_t data)
}
if (mask & (IFCAP_RXCSUM | IFCAP_RXCSUM_IPV6))
if_togglecapenable(ifp, IFCAP_RXCSUM | IFCAP_RXCSUM_IPV6);
- if (mask & IFCAP_TXCSUM)
+ if (mask & IFCAP_TXCSUM) {
if_togglecapenable(ifp, IFCAP_TXCSUM);
- if ((if_getcapenable(ifp) & IFCAP_TXCSUM) != 0)
- if_sethwassistbits(ifp, CSUM_IP | CSUM_DELAY_DATA, 0);
- else
- if_sethwassistbits(ifp, 0, CSUM_IP | CSUM_DELAY_DATA);
- if (mask & IFCAP_TXCSUM_IPV6)
+ if_togglehwassist(ifp, CSUM_IP | CSUM_DELAY_DATA);
+ }
+ if (mask & IFCAP_TXCSUM_IPV6) {
if_togglecapenable(ifp, IFCAP_TXCSUM_IPV6);
- if ((if_getcapenable(ifp) & IFCAP_TXCSUM_IPV6) != 0)
- if_sethwassistbits(ifp, CSUM_DELAY_DATA_IPV6, 0);
- else
- if_sethwassistbits(ifp, 0, CSUM_DELAY_DATA_IPV6);
+ if_togglehwassist(ifp, CSUM_DELAY_DATA_IPV6);
+ }
if (if_getdrvflags(ifp) & IFF_DRV_RUNNING) {
DWC_LOCK(sc);