Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp296233pxx; Wed, 28 Oct 2020 05:16:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0Oi5VZlh/EJ9qlGC8QoJXcj9AvlMnZfgAhrRZeIJdn4MhfRG4gJvaLbZDkn3lwoubSrr8 X-Received: by 2002:a50:e40c:: with SMTP id d12mr7247920edm.35.1603887385116; Wed, 28 Oct 2020 05:16:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603887385; cv=none; d=google.com; s=arc-20160816; b=0UqZlJ7EeYcjkXv+HZmoUD5Kpoho3+lzyiNtmwBSEaT5qozxGvhA81hY+F1Zk+BmI3 ylF9XxBC7xcwqVcKX88LuXsWBOHL6QfUl/2MQ3YOcK2ErlMrDcZjht+t+L6OSRbYlI4+ aD6vCxvy4rap49ALA/QIfCIjy6bzD635ckzYAIkSXf9hpVdDnNE54Dz8qIF04xhGZUcz 4ybijLRc7+r0QRECSX0naDoMs2rlwVDVcXfqR+PChPMo3oUuU5fKUNvUagKbHKAylNNp /JEw9bEHJYRp9Yy++PWlB6v5HNDngpQQewyOoVf4GE+m4u3Ap0S0+tswKCJGBFylMXY2 ubCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=LXIKq8XP/tQzXPpPDBwWUjEg/ReJxXbrNlOR11w9o6s=; b=YhEvn/qvmh4w5Ixj7Y+AZrDM7RIhcxE8+8Qx6TWzXWuEeNsrBFQspzNXu272QFYLPP lMfB/LYmI+bc8tmxlaaSWG085K8QlTxlHUuXciElSYKP7QaQhRpqXZ3vpiICvTnoABeA nsp5HTQzT65ugwWy4xhHhPH6g+aVktQcRNW2KA/GU4+GXP0/zC2Y4SkFW3OvqVrTBrRf 5bXdr3DZqRbaEjUaqBQnc0yoj3JnjkfglfmJR9Dbgf3vi4TRuNscGeZ4X1Spgy9yma48 vEQrCbGc7xHnAdZe5BsV/8ldDhGJDWda19ozV/hjgzNKTB0uonQfFnpQqkrN5vpsb7q/ cS9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=hADSSXFo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g1si3663191edn.100.2020.10.28.05.16.02; Wed, 28 Oct 2020 05:16:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=hADSSXFo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1796378AbgJ0PR5 (ORCPT + 99 others); Tue, 27 Oct 2020 11:17:57 -0400 Received: from mail.kernel.org ([198.145.29.99]:50626 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1794813AbgJ0PNp (ORCPT ); Tue, 27 Oct 2020 11:13:45 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 8E04920657; Tue, 27 Oct 2020 15:13:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603811625; bh=b3yn/e1fuNGB/nSvT2z3p0aLOFj4I7+dDr6hA0bzlTk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hADSSXFoRezmmvgQzvyYlWi00/M+2N4jK8GPC1fV2CcZw4B1rT78bwyvwLDps8T+W VW9DXteYwgRCbNms/hZ5q7eiXpoj310KdT/YdIGk6MjUZgi6sxL0xLb6NvFdF8hsuG PkjBXGosfNkj7yYioCRMJdrH0IstxA6OO4fbkG70= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, =?UTF-8?q?J=C3=A9r=C3=B4me=20Pouiller?= , Sasha Levin Subject: [PATCH 5.8 560/633] staging: wfx: fix handling of MMIC error Date: Tue, 27 Oct 2020 14:55:03 +0100 Message-Id: <20201027135549.077722164@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135522.655719020@linuxfoundation.org> References: <20201027135522.655719020@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jérôme Pouiller [ Upstream commit 8d350c14ee5eb62ecd40b0991248bfbce511954d ] As expected, when the device detect a MMIC error, it returns a specific status. However, it also strip IV from the frame (don't ask me why). So, with the current code, mac80211 detects a corrupted frame and it drops it before it handle the MMIC error. The expected behavior would be to detect MMIC error then to renegotiate the EAP session. So, this patch correctly informs mac80211 that IV is not available. So, mac80211 correctly takes into account the MMIC error. Signed-off-by: Jérôme Pouiller Link: https://lore.kernel.org/r/20201007101943.749898-2-Jerome.Pouiller@silabs.com Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/staging/wfx/data_rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/wfx/data_rx.c b/drivers/staging/wfx/data_rx.c index 0e959ebc38b56..a9fb5165b33d9 100644 --- a/drivers/staging/wfx/data_rx.c +++ b/drivers/staging/wfx/data_rx.c @@ -80,7 +80,7 @@ void wfx_rx_cb(struct wfx_vif *wvif, goto drop; if (arg->status == HIF_STATUS_RX_FAIL_MIC) - hdr->flag |= RX_FLAG_MMIC_ERROR; + hdr->flag |= RX_FLAG_MMIC_ERROR | RX_FLAG_IV_STRIPPED; else if (arg->status) goto drop; -- 2.25.1