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 5527E2D7DE4 for ; Fri, 20 Mar 2026 08:58: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=1773997094; cv=none; b=MwdJwh7nzOyuKl7BixInqJJaQxFHwdAzH5MN15u2yDKWbcF3u7J7skSSPRmBoOMDbzmXI+Oeq5fEyYYelSwdSStU7a+pTqLxw5QY6DZY1mq5j+GdIRCyrRd4kxkqAGlmxo3cxU5nW6TyCRiQSayziqnCW5txpQTXd9JtGxVkD/U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773997094; c=relaxed/simple; bh=vWD1bZFC2UCTq/YyWnEY3oWpuQ/0W2n9KB7fb2hqbB8=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=i7IdLB70p683Ma3wwrnkzmBAvxFrwQy9YnBQ9Yt6ZBu1/4DfnhG2TyNLCOsxWfYXwjm1KDMr7z+sfhj2ycpH3/kLsZmb8AbG/ifkDua5VbMdWPZi4QYuxcTrtuXZNg1Y93vkZq8FlWgjYWFf/Rorin4q1rnidaArm+eUUKAP5wU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=rJUg7prc; 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="rJUg7prc" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 41024C4CEF7; Fri, 20 Mar 2026 08:58:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1773997093; bh=vWD1bZFC2UCTq/YyWnEY3oWpuQ/0W2n9KB7fb2hqbB8=; h=Subject:To:Cc:From:Date:From; b=rJUg7prcRa0xr+t+NflSTKm5FhHWU4cfSOgsTN5xbLlF8HrxbmrKJ+D6rq7daR9IT XwtL15I9hesV+V6hwzi1GDSPSi32FPO2oZkmhopxrogdCRrUGGlB1Sb3ApLSbxCISF roYRcPMc25mNOEoBlc8SutwfKE1OSDLubq6mxzXc= Subject: FAILED: patch "[PATCH] net: macb: Reinitialize tx/rx queue pointer registers and rx" failed to apply to 6.18-stable tree To: haokexin@gmail.com,horms@kernel.org,kuba@kernel.org,quanyang.wang@windriver.com Cc: From: Date: Fri, 20 Mar 2026 09:58:00 +0100 Message-ID: <2026032059-clad-unselfish-9202@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.18-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.18.y git checkout FETCH_HEAD git cherry-pick -x 718d0766ce4c7634ce62fa78b526ea7263487edd # git commit -s git send-email --to '' --in-reply-to '2026032059-clad-unselfish-9202@gregkh' --subject-prefix 'PATCH 6.18.y' HEAD^.. Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 718d0766ce4c7634ce62fa78b526ea7263487edd Mon Sep 17 00:00:00 2001 From: Kevin Hao Date: Thu, 12 Mar 2026 16:13:59 +0800 Subject: [PATCH] net: macb: Reinitialize tx/rx queue pointer registers and rx ring during resume On certain platforms, such as AMD Versal boards, the tx/rx queue pointer registers are cleared after suspend, and the rx queue pointer register is also disabled during suspend if WOL is enabled. Previously, we assumed that these registers would be restored by macb_mac_link_up(). However, in commit bf9cf80cab81, macb_init_buffers() was moved from macb_mac_link_up() to macb_open(). Therefore, we should call macb_init_buffers() to reinitialize the tx/rx queue pointer registers during resume. Due to the reset of these two registers, we also need to adjust the tx/rx rings accordingly. The tx ring will be handled by gem_shuffle_tx_rings() in macb_mac_link_up(), so we only need to initialize the rx ring here. Fixes: bf9cf80cab81 ("net: macb: Fix tx/rx malfunction after phy link down and up") Reported-by: Quanyang Wang Signed-off-by: Kevin Hao Tested-by: Quanyang Wang Cc: stable@vger.kernel.org Reviewed-by: Simon Horman Link: https://patch.msgid.link/20260312-macb-versal-v1-2-467647173fa4@gmail.com Signed-off-by: Jakub Kicinski diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c index 4bdc7ccab730..033cff571904 100644 --- a/drivers/net/ethernet/cadence/macb_main.c +++ b/drivers/net/ethernet/cadence/macb_main.c @@ -5952,8 +5952,18 @@ static int __maybe_unused macb_resume(struct device *dev) rtnl_unlock(); } + if (!(bp->caps & MACB_CAPS_MACB_IS_EMAC)) + macb_init_buffers(bp); + for (q = 0, queue = bp->queues; q < bp->num_queues; ++q, ++queue) { + if (!(bp->caps & MACB_CAPS_MACB_IS_EMAC)) { + if (macb_is_gem(bp)) + gem_init_rx_ring(queue); + else + macb_init_rx_ring(queue); + } + napi_enable(&queue->napi_rx); napi_enable(&queue->napi_tx); }