From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 234DF314D0D for ; Tue, 21 Apr 2026 17:32:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776792774; cv=none; b=ua1rcRfgxX8tAXgYYkci+0gj5lEZFRSqf/EwtaU1ZEEb1cd7rqT//wIE1VGKY6AcCH4Wa4+jWVUkUIbJK6WekdEeVZ2TAGY+xKIbxBN+f78wO8iFqYOfeDhpV5HS23bplNVnXCI3Z01tmTDtyfDVHok9ShUecKEfbunH6rnOR8w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776792774; c=relaxed/simple; bh=/Ba3EWb30hnk7KFV4mh/GjZJGnrFEQ1WOb7ya6fOX7U=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=W0FaJ1KGkmkAZKhDHl1f/3UaXcsHywf+B2ibSgBAwuy5P7Py2z3oWL+j+KiaYVT+M6iOcESBNJw1AHNMoueBwsGgnr51Dxa4bZs6357Rs0eVfBbL5RPqgL34gBe6rFHoe4lUqAYkzKPrYLus5N/FrUAAEGQUxHYGFaLPFljZXGg= 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=QS1e8+mp; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=HM65o6Sf; arc=none smtp.client-ip=205.220.168.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="QS1e8+mp"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="HM65o6Sf" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 63LH2xB51834872 for ; Tue, 21 Apr 2026 17:32:51 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= URbrxLq/NhhyYFTtqjb5hgyP/ewhb68e/QnrFe61sLQ=; b=QS1e8+mpvTYDjLbI xBjSEijM1o+jWC55zG9SWLVLY83eP+tP725VAEMlhVXgrcn+abz3kKFGYxGcZS2Z nGSkalD/gFqNdhkCNZrhy4it6WuRCW+iPpJYayUglXGT6Cbxn/kixJ5iDld5vNIs lIWhGLifnNHQdWbQyKJtrjSG/+3qr/XCsbfx85cOg+ZzNdkQymT0hD9CTabVefrF 5IHeVJYJi3GJdUEAaWnZYUIY1+zZtddg0aZOAbWaFeNXNSENAl9EsH3PgMiLIN6t n2f8vZWfZAihWck1OOoTbAfdnCIdKr24JQpmTr+Qs524pDnDLz+D9EUnnsVRSKk2 EJ2t2Q== Received: from mail-pl1-f198.google.com (mail-pl1-f198.google.com [209.85.214.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4dp76gsmsj-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 21 Apr 2026 17:32:51 +0000 (GMT) Received: by mail-pl1-f198.google.com with SMTP id d9443c01a7336-2b2e06219cbso55985835ad.3 for ; Tue, 21 Apr 2026 10:32:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1776792771; x=1777397571; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=URbrxLq/NhhyYFTtqjb5hgyP/ewhb68e/QnrFe61sLQ=; b=HM65o6Sfc7jzwFEWWDwl+sc4Nddj7Dlr767BVD9IwboV5BrHZYminsJtYxKGWSfQwn DFl7C1H2HgoJ1uWIqhgMkzlAIy0n2bIao22GEeQkbgCw7NHlmmwXwVj4YFCuIztvDfTe EhCP/fYUtvih/8w1xyFhZIAfouEjTPaOnWXcmaeGM58c/nAz6s31zmoI8S74Qfb0aG9D v/HXTzAvl5xefchn4k6aVKULtkAlMd4TWu3IkLGxNHq8UrRUz13L/kfyUsWrnSC855VK FbnA22FFYg/wOgRyMLhryo+2sfMvyYxc97HrtTvgKnIqcZhvp682g9Tmk0H5o7dEsldt hQww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1776792771; x=1777397571; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=URbrxLq/NhhyYFTtqjb5hgyP/ewhb68e/QnrFe61sLQ=; b=bvb11VSsPs2N7YjzICdaHseFrsJtDvp40JMyvYQDTFpiQRchvLHjA5BnQuqNuIAxPT aeAQR3hgCuFqGCrJ8eC97b1ywtJ1ao1zCs21OuX3xZdH4EyhwRIXfNHF2rQGKKPHxIin vtrHAr/+klykbHeG03DVVWuTjy1LTOZYuWaFJeN2tZAGHmUcz561rSKUPmY2pJj6uvEm e9ICPr1YOvPUcskj+vKLFrCk8mbmyCRMkf0zMfrdLP0hEGgwbST0DsSwZh5eN1epKwJ7 IbN4ZKQS+LsmTEhmVrHAebBADMQJ6V98eI6LQAkukEjPVzzY96sxRX3wjbN/HVizzxYA iIuA== X-Forwarded-Encrypted: i=1; AFNElJ8bZTtiBKqRIgeeCMYoD1JnE/B2VfsVLMdhcCpEHAuKgWriP3pJ/mtLpaheZ+6sQVccYKMgq+KCRFEJTxI=@vger.kernel.org X-Gm-Message-State: AOJu0YzlKYfgqIahOBvmZ6md12OYXAm9Q3aJ44D1Kq8NKJg/ly3xr/zp Q/J3Gs4ErbNuWE0DDCyaVmRDcY/QYSwPM8OLM5syPaGNtn1WjNbPi5oi2UQ2U8dJD9YirbJzvqy r9U+VtpOH1eLyfMI63NIaHBeF787DqeQQqNqQ3v35yp5f4bHmZwZgol2t7AYjjM/Va2g= X-Gm-Gg: AeBDies2oD3a3qxUtsqv3hWehhFIHAV7nPjkqfEuDL8yPKgQqBVGvgkl74fjBxfcpLs OvH5I3AmFJr8bRAVtFTtF6Y2db4ZU2R4jS3syptgzQy/FZB8dVp8mefwsR8od0dXVtjYfaw0IbR Bej97CWf3wD3asO3KfWVexXb97k/V22d5sabPwuHGemjJbbjanwWRVItNljCAaemK1J7yuU6sHJ rej5Zb/1iCfKWJHIIKcp+eAhE5UL97ukuhfHzRlz/kMTtdRSKOgytkxT26sF7AUHiLb4c1UoKo+ AVy9hVoLbYGzNnpNpUlJtuO+mwW8vUySxN9YQi4dq/iYTukEPL1E947+SGqS7wruaPXFXfUF9Q2 ZkQwrsbi51SXR6ASksFUYZipBuqJuv61DTsTZY1DkgTSkkoDuDshasw9/N8ZHbMe3ZeuzfBY/Aj 9i X-Received: by 2002:a05:6a20:4326:b0:39c:cf9:b8e4 with SMTP id adf61e73a8af0-3a08d8f5a50mr22898228637.42.1776792770680; Tue, 21 Apr 2026 10:32:50 -0700 (PDT) X-Received: by 2002:a05:6a20:4326:b0:39c:cf9:b8e4 with SMTP id adf61e73a8af0-3a08d8f5a50mr22898185637.42.1776792770063; Tue, 21 Apr 2026 10:32:50 -0700 (PDT) Received: from [192.168.11.106] ([124.123.81.173]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-c7976f8f3e5sm11200099a12.5.2026.04.21.10.32.45 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2026 10:32:49 -0700 (PDT) Message-ID: <1016fbd7-be27-44b1-9eb8-6201c9495f1a@oss.qualcomm.com> Date: Tue, 21 Apr 2026 23:02:42 +0530 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] wifi: ath12k: fix false positive RCU warnings on PREEMPT_RT To: Yu-Hsiang Tseng , Jeff Johnson , ath12k@lists.infradead.org Cc: Baochen Qiang , Rameshkumar Sundaram , Kalle Valo , Sebastian Andrzej Siewior , Clark Williams , Steven Rostedt , linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rt-devel@lists.linux.dev References: <4cdf2e61-fe69-4168-9df7-55bb71585dfe@oss.qualcomm.com> <20260421172500.1050754-1-asas1asas200@gmail.com> Content-Language: en-US From: Rameshkumar Sundaram In-Reply-To: <20260421172500.1050754-1-asas1asas200@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNDIxMDE3NCBTYWx0ZWRfXydzRazSaTN2r Itqx5xxmG9WK6XqpU3O/lSi94jLB22njPRCTYz36kQe7x+7OyJJ04i7GLuidFz/kvhWjQRak5xD 1bK/qhhkf4o8VhbJ77oi5GVDC3oNWer62ggops96bCVug0x6HyOnhVflQt3Yf/dymgspACHhhRQ HNoM3/ptcF8h2f/rNwbzd20FdSo9jeV37Yt8yon5DCSQJYCjMf5BrG9R4JjG71N/GVApgRcqbgI GeNgka39uE+H0QHZEi0vXOxRVYpOuLA4TYXi1PsFY1ZvgkQVPLU6+i6OUr+nOkq/y2LR7AwZiZv dk658c0LnFyJze8km4yAUVj/bg8xtSLNnAqvVj7nM3J3cpRIkAjcVgnj1ETHXhgpaXQvkLa0Czz N7O0lICM5SKrfsuTFk89G3WTT12YHWRpQaHQd++hot2JYF5wn5bNNNnsoD0o5HQzqvRSz9+vzVb k5rMTQCVa/RQburQOjg== X-Proofpoint-GUID: G40SfEUYr19rnkzexz13QULDmvI0cLH- X-Authority-Analysis: v=2.4 cv=crWrVV4i c=1 sm=1 tr=0 ts=69e7b4c3 cx=c_pps a=MTSHoo12Qbhz2p7MsH1ifg==:117 a=R7zuFBDiW8lgADV909h7jA==:17 a=IkcTkHD0fZMA:10 a=A5OVakUREuEA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=DJpcGTmdVt4CTyJn9g5Z:22 a=EUspDBNiAAAA:8 a=pGLkceISAAAA:8 a=akWcTCgZTv-KWhlo_GAA:9 a=QEXdDO2ut3YA:10 a=GvdueXVYPmCkWapjIL-Q:22 X-Proofpoint-ORIG-GUID: G40SfEUYr19rnkzexz13QULDmvI0cLH- X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-04-21_03,2026-04-21_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 lowpriorityscore=0 clxscore=1015 impostorscore=0 priorityscore=1501 spamscore=0 phishscore=0 bulkscore=0 malwarescore=0 adultscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2604070000 definitions=main-2604210174 On 4/21/2026 10:55 PM, Yu-Hsiang Tseng wrote: > Two functions in ath12k assert that the caller holds an RCU read lock: > ath12k_mac_get_arvif() and ath12k_p2p_noa_update_vdev_iter(). Both use: > > WARN_ON(!rcu_read_lock_any_held()); > > On PREEMPT_RT kernels built with CONFIG_PROVE_RCU=n, this produces a > false positive splat whenever these functions are invoked from paths > that do hold the RCU read lock (e.g. firmware stats processing or > mac80211 interface iteration). > > Root cause: > > - On !PROVE_RCU, rcu_read_lock_any_held() is a static inline that > returns !preemptible() as a proxy for "in an RCU read section". > > - On PREEMPT_RT, rcu_read_lock() does not disable preemption. A > task can therefore be preemptible while legitimately holding an > RCU read lock. > > - Callers such as ath12k_wmi_tlv_rssi_chain_parse() (via guard(rcu)()) > and ieee80211_iterate_active_interfaces_atomic() do hold the RCU > read lock, so these warnings are incorrect. > > Typical splat seen on a WCN7850 station with periodic fw stats > processing: > > WARNING: drivers/net/wireless/ath/ath12k/mac.c:791 at > ath12k_mac_get_arvif+0x9e/0xd0 [ath12k] > Tainted: G W O 6.19.13-rt #1 PREEMPT_RT > Call Trace: > ath12k_wmi_tlv_rssi_chain_parse+0x69/0x170 [ath12k] > ath12k_wmi_tlv_iter+0x7f/0x120 [ath12k] > ath12k_wmi_tlv_fw_stats_parse+0x342/0x6b0 [ath12k] > ath12k_wmi_op_rx+0xe9e/0x3150 [ath12k] > ath12k_htc_rx_completion_handler+0x3df/0x5b0 [ath12k] > ath12k_ce_per_engine_service+0x325/0x3e0 [ath12k] > ath12k_pci_ce_workqueue+0x20/0x40 [ath12k] > > Replace the WARN_ON() with RCU_LOCKDEP_WARN(), which is gated on > debug_lockdep_rcu_enabled() and therefore compiles out entirely > when PROVE_RCU is disabled. PROVE_RCU kernels continue to get the > full lockdep-based check. > > Fixes: 3dd2c68f206e ("wifi: ath12k: prepare vif data structure for MLO handling") > Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.1.c5-00302-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.115823.3 > Suggested-by: Baochen Qiang > Signed-off-by: Yu-Hsiang Tseng Reviewed-by: Rameshkumar Sundaram