The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=232021fd093c6e65beee5c0b4281091902022d08
commit 232021fd093c6e65beee5c0b4281091902022d08 Author: Ed Maste <[email protected]> AuthorDate: 2026-06-05 21:01:39 +0000 Commit: Ed Maste <[email protected]> CommitDate: 2026-06-06 12:34:50 +0000 linuxkpi 802.11: Free entire mbuf chain on failure Reviewed by: bz Sponsored by: The FreeBSD Foundation Fixes: 0936c648ad0ee ("LinuxKPI: 802.11: update the ni/lsta reference cycle") Fixes: c816f64e66a0d ("LinuxKPI: 802.11: plug mbuf leak") Differential Revision: https://reviews.freebsd.org/D57477 --- sys/compat/linuxkpi/common/src/linux_80211.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index c6dcae2bffff..11f76c3ff5a5 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -5473,7 +5473,7 @@ lkpi_xmit(struct ieee80211_node *ni, struct mbuf *m, #endif LKPI_80211_LSTA_TXQ_UNLOCK(lsta); if (freem) - m_free(m); + m_freem(m); return (ENETDOWN); } @@ -5482,7 +5482,7 @@ lkpi_xmit(struct ieee80211_node *ni, struct mbuf *m, if (error != 0) { LKPI_80211_LSTA_TXQ_UNLOCK(lsta); if (freem) - m_free(m); + m_freem(m); #ifdef LINUXKPI_DEBUG_80211 if (linuxkpi_debug_80211 & D80211_TRACE_TX) ic_printf(ni->ni_ic, "%s: mbufq_enqueue failed: %d\n",
