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 3F1CB63CB for ; Wed, 18 Mar 2026 00:46:50 +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=1773794810; cv=none; b=b0W1WXb/Vynncr09gFe1G7YFyrvpMb0mmYUtOPrHVIX9ufI1fxVGw7AABh7Pey3NqP1DiJQtigtwMXE9lh0EulpHh2rnk2qqv+ftS2E2PX5LyePhxQPRV5yOfxZ2ta1ci+O2MyaLkqRp0FrIOAA0RiM3e6Ode80w00YjxCTdoek= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773794810; c=relaxed/simple; bh=nu5V9txB2lTknRc1Zna4Z4zJoICLCBp3mRzjTzJgaEM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=l4K+dm84O69163vWB+5fayCTuAh+AtQ9BK8pymt76lcrol//0CHnhjWUFwVoVLqyubZovzy2cLGX8bY21/WS7kN9fISB6bMD9U2MWPe0kyJFtucVs0QqWW37kvPSoenz0vYhU3lNxZRR+8NRojISokGWyj/z4/nez16AINXY2zc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=CVcVxsuL; 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="CVcVxsuL" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 10338C19424; Wed, 18 Mar 2026 00:46:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1773794810; bh=nu5V9txB2lTknRc1Zna4Z4zJoICLCBp3mRzjTzJgaEM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CVcVxsuLrLopECFyxarpjkh0DHpX/FX9iUHGhY5zvpz7Pt67Dkds7fP/3h7yTdiEG iidpLbrSQHnwLqTIz46rS9FSvV9K2DKUe8heFILGoVAyi5iNabzLZLCvexf0S+d7Z6 Oz2C09dx9cCuI+PFf7SbHfv+Y4elFci4hHWlmx6UwxS7L23K7OXHJxeyyxWZyTtSaH ppygh2Sq8iZdUIDjjvhuxIKsD9agA7tDm8Q32X0kc1ncT32JGwuzrznosczsCVslov rY29pKMge2vAtKSHwupZS7lBVZFaBDNZxsql+FihEweGiL6eicLRSa2U/1Bfw5FR8z QktxcQTDY4UoA== From: Sasha Levin To: stable@vger.kernel.org Cc: Jakub Staniszewski , Michal Schmidt , Dawid Osuchowski , Aleksandr Loktionov , Przemek Kitszel , Paul Menzel , Rinitha S , Tony Nguyen , Sasha Levin Subject: [PATCH 5.15.y 2/2] ice: reintroduce retry mechanism for indirect AQ Date: Tue, 17 Mar 2026 20:46:46 -0400 Message-ID: <20260318004646.408222-2-sashal@kernel.org> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260318004646.408222-1-sashal@kernel.org> References: <2026031702-configure-decorator-0097@gregkh> <20260318004646.408222-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Jakub Staniszewski [ Upstream commit 326256c0a72d4877cec1d4df85357da106233128 ] Add retry mechanism for indirect Admin Queue (AQ) commands. To do so we need to keep the command buffer. This technically reverts commit 43a630e37e25 ("ice: remove unused buffer copy code in ice_sq_send_cmd_retry()"), but combines it with a fix in the logic by using a kmemdup() call, making it more robust and less likely to break in the future due to programmer error. Cc: Michal Schmidt Cc: stable@vger.kernel.org Fixes: 3056df93f7a8 ("ice: Re-send some AQ commands, as result of EBUSY AQ error") Signed-off-by: Jakub Staniszewski Co-developed-by: Dawid Osuchowski Signed-off-by: Dawid Osuchowski Reviewed-by: Aleksandr Loktionov Reviewed-by: Przemek Kitszel Reviewed-by: Paul Menzel Tested-by: Rinitha S (A Contingent worker at Intel) Signed-off-by: Tony Nguyen [ kzalloc() => kmemdup() ] Signed-off-by: Sasha Levin --- drivers/net/ethernet/intel/ice/ice_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c index 75b54bef8be3a..3f16b80308f92 100644 --- a/drivers/net/ethernet/intel/ice/ice_common.c +++ b/drivers/net/ethernet/intel/ice/ice_common.c @@ -1422,7 +1422,7 @@ ice_sq_send_cmd_retry(struct ice_hw *hw, struct ice_ctl_q_info *cq, if (is_cmd_for_retry) { if (buf) { - buf_cpy = kzalloc(buf_size, GFP_KERNEL); + buf_cpy = kmemdup(buf, buf_size, GFP_KERNEL); if (!buf_cpy) return ICE_ERR_NO_MEMORY; } -- 2.51.0