From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 5F77024C060; Mon, 23 Jun 2025 13:27:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1750685234; cv=none; b=nu9HL2kPUFgsVvAh6OX0T+QPoSxWsk7IHtk388qn8nwSryu6cJJVUbyYiUy8siXdAZA7VcPMnnLaQ6YX3lEORR29zBqE6gUH/YKMepi+00sortqDSrdmQyLwgdYEFYhpHx4spn2sUpYyxbP5D9Ia31D30+w6yAovrf/80EL9Zd8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1750685234; c=relaxed/simple; bh=dWI6xyN7Do1+jsMq1GpIYplLOD+WpFMlSMfRhJKRxZI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=L8gWuUgqNkN0vGwKi/ENWMI05f+SZ1me/63zIlUDp+IUXUkBStmp9RtMyWv8KZ5LaMjOUeDh3Ad5WypxPHNqdD1r9nJ1aIxG6A88OjKFP5vkQqCOeoBsWbV4yQhX/8+QoRWm6CW2Kfb4d6P41+I73eUMkQeBaVyzyc43ppJ4fIA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=qYJ0yOzm; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="qYJ0yOzm" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E6470C4CEEA; Mon, 23 Jun 2025 13:27:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1750685234; bh=dWI6xyN7Do1+jsMq1GpIYplLOD+WpFMlSMfRhJKRxZI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qYJ0yOzmuvqTcS3JrNatmZlypQjwmrIrTLchK4KqSGzJERE5uRtjJLJYJ7XAyfJlY L//y7WvV3gRTBzTjPjDDa/EKgtXyz7zuC2hX5DgHD+17k6Zd0cYa4fNSs3WAqRUDjM TdgF6OdjuaiM28he6LODHknW+uz/H05fnZoU8100= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Ping-Ke Shih , Dmitry Antipov , Sasha Levin Subject: [PATCH 5.10 037/355] wifi: rtw88: do not ignore hardware read error during DPK Date: Mon, 23 Jun 2025 15:03:58 +0200 Message-ID: <20250623130627.941162715@linuxfoundation.org> X-Mailer: git-send-email 2.50.0 In-Reply-To: <20250623130626.716971725@linuxfoundation.org> References: <20250623130626.716971725@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.10-stable review patch. If anyone has any objections, please let me know. ------------------ From: Dmitry Antipov [ Upstream commit 20d3c19bd8f9b498173c198eadf54580c8caa336 ] In 'rtw8822c_dpk_cal_coef1()', do not ignore error returned by 'check_hw_ready()' but issue a warning to denote possible DPK issue. Compile tested only. Found by Linux Verification Center (linuxtesting.org) with SVACE. Fixes: 5227c2ee453d ("rtw88: 8822c: add SW DPK support") Suggested-by: Ping-Ke Shih Signed-off-by: Dmitry Antipov Signed-off-by: Ping-Ke Shih Link: https://patch.msgid.link/20250415090720.194048-1-dmantipov@yandex.ru Signed-off-by: Sasha Levin --- drivers/net/wireless/realtek/rtw88/rtw8822c.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/realtek/rtw88/rtw8822c.c b/drivers/net/wireless/realtek/rtw88/rtw8822c.c index abed17e4c8c7b..a7fc2287521f0 100644 --- a/drivers/net/wireless/realtek/rtw88/rtw8822c.c +++ b/drivers/net/wireless/realtek/rtw88/rtw8822c.c @@ -3157,7 +3157,8 @@ static void rtw8822c_dpk_cal_coef1(struct rtw_dev *rtwdev) rtw_write32(rtwdev, REG_NCTL0, 0x00001148); rtw_write32(rtwdev, REG_NCTL0, 0x00001149); - check_hw_ready(rtwdev, 0x2d9c, MASKBYTE0, 0x55); + if (!check_hw_ready(rtwdev, 0x2d9c, MASKBYTE0, 0x55)) + rtw_warn(rtwdev, "DPK stuck, performance may be suboptimal"); rtw_write8(rtwdev, 0x1b10, 0x0); rtw_write32_mask(rtwdev, REG_NCTL0, BIT_SUBPAGE, 0x0000000c); -- 2.39.5