From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from paleale.coelho.fi ([176.9.41.70]:42394 "EHLO farmhouse.coelho.fi" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750848AbdJ2M25 (ORCPT ); Sun, 29 Oct 2017 08:28:57 -0400 From: Luca Coelho To: kvalo@codeaurora.org Cc: linux-wireless@vger.kernel.org, Shahar S Matityahu , Luca Coelho Date: Sun, 29 Oct 2017 14:28:13 +0200 Message-Id: <20171029122816.8802-15-luca@coelho.fi> (sfid-20171029_132859_949477_5173D2B3) In-Reply-To: <20171029122816.8802-1-luca@coelho.fi> References: <20171029122816.8802-1-luca@coelho.fi> Subject: [PATCH 14/17] iwlwifi: drop RX frames during hardware restart Sender: linux-wireless-owner@vger.kernel.org List-ID: From: Shahar S Matityahu In case of a hardware restart the BA session data in HW is lost so the reorder buffer simply passes the frames to mac80211 as is as there is no NSSN set. Instead, we will drop these frames before they reach the reorder buffer. mac80211 drops such frames anyway, but we shouldn't rely on that. In addition it saves some processing time Signed-off-by: Shahar S Matityahu Signed-off-by: Luca Coelho --- drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c b/drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c index 343bdc4266cd..76dc58381e1c 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c @@ -834,6 +834,9 @@ void iwl_mvm_rx_mpdu_mq(struct iwl_mvm *mvm, struct napi_struct *napi, struct sk_buff *skb; u8 crypt_len = 0; + if (unlikely(test_bit(IWL_MVM_STATUS_IN_HW_RESTART, &mvm->status))) + return; + /* Dont use dev_alloc_skb(), we'll have enough headroom once * ieee80211_hdr pulled. */ -- 2.14.2