Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2909817pxb; Tue, 19 Jan 2021 08:54:46 -0800 (PST) X-Google-Smtp-Source: ABdhPJwQ+x1YZfRJ3Ylp6MgK2gkfUTYvecYgacnY2zWFNOJ97F/lTSXjKaZhMRAS95X3HYFwIICJ X-Received: by 2002:a05:6402:2c4:: with SMTP id b4mr4161508edx.49.1611075286449; Tue, 19 Jan 2021 08:54:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611075286; cv=none; d=google.com; s=arc-20160816; b=N5M1uHEBk7hD3/GjKPCuWt8IUdMRbFKQaG9ipTRtrjqZ8eYVI4YftrnzLrE7tyFHCq ZTpnZSWB++8AQcc8GMP1X+Oh0s56UFjAMM5kJ/uuT645fk3g5hiwIf/UmCACClkgkEtT w47CIxBmsOaYnCM4WFiNQCewM7Xaex20fiJEP3x6j6S2kderJHkMv0vyKgaoX2Xn5H0J DLc2sy5jEzHZMMRFCbyzJYJAW3/FmkxbRiBZByaXgMkHQNX86hGEfHkm6L/gknMZJN/T umkrfMOdLhHjzz0nOmqmxRHRHkL9rhP6mbOasJy5SGD6ryP96rjdvngn45mkYF8lzTk/ 5pAA== 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:to:from :dkim-signature; bh=ahmWnZAwkyvoeStbN40m0VVoSNcmj9YGbKfkZkaYnOA=; b=MXw2YMCXKPwHvF6h2e27jF0W0enTq7Vw0V8kuPVgrEwbs8GbBmJs6zKSw05I3ZjJrK Yu9j4/TZ87NzL3EzkqLLa6KMrfO++uzHqevNzOuiwTbgubdU1IaZ5gV9QxryNuMXQ+kI C3G8poK4USZSWiKg+/aE8M997LspGISWqj8SdntOHPNfqiejYJfTZmLQFTwazVwJBpT0 bV+WHLggr834OxlXEQqSIkR20ft5pRt29Q4iT2Dg8ts3xAWFGjJ2ptLDiFs170NmW4F9 Q314tV5IVKfBoc0kubJy4w8brahA0BICgSmO/U5tRN5SLx142qW3iowhVkAZecR42kxt 3g5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@nbd.name header.s=20160729 header.b=eRxHhKky; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id go13si1195488ejc.73.2021.01.19.08.54.23; Tue, 19 Jan 2021 08:54:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@nbd.name header.s=20160729 header.b=eRxHhKky; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389825AbhASQu6 (ORCPT + 99 others); Tue, 19 Jan 2021 11:50:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54760 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390349AbhASQu0 (ORCPT ); Tue, 19 Jan 2021 11:50:26 -0500 Received: from nbd.name (nbd.name [IPv6:2a01:4f8:221:3d45::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB873C061574 for ; Tue, 19 Jan 2021 08:49:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=nbd.name; s=20160729; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=ahmWnZAwkyvoeStbN40m0VVoSNcmj9YGbKfkZkaYnOA=; b=eRxHhKkyXYu7JB+tnNjJvBUAJc BCE3nckjlShpFgC/0HnTd2K4rdXG+FR//WB2emBJHACNPSmTHE/XEHh/QxCsgHWXrrDTvMdcq3mGn P2eFW6kQgjdj0BJ0R8qVclwvj18R4bgHU9tcRIZh/R7UkzP3eMnYKGawShnmhSYyMv74=; Received: from p54ae91f2.dip0.t-ipconnect.de ([84.174.145.242] helo=localhost.localdomain) by ds12 with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.89) (envelope-from ) id 1l1uCO-0004Hf-CJ for linux-wireless@vger.kernel.org; Tue, 19 Jan 2021 17:49:44 +0100 From: Felix Fietkau To: linux-wireless@vger.kernel.org Subject: [PATCH 2/3] mt76: mt7915: fix vif sta index for DBDC Date: Tue, 19 Jan 2021 17:49:42 +0100 Message-Id: <20210119164943.99223-2-nbd@nbd.name> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20210119164943.99223-1-nbd@nbd.name> References: <20210119164943.99223-1-nbd@nbd.name> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Since vif indexes are per-phy, we need to factor in the phy index to avoid collisions on the WTBL index Signed-off-by: Felix Fietkau --- drivers/net/wireless/mediatek/mt76/mt7915/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/main.c b/drivers/net/wireless/mediatek/mt76/mt7915/main.c index 8b8d0d2d532b..cbd9892f5bf9 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7915/main.c +++ b/drivers/net/wireless/mediatek/mt76/mt7915/main.c @@ -189,7 +189,8 @@ static int mt7915_add_interface(struct ieee80211_hw *hw, phy->mt76->vif_mask |= BIT(mvif->idx); phy->omac_mask |= BIT_ULL(mvif->omac_idx); - idx = MT7915_WTBL_RESERVED - mvif->idx; + idx = MT7915_WTBL_RESERVED - mvif->idx - + ext_phy * MT7915_MAX_INTERFACES / 2; INIT_LIST_HEAD(&mvif->sta.rc_list); INIT_LIST_HEAD(&mvif->sta.stats_list); -- 2.28.0