Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp2262677rwr; Fri, 28 Apr 2023 08:09:23 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7lxNnkxpSvIqFx1aAen7h/aYnMDThA/N3YEYGOa/SXmXHdIW5ABhelRMY3un4+U5EVXGoA X-Received: by 2002:a17:903:1c6:b0:1a2:9183:a49c with SMTP id e6-20020a17090301c600b001a29183a49cmr6133869plh.32.1682694563521; Fri, 28 Apr 2023 08:09:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682694563; cv=none; d=google.com; s=arc-20160816; b=zGl3NRbkjoon4icw4//BMBz5x7h3mcFd3r9RgQ58GlhHJF/f58YGql9FAUSO6XHGts VZOPNfdzDjiakSAVx4wJTIMzeTUrYLJXnRxukEizF8wenBgwYK81YMchKcRKhIU6Hd+f hXUAIbbJRtbnluYmLVsf5Gj+uWEyjXz2MoWO9IRxIa8ImRgIB7upAZKcBT7ikwLAHFZZ yub81C3jwubrGNgFTTnN77S2YYxKyq/L79QqjvxTotCS0Cpxxrah/As0v2Sqa/ZxgoAd QJz+WBMWaIPEo5VO/1w7htI7EW5BZsE4+l+NucAvfbb/rUQ904Eud5L4lTScmEM0MxQa iKjQ== 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=5TzCBkAhEE1r9irTGgb6179fix0fEgXAdCpZoHyDzVI=; b=UmiyPL7HTAxrNqNH8MM4bMZWcrP613H7QVNRDZyipF5Z4Y5BNYh0Mzpc42aBC0y8CL GjLcEtdcluP7TGvfwLt8J+afeYYaO6hlKEg9jh/AVzvh6iAeneGXnxouCXOEN8hwi66w /NT0CzdA5q9XVbtP2TRhZzBoAdbA7hJdZjORF3LYf1Ga9UggsUvrbg9TqQI39BoIyCwj bb91pNt/oGaBT6RlJYlkD9TVQM1Fwrsq2ERGXPjRmWvjqky8xbep7rFdtjSc0r14X/ZT BzkrGdKzLVn2HOgGSZrM+bpbFCdnci0R3vmHW7wcoKNtXTI13ZoYsWO9TeUXTlRtwXQc gcIw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b="d0JHi6n/"; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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 ku14-20020a170903288e00b001a522ea4e89si19932415plb.125.2023.04.28.08.09.15; Fri, 28 Apr 2023 08:09:23 -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="d0JHi6n/"; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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 S1346312AbjD1PJC (ORCPT + 62 others); Fri, 28 Apr 2023 11:09:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346289AbjD1PIy (ORCPT ); Fri, 28 Apr 2023 11:08:54 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1F2C82726 for ; Fri, 28 Apr 2023 08:08:51 -0700 (PDT) From: Martin Kaistra DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1682694521; 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=5TzCBkAhEE1r9irTGgb6179fix0fEgXAdCpZoHyDzVI=; b=d0JHi6n/pDSpsyzGYz3mrFdvz8YAEntytevcZFwor6XRcnZ8waEqI4EymMB12KwtVFUiPB bA0LXyPICd5khDac8vY2Fdh9WmOAuBfPhbl+Ze1JlIk/ZkECN4SMlSmUCjRQBVYhPh6X0W ltuAM5dp+KrHBH8kHqrh4sX9NGVoa1qtlIOpOwK2fycK7vREumaKGRJgsBBT8YhHjP3AXB J21gy/ylLlDM4sB2toxtT3U+q3rGNo/txpGfrh7xOQT7wHT49B01CFwmnKamCHv3ajDAQT 0mOf/HRVls7FUdU0ToelmrkV2nORcHK7ZyqinR8Nra3OWcWD/snumIh7f4OhyQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1682694521; 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=5TzCBkAhEE1r9irTGgb6179fix0fEgXAdCpZoHyDzVI=; b=jj7FBTWTX9bihWh0CWpImC5fpwDxYq2wIBad79IC/ubRbO+hCYQQO3MS/HThyJfdwpACf8 BmJqp2hDxJJ5YZDw== To: linux-wireless@vger.kernel.org Cc: Jes Sorensen , Kalle Valo , Ping-Ke Shih , Bitterblue Smith , Sebastian Andrzej Siewior Subject: [PATCH v4 14/18] wifi: rtl8xxxu: Clean up filter configuration Date: Fri, 28 Apr 2023 17:08:29 +0200 Message-Id: <20230428150833.218605-15-martin.kaistra@linutronix.de> In-Reply-To: <20230428150833.218605-1-martin.kaistra@linutronix.de> References: <20230428150833.218605-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,URIBL_BLOCKED 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 2e075094a37a5..9e9d172a37f1e 100644 --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c @@ -6689,22 +6689,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