From patchwork Thu Jun 12 12:11:26 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maharaja Kennadyrajan X-Patchwork-Id: 896235 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CFC722F432A for ; Thu, 12 Jun 2025 12:11:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749730299; cv=none; b=X5jAQ6iC+zch9sz3Fm9PVas9rOV4Imt5An5ELpT98b5c33oUBF49LNXXbniegvxnNncw3DyfRkY7OlkTxQtHWif7osx6xhy3vAvbzVvo8RIreekQax5CDDZlTPzu9d9In8LoO4ge6c9/noVKuXZv1W212dLaltcOdF8GZnRkwWU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749730299; c=relaxed/simple; bh=gUNupGepM1WVSMap8KXNT9bP2CjzqWLKV0ztkGjCTRs=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=iYdSozXlZlaRgXIfYMWI0wK3uLy+o2JCfPuCC67aYB/LbOYHm5sA3W52gi7kcNrFMp2EIJUtB1BEXbNFLEics08NC9btYlUl7i8JknSHDAO7WgqxAnaCZd/hlECYtSKuUqIBY7m3lvTI5dpZxZ5WcljAHbep1B2AvM4QvwjuQCg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=QyddZAyY; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="QyddZAyY" Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 55C8pSlU029716 for ; Thu, 12 Jun 2025 12:11:35 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:date:from:in-reply-to:message-id:references:subject:to; s= qcppdkim1; bh=a+4rMuTii1JkiDDuWIDdg9QzjymHuS15HI2nOtnUfsg=; b=Qy ddZAyY4nPPb/gW4HBt+8hD5fEypoSGPhNEPSnP+6kcunJ3XGOCiKv4oaouWlPXze ezDe+FP3+XuEx0+TR6UUcxA7LeHH0N0kxEJFjw4PKul4A/G5HMnlnuMTKUE19Iqe eGRLsNC45sZsQs+jp73H/rFXltTGLicEJVDpE4IHd877wvtruVjX5cAv5PcDc2v3 N+qfI+ydl5sIi9jOpaAJjLCfa28ak5nuOMmIUaQl6g+28/9uUJ4T5tvjGHfIsKwo DEaKXo0mMhfyJAp107Oo+cHclceho0vNuCj0RrPFnRB0E2JQFBvgVG8/LGIeAiJU NXXX37/xzkaTkS644NiQ== Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 474d128efs-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 12 Jun 2025 12:11:35 +0000 (GMT) Received: by mail-pf1-f197.google.com with SMTP id d2e1a72fcca58-7391d68617cso1659140b3a.0 for ; Thu, 12 Jun 2025 05:11:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1749730294; x=1750335094; h=references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=a+4rMuTii1JkiDDuWIDdg9QzjymHuS15HI2nOtnUfsg=; b=K/ur9wBaAFL56ptplKbrr/5Lm/eWS92KuK7Hd/xf3TJs5ycDjaImyD0cThFZIbMlHB A6ji5nxbK0i8gvqJ4b5kxKvG7wjvPNeWOZzxEjuIhNbhUSaqPGoChzsDsQqRyCBbDhDh LRMTrgcbjoxdo8xfXFew0uDyf6m5NNSkNeQoDMubGuRXspEowc47S0xuo/YvGtPkFK5l xpyzEsg0CwP1NHMSeYZyKEHfea+WSV9t2QhJuXiK86vtMgdwcKUZIQPb97JGVnIzZMFC ktrWWuEC2E8HbAw/ubToVUm3z1juApIChDkKTg4H1JwkAdWc7drR/8uHI+oDQ5SVgNnY lthA== X-Gm-Message-State: AOJu0Yw+UFCAF5P948r3HuSqGHzdb2NgAu8rVTW7HnaQy1s+XxSXhqHP JI1z5f3CPVgEKVbfWw3a/2+z7vh+YPrZimkxfb4Uh2J7yV9+zlUVe0A0cRzbtAxDzmYzmFqrIcB JF0+4dZp/WdVNcm++0Ptt/0AlNAbUCBNybU16iWYT4EmdlvOu2RzEgVY3lHLdaUNT3PyuQXzkqD D/Wg== X-Gm-Gg: ASbGncvgRDAa9sSJKVrkxMiiZ5Zlh0swUd9UPO/U6ZTJQEaGz7hxAltZRDXlb6cKQVp WHpvwK0Wr8XLVK2yhz2xoob8F5SV9PFdqRVR+B3IdP43VQv4AKZR6xhfkUBCaJWQvg5jOiHfvQ6 oGjdrzwKhJeNSr+A3p5kw5rSNPNsOTOGLSwjpM9xQa41Kof5NYiSgICXfvI9MvqQN2M7f4HAlcw 7BECnYo6hyBsgWGOSbSKZfKC74TfFVbLQL7XDodDs3qej+XSW4me2YYCAa06xXYlYgfoZkntjak F4YIsU340h3BQXEHrqwSq0BeuYG0FHYwkMyLdaAQzcSoYg+JK5h4lpVLNWGQutXEKmtI3dLEthl 2eLREMPx6Sxz8buBokBfCvPMU6O4K8uvM0hEGwX4mXC1Ymi5a0lHK6ETr X-Received: by 2002:a05:6a00:1742:b0:742:ccf9:317a with SMTP id d2e1a72fcca58-7487cf337c0mr4142703b3a.12.1749730293882; Thu, 12 Jun 2025 05:11:33 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHRbHr9q5jfCMz8iUPZ42irQlsWj9BNXo8BttjPRQ167qDe4cEZSXvdGPwf/UPvkR3kTmGO+Q== X-Received: by 2002:a05:6a00:1742:b0:742:ccf9:317a with SMTP id d2e1a72fcca58-7487cf337c0mr4142665b3a.12.1749730293435; Thu, 12 Jun 2025 05:11:33 -0700 (PDT) Received: from che-siroccolnx03.qualcomm.com (blr-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com. [103.229.18.19]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-b2fd6376366sm1189405a12.68.2025.06.12.05.11.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Jun 2025 05:11:33 -0700 (PDT) From: Maharaja Kennadyrajan To: johannes@sipsolutions.net Cc: linux-wireless@vger.kernel.org, Maharaja Kennadyrajan Subject: [PATCH wireless-next v4 1/2] wifi: mac80211: update ieee80211_rx_status::freq documentation for multi-radio Date: Thu, 12 Jun 2025 17:41:26 +0530 Message-Id: <20250612121127.1960948-2-maharaja.kennadyrajan@oss.qualcomm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20250612121127.1960948-1-maharaja.kennadyrajan@oss.qualcomm.com> References: <20250612121127.1960948-1-maharaja.kennadyrajan@oss.qualcomm.com> X-Proofpoint-GUID: IqFtav6J-hlVePDvoDXS5Xfvvizbdm1T X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNjEyMDA5MyBTYWx0ZWRfX02OUd8rz8VB4 pTqRZAlJ4jSuPxXasbef/vc637qZCEo9DS01R1dXtmz0uKavpQDAGLyGMt4CseYJGnZksD5VCFM YvA+ycz6tfB3GnqSaiMDlWcohhaILQK/vyL3u+OUraNnTYKbNxypnxWpA2PpHNdpYfZaOz2ndYm tj/ebcWG9MPBVRNXpXhKxbNQfAaSZy9AUqyF9SAE2i/yJEUSOD+yD4doTez2mu4+7/j3wzb9ldO IxuLZp7fXQgtVXKz8NJFF1Q6wExm26szRrEM0ZZg31q41Hq/VRuZP5nAeSF1qv5b75CwHc/Jl8G LVsF2u6SK+Q32FAX6speCywTulv8oDVuXfHglp/i0YnuaCXNNVeuh1QqS7luMOgA9qhdObhFO9H Z1cfzk/0s9BmdgxidNs70WAi1JCy8wTNFp743na9feQ9pBCEcCWz0jMV3Z2nMU5nxRrkPI8J X-Authority-Analysis: v=2.4 cv=GYkXnRXL c=1 sm=1 tr=0 ts=684ac3f7 cx=c_pps a=rEQLjTOiSrHUhVqRoksmgQ==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=6IFa9wvqVegA:10 a=EUspDBNiAAAA:8 a=G3GIQwjkmUm1iQ8NZroA:9 a=2VI0MkxyNR6bbpdq8BZq:22 X-Proofpoint-ORIG-GUID: IqFtav6J-hlVePDvoDXS5Xfvvizbdm1T X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-06-12_08,2025-06-10_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 phishscore=0 spamscore=0 mlxlogscore=999 bulkscore=0 impostorscore=0 clxscore=1015 malwarescore=0 priorityscore=1501 mlxscore=0 adultscore=0 lowpriorityscore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2505280000 definitions=main-2506120093 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: With multi-radio device, it has been observed that the group-addressed management/data Rx frames, which are actually received on one band, are getting processed on an interface running on a different band. This occurs because there is currently no check to ensure that the sdata is running on the same band as the frames are received on before start processing those frames. Update the documentation of ieee80211_rx_status::freq to make it mandatory for group-addressed data frames in multi-radio device. Drivers such as ath12k and mediatek(mt76) are currently supporting multi-radio and report ieee80211_rx_status::freq in their Rx frame indication to the mac80211 driver. Signed-off-by: Maharaja Kennadyrajan --- include/net/mac80211.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/net/mac80211.h b/include/net/mac80211.h index 82617579d910..9212c2089638 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h @@ -1612,8 +1612,10 @@ enum mac80211_rx_encoding { * it but can store it and pass it back to the driver for synchronisation * @band: the active band when this frame was received * @freq: frequency the radio was tuned to when receiving this frame, in MHz - * This field must be set for management frames, but isn't strictly needed - * for data (other) frames - for those it only affects radiotap reporting. + * This field must be set for management frames, also for group + * addressed data frames in case of multi-radio device, but otherwise + * this isn't strictly needed for data (other) frames - for those it + * only affects radiotap reporting. * @freq_offset: @freq has a positive offset of 500Khz. * @signal: signal strength when receiving this frame, either in dBm, in dB or * unspecified depending on the hardware capabilities flags From patchwork Thu Jun 12 12:11:27 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maharaja Kennadyrajan X-Patchwork-Id: 895903 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 27AF42367B0 for ; Thu, 12 Jun 2025 12:11:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749730300; cv=none; b=YfJBiZiH+9wWlyElaiPuKEEQEzGBvhL/rwbzYJD5YFaSGRqlOBVW5Wmmvb9yIOQ2Buvr/DZuiQxk6LwFCrORUHH3OltxVh/3gYXepFbMukVWK272j9qjywI+tk5YtGLVeFf/RrMS0U2Zbzjb0S/B+SMIiSVAHVld8GBSO0jj5wA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749730300; c=relaxed/simple; bh=/QbNC5oeb4PozRW2qgEaqaQm5eC5ECcXH/Vk+7Prrno=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; b=FSbRso2HDIaPUoEBg827bA1RPwWHlxTE6RM9yjtXjb5o6ERKlrKDw0PMQe2OBUW8lx3mN7uqWZtG4ZfiulauVo8hAykjnjshBwePS6UYD3uVjAYvVJDhxDYuKZ1Jb/aU1oCCEPgESOyvvsIBGw3YeAY2yRnPpgpETOSklMUPUOk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=UcuBZRx/; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="UcuBZRx/" Received: from pps.filterd (m0279869.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 55C96KNv002604 for ; Thu, 12 Jun 2025 12:11:37 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:date:from:in-reply-to:message-id:references:subject:to; s= qcppdkim1; bh=yU7oSJGLbh4FW8bBDKQJ7R0JGuTvyQFJtUW2RLYDSCI=; b=Uc uBZRx/vcHRjsKhrt8KnNc6N1HU6MUwF6n1+lNlJ/bfB6qY5fXemHtYKPyEQKzk3n jxJPxNtHOgm2tasbYIADZux/PxZKhbHDjKDVJH9U4j5q0zRBq7ckWbJg6a7O5KB6 yPfvTydyNWR1fENnoDFcfRN1F3BIVtbYcdi5CwzV563Qe+LVnyGEF++H1VnHwHPQ LY63jT9cMFlZX03/bDwaPFxkf2JizMWeew+hskbA8wQVdYby6/VI/W4AmQSe8sNw SjfKD5wFma18/HKmVO74cDHWjaWgvJHkEjAeko5LpgZwUq9/j6OeD2q/9XJ9ivid Vlkz84+NZGNmvpTwFqYA== Received: from mail-pf1-f198.google.com (mail-pf1-f198.google.com [209.85.210.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 477jbphxba-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Thu, 12 Jun 2025 12:11:36 +0000 (GMT) Received: by mail-pf1-f198.google.com with SMTP id d2e1a72fcca58-74877ac9ca7so902895b3a.1 for ; Thu, 12 Jun 2025 05:11:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1749730295; x=1750335095; h=references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=yU7oSJGLbh4FW8bBDKQJ7R0JGuTvyQFJtUW2RLYDSCI=; b=VtLHi97NgySivIeZHOBpcrNtPPnGeYZVdRP5JhTJ5XWUgMUgt/EFbeH1KENDk0Cc0v f+CBiUqIHlwWADBoyaFIllDA3kRw9EhLkpP+da1epjD326ogNMyJXXi+TleIa3larVE1 gv9TAx+VeiCygrQoqjhs88iWmbuZuWflVxBlBPjGqU+8fy2sqzaVgctVmyKhc8dsCEoR 184fq/J/1Hb4DREbJJ6W82a+izegRRZoWiTpO1jjTsG3EINvAeql+tb4BMY6awKdVVV4 R30UgtsL4lXYj6afW4zQE1hJ3xX5jkIYaw9GPAgv2kNOpjuXi76Nm4hOHsoNdc7qqkFV z9vQ== X-Gm-Message-State: AOJu0YycZxzDZJUEobM9rmxDDkdIVFqN9YIhxNcJ40BnuSKer7nnv663 fgXWjJTsysFEM9EEK9Q911+W7lCtiBs+TF7ALwqA2soYIe5hcI8wW6uielKGWfBIHKoEAQVX83j 00q2a7SQlu5nsEyJ9D7X5BEdDgTwUsW8ln+nKhx79Ce/EnuadZraVLmMDok22lChmG3i+kA== X-Gm-Gg: ASbGncvVmmij3PHyOg8u9rlOQqMatdoEnwAasfBex+yKFCYOaxyoU5D609iBlvQoUwO AZ6O2EEjR2PdTDDJWgzawV7zdJV0N6iQ0UJAdDy4xXbTlC9FREPDJaVSiV+3RSdt5erLs4FEUqr MkqGCA5gUTDt8dEBpJO2/25Ku/OCOy60l3hZYL3oXOMcJt1nkfVbAN+wRq1ottyBnA7vIuVCrYB nzvrw4NTG6VYizpzP7sc8mlT7PkLMmWl6+Oo0889Cnhyl5sVkETrKq5ZYx4RUqGbuZ5PlQTiVSV YnGe/PsdRvc9hscM4wG7zOTzLpJOd4ee5On5GU+v0M9kAsdimteHp7BZFB/TDEQoaNTOQiM0Sc5 UuF13LrWrKOieyJ53+4a1fCeSEqJJZo/xQ2Yz6wojhznTbjeDIUjuvNbC X-Received: by 2002:a05:6a21:4006:b0:215:d1dd:df4c with SMTP id adf61e73a8af0-21f9900abcdmr5060924637.6.1749730295557; Thu, 12 Jun 2025 05:11:35 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEZt26IwlLJ/jeX136unBPZvhI/cBP9yckghD2HkZuBIJqgoRjVPIvIXz1/vuHEs257SPO76g== X-Received: by 2002:a05:6a21:4006:b0:215:d1dd:df4c with SMTP id adf61e73a8af0-21f9900abcdmr5060880637.6.1749730295147; Thu, 12 Jun 2025 05:11:35 -0700 (PDT) Received: from che-siroccolnx03.qualcomm.com (blr-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com. [103.229.18.19]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-b2fd6376366sm1189405a12.68.2025.06.12.05.11.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Jun 2025 05:11:34 -0700 (PDT) From: Maharaja Kennadyrajan To: johannes@sipsolutions.net Cc: linux-wireless@vger.kernel.org, Maharaja Kennadyrajan Subject: [PATCH wireless-next v4 2/2] wifi: mac80211: process group addressed Rx data and mgmt packets on intended interface Date: Thu, 12 Jun 2025 17:41:27 +0530 Message-Id: <20250612121127.1960948-3-maharaja.kennadyrajan@oss.qualcomm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20250612121127.1960948-1-maharaja.kennadyrajan@oss.qualcomm.com> References: <20250612121127.1960948-1-maharaja.kennadyrajan@oss.qualcomm.com> X-Proofpoint-GUID: D5GOKh339iy6lk-9kTBmt7kaZeNW_P4B X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNjEyMDA5MyBTYWx0ZWRfX3K58kH8U0NTa yH6WfRBbcllGyTrEC78Eco6IVNPxN1gfF0naTfaEchyn5MoOxqun8poDEWAH0oIAWbUJCWeu/V8 C6PNGT0gMlGWeH6I/gjfhaI3j3X25vk0WkPbE6tqt+qHohSOZqH8Nb0dFFWEkbuw41SVmdHTN+Z Uu3qoRMVBsCgN/QMxtOaHHMuD3KzhT3ZuQk7ief7MMbmoCvU+3ud44PZnE/QZyC9urj8mj+gETL 6XSMM27hi1CIZpPRYary2LRlsMjobGzwtLaZlaGQF0EuwAPrl/B1mVUBJnkZVVWMhtm0AI2hFpd +BBj0JzUDSoyAVDsmwkhUcMBUA+36uh7wWhM6nDPMx9bXps9eGEiSxKcvlphlvpVbUAJhZ43GUR OBYDP+USqm93aLfshJIll1tNDhxbCTYuJch2uDUny1ziGYXJMzmzlkSQJaprnkjtTKonOWMV X-Proofpoint-ORIG-GUID: D5GOKh339iy6lk-9kTBmt7kaZeNW_P4B X-Authority-Analysis: v=2.4 cv=OLgn3TaB c=1 sm=1 tr=0 ts=684ac3f8 cx=c_pps a=m5Vt/hrsBiPMCU0y4gIsQw==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=6IFa9wvqVegA:10 a=EUspDBNiAAAA:8 a=uuzzVUd8oATLJfYfrdoA:9 a=IoOABgeZipijB_acs4fv:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-06-12_08,2025-06-10_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 priorityscore=1501 impostorscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 mlxlogscore=999 suspectscore=0 adultscore=0 malwarescore=0 phishscore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2505280000 definitions=main-2506120093 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Currently, in multi-radio devices, group-addressed data and management frames received on one band are getting processed on an interface running on a different band. This occurs because these frames do not have the destination station information, unlike unicast Rx frame processing where the transmitting station is known. There is no check to ensure that the sdata is running on the same band as the frames are received on before processing those frames. Fix this by checking the operating frequency of the interface against the frequency of the packets received before forwarding them to the interface in multi-radio devices. The current behavior is retained as a fallback mechanism when the frequency is not reported by the drivers. Signed-off-by: Maharaja Kennadyrajan --- net/mac80211/rx.c | 50 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 42 insertions(+), 8 deletions(-) diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 09beb65d6108..b4f715040983 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -5125,6 +5125,32 @@ static bool ieee80211_rx_for_interface(struct ieee80211_rx_data *rx, return ieee80211_prepare_and_rx_handle(rx, skb, consume); } +static bool +ieee80211_rx_is_sdata_match(struct ieee80211_sub_if_data *sdata, + int freq) +{ + struct ieee80211_link_data *link; + struct ieee80211_bss_conf *bss_conf; + struct ieee80211_chanctx_conf *conf; + + if (!freq) + return true; + + for_each_link_data(sdata, link) { + bss_conf = link->conf; + if (!bss_conf) + continue; + conf = rcu_dereference(bss_conf->chanctx_conf); + if (!conf || !conf->def.chan) + return true; + + if (conf->def.chan->center_freq == freq) + return true; + } + + return false; +} + /* * This is the actual Rx frames handler. as it belongs to Rx path it must * be called with rcu_read_lock protection. @@ -5264,18 +5290,26 @@ static void __ieee80211_rx_handle_packet(struct ieee80211_hw *hw, * the loop to avoid copying the SKB once too much */ - if (!prev) { - prev = sdata; - continue; - } + /* Process the group addressed management and data packets + * in the intended interface when the operating frequency + * matches with rx_status->freq in multi-radio devices. + * If rx_status->freq is not set by the driver, then + * follow the existing code flow. + */ - rx.sdata = prev; - ieee80211_rx_for_interface(&rx, skb, false); + if (ieee80211_rx_is_sdata_match(sdata, status->freq)) { + if (!prev) { + prev = sdata; + continue; + } - prev = sdata; + rx.sdata = prev; + ieee80211_rx_for_interface(&rx, skb, false); + prev = sdata; + } } - if (prev) { + if (prev && ieee80211_rx_is_sdata_match(prev, status->freq)) { rx.sdata = prev; if (ieee80211_rx_for_interface(&rx, skb, true))