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 446A21C5CA5 for ; Mon, 9 Dec 2024 15:37:42 +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=1733758663; cv=none; b=XBnIMnbJvrmhPQan3PP69mXSVV8dCPh8NKYF91Wb6ZHzHVaPLbLvJ0VOlvVwZVnJgsPcbzQ47vyNfjB7UZqaYT8P9qlnTFc/nC4lFdkwNmNrmsfIjuw7bTBpPnbdpElMao/ft6EzOCHspqqHG7EzBmpDMjOubGs3PILxZcP1+fo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733758663; c=relaxed/simple; bh=cXpfKad7ahdOsjhCoNvLsP9akGn3j6cxcJ0cD82I8co=; h=From:To:Cc:Subject:References:Date:In-Reply-To:Message-ID: MIME-Version:Content-Type; b=m10FYW1U5cQFEUzUyIK1Q81CYV6Z7gDWbID4AIbmAz9aovDl4YqYjDJBAjspEUH3r+nGw2ZN8bar1BUshyxWeZnhwMjcOAcSUAirqKu96suzUBKyK4AXYFUVpaukz/0mSDrwNzEToqgitx7xZGfBRBeD2z+ZUuZc/AxFWYGQqbA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=nd+XeR4u; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="nd+XeR4u" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 22D33C4CED1; Mon, 9 Dec 2024 15:37:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1733758662; bh=cXpfKad7ahdOsjhCoNvLsP9akGn3j6cxcJ0cD82I8co=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=nd+XeR4u4fWoq3FzdBO50fYSn4o3+gZdL4MRRWbuRc0rB0IL4jMU9yIGv9LDBCAbG Rzp6hZ+NzdSCT6lcr0806Tv0uQU0ZUhk6Ui7DJ3BaG97+54pt7cvME+8TRIgLSbpzK 8ISTTRAhn/Z49zdozu7N/JuanYFw0QfO6F4pKLy0nLhv6Vun8g9EHbZ/BIgp6Q3qxB mdVwz7Ov1BZebPT1wlGinm+/VFd0EcGhU+JbCIW2TvSGIO1QZCA1ZBWELd9s7RnoGs nN8Ga3b4x/Owc4VANDL4so8Acv/No/i2qGzvUEv2jo7S2lukbE6gYGkC2TSi9nrbx6 YgkoAPygtazkQ== From: Kalle Valo To: Baochen Qiang Cc: , Subject: Re: [PATCH] wifi: ath12k: fix leaking michael_mic for non-primary links References: <20241206054552.177424-1-quic_bqiang@quicinc.com> Date: Mon, 09 Dec 2024 17:37:40 +0200 In-Reply-To: <20241206054552.177424-1-quic_bqiang@quicinc.com> (Baochen Qiang's message of "Fri, 6 Dec 2024 13:45:52 +0800") Message-ID: <87ikrssw8r.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain Baochen Qiang writes: > In ath12k_dp_rx_peer_frag_setup(), commit ea4192553850 ("wifi: ath12k: add primary > link for data path operations") checks whether a link is the primary link, and > returns directly if it isn't. In ML scenario where we have non-primary links created, > this results in leaking the michael_mic info since it is allocated by default but > could never be freed for a non-primary link. > > Note that we can not move the might-sleep allocation after primary link check since > there we are in atomic context (due to spin lock). So keep the default allocation, > and then free it before return to fix this issue. > > Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4 > > Fixes: ea4192553850 ("wifi: ath12k: add primary link for data path operations") > Signed-off-by: Baochen Qiang Acked-by: Kalle Valo -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches