diff options
author | Jonathan Matthew <jmatthew@cvs.openbsd.org> | 2020-06-02 02:26:37 +0000 |
---|---|---|
committer | Jonathan Matthew <jmatthew@cvs.openbsd.org> | 2020-06-02 02:26:37 +0000 |
commit | 09c0856231677c253033bffd8627d62354a6d914 (patch) | |
tree | ad5282e7d18e7601fdd3560af3402779929fdd23 /sys/dev/pci/if_iwm.c | |
parent | e64972ef3e11148ba5487561effaca172e6a7f8c (diff) |
Add missing ieee80211_release_node() calls in cases where hardware
decryption failed. The node here is always ic_bss, for which the
reference count isn't actually used (it's always freed when the interface
detaches), so missing these calls wasn't really a problem.
ok stsp@
Diffstat (limited to 'sys/dev/pci/if_iwm.c')
-rw-r--r-- | sys/dev/pci/if_iwm.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/pci/if_iwm.c b/sys/dev/pci/if_iwm.c index 25849cb2464..69c252f4e8a 100644 --- a/sys/dev/pci/if_iwm.c +++ b/sys/dev/pci/if_iwm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_iwm.c,v 1.310 2020/05/23 08:42:51 stsp Exp $ */ +/* $OpenBSD: if_iwm.c,v 1.311 2020/06/02 02:26:36 jmatthew Exp $ */ /* * Copyright (c) 2014, 2016 genua gmbh <info@genua.de> @@ -3992,6 +3992,7 @@ iwm_rx_frame(struct iwm_softc *sc, struct mbuf *m, int chanidx, ic->ic_stats.is_ccmp_dec_errs++; ifp->if_ierrors++; m_freem(m); + ieee80211_release_node(ic, ni); return; } /* Check whether decryption was successful or not. */ @@ -4003,11 +4004,13 @@ iwm_rx_frame(struct iwm_softc *sc, struct mbuf *m, int chanidx, ic->ic_stats.is_ccmp_dec_errs++; ifp->if_ierrors++; m_freem(m); + ieee80211_release_node(ic, ni); return; } if (iwm_ccmp_decap(sc, m, ni) != 0) { ifp->if_ierrors++; m_freem(m); + ieee80211_release_node(ic, ni); return; } rxi->rxi_flags |= IEEE80211_RXI_HWDEC; |