Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp356148rwr; Thu, 27 Apr 2023 02:12:55 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7FKT9Avc0bL9y96lfMLakat0q5RJ3EyioEZUTWhyppB/hk6JawVn+YO3V5iKnbPXfbrydx X-Received: by 2002:a05:6a00:2408:b0:63f:37b8:655 with SMTP id z8-20020a056a00240800b0063f37b80655mr1409055pfh.20.1682586774823; Thu, 27 Apr 2023 02:12:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682586774; cv=none; d=google.com; s=arc-20160816; b=KAlEFOCFwvrS6uDTpllnXMMDDHsJVSCRulOqKSeq2h958TO7QI8oRFRyako4mDjwJq BSpTY0cO+NvFPElAODGwtvnAqpUP6egkTDuOjriJP5o4V9KYZuS2i+4/ylemAmWyHMOa GevraGRu2LjA6UuUeL2kENGtb19QxgLYgEgzZ1lWLCBWOxd2oV90i9Y30pJZ4ZN8jrvr 27SqPxMa/ccIMPiKv1k3bZNaELSCcIBOxn2diIKrds3lpzTU1id5Qyro0vPjX084w+7T blchLausD3BW1vwgoRTrKRlcvw/HeAQzhiX3LoHmxx4FM3X/giV4eMueJ403sw2AOBot AzIg== 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 :references:in-reply-to:message-id:date:subject:cc:to:dkim-signature :dkim-signature:from; bh=bJan1WNMcFcfwXTFXtQ1gfptIcRdldF7K7is6hG3+ys=; b=SS505EjVteARu/1SqZ4ByMVY4cz8mTQUL3G3Hibxk9ObFMNdXZr+t47K4ay3zDkDvx 9gswyq8CJhQHAryNgUFHUdURxVDXr4Q3jqFKhcdgqdv58GzgAcWlZqsdsGUoTrKzg9Lh jht7NloFA6bjr9EltYDMqvck0H0ch3YRnpxKge2m26bjWSY72uT9jDiPZJXX9fquwKfl wbSrkG4KOfWfaDeAZI8gPOCBNOu3YVXUiHRzdYgxy+KVZCjHLmVo7r9yMTYRPC2cCSS3 sdTB1KPbQRRjX3aIrc3a43gfiUqOd1m5kwoP3HFs6EbFtwEOoWoMl9ta4VibTMLOQnXp HSGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=bucvyzZH; dkim=neutral (no key) header.i=@linutronix.de header.b=+shwgfPj; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a6-20020a634d06000000b0050fa328e128si17291546pgb.419.2023.04.27.02.12.46; Thu, 27 Apr 2023 02:12:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=bucvyzZH; dkim=neutral (no key) header.i=@linutronix.de header.b=+shwgfPj; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243340AbjD0JKV (ORCPT + 62 others); Thu, 27 Apr 2023 05:10:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37682 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243389AbjD0JJ4 (ORCPT ); Thu, 27 Apr 2023 05:09:56 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 486B830FC for ; Thu, 27 Apr 2023 02:09:53 -0700 (PDT) From: Martin Kaistra DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1682586587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bJan1WNMcFcfwXTFXtQ1gfptIcRdldF7K7is6hG3+ys=; b=bucvyzZH+vO5XmhmjoqMIJUkychG94N+WlEgt56tGAJ+4+bqMjnnpN+ci7fay734+LRNUW btgc9AbHv10abnFQ+iigj5H6ecehaw6fTuJp14MHixsTRAkYAYoML9HBj+mKl7/WIKtTUX iEqGMoJK0IQFcoM06GnLds4vCcKro9XEjAPPnnoZC/gZMOA86Rid/6Uiw0SPTgPycLpcVS 7zrYNQ/H8Pp7xdaZW22zSPVWhnE66L84Zmj64Wfdk5voK0TuqeHBHhppuobp+Nv50ZjiAB VJd5VKtOUeI42cTss7sBmaDUpOtrvfw/7C9TyTXD44XWT8V5FbaX9i+rPWo2+A== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1682586587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bJan1WNMcFcfwXTFXtQ1gfptIcRdldF7K7is6hG3+ys=; b=+shwgfPj5oIae/tlA5gqljHenmXAguOlRP+r2VkXpRY/cxKw8inxu/Djw8+CUluZU1i6sp 8wne79Y52e09G8Cw== To: linux-wireless@vger.kernel.org Cc: Jes Sorensen , Kalle Valo , Ping-Ke Shih , Bitterblue Smith , Sebastian Andrzej Siewior Subject: [PATCH v3 14/18] wifi: rtl8xxxu: Clean up filter configuration Date: Thu, 27 Apr 2023 11:09:18 +0200 Message-Id: <20230427090922.165088-15-martin.kaistra@linutronix.de> In-Reply-To: <20230427090922.165088-1-martin.kaistra@linutronix.de> References: <20230427090922.165088-1-martin.kaistra@linutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org When RCR_CHECK_BSSID_MATCH is set in AP mode, we don't receive any data frames. Rearrange RCR bits to filter flags to match other realtek drivers and remove RCR_CHECK_BSSID_MATCH in AP mode. Signed-off-by: Martin Kaistra Reviewed-by: Ping-Ke Shih --- .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c index 5aecd2b9184b9..3b34e4164ac72 100644 --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c @@ -6688,22 +6688,22 @@ static void rtl8xxxu_configure_filter(struct ieee80211_hw *hw, */ if (*total_flags & FIF_BCN_PRBRESP_PROMISC) - rcr &= ~RCR_CHECK_BSSID_BEACON; + rcr &= ~(RCR_CHECK_BSSID_BEACON | RCR_CHECK_BSSID_MATCH); else - rcr |= RCR_CHECK_BSSID_BEACON; + rcr |= RCR_CHECK_BSSID_BEACON | RCR_CHECK_BSSID_MATCH; + + if (priv->vif && priv->vif->type == NL80211_IFTYPE_AP) + rcr &= ~RCR_CHECK_BSSID_MATCH; if (*total_flags & FIF_CONTROL) rcr |= RCR_ACCEPT_CTRL_FRAME; else rcr &= ~RCR_ACCEPT_CTRL_FRAME; - if (*total_flags & FIF_OTHER_BSS) { + if (*total_flags & FIF_OTHER_BSS) rcr |= RCR_ACCEPT_AP; - rcr &= ~RCR_CHECK_BSSID_MATCH; - } else { + else rcr &= ~RCR_ACCEPT_AP; - rcr |= RCR_CHECK_BSSID_MATCH; - } if (*total_flags & FIF_PSPOLL) rcr |= RCR_ACCEPT_PM; -- 2.30.2