From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 4778E23D7FF; Wed, 30 Sep 2026 18:38:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790793513; cv=none; b=ul5+9/fLTt3Dz7Ynn2kSEyW8zNVP0xJXs8BYRE3uLJgzXJcviwvofGghx7qxcOuRKV40l9EYMUiLOX3cONOsL1aeGru9TuTFUkgebioSfjZTIE4vIYKE57v2WNPvHQhX1EF7Ni2sx6X0+PBQTkhXeNUlz04SYWfaJaouSIVL1j8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790793513; c=relaxed/simple; bh=YMG95K8ivvLzH+D3LBf9KOk6D8KcNLyj4FPlJHiWIz0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=DDCPlPKokNluhT45XriPDPqU8JrxLsrnqRPaVCH4GSjt8F5cCHb6Rexvg79UylkOcLVMjd/cKAaepYzMMLUHhGE+4kocgu5N3UOaUlGMHByZ27KnIHhUlPRtGnZ4hIqZYB2U5vdTU77J9ndutWmAJmMwD1ardakkXDeZTwGJHxE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=EQM+MnQW; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="EQM+MnQW" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5D0471F000FF; Wed, 30 Sep 2026 18:38:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1790793511; bh=uhH0RmFdYgZO6EbgO4wIx3CQtCib1fiTcUW52rcIbL0=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=EQM+MnQWpqAvKWmw7t99EtK4rjPPibynb0f+n7Lv1lf++spUyMpXjuCLp1g1U82AS fguo5eyXDN5HtzWxQxqnaOJLgUzf5CIWp1ZNtLptyCentewCgbvl9cEjNIRdUJuQ8j pyfULPXbmUkwcBzubaGGo4+EVoWif+Hh6IC4PE6M= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, =?UTF-8?q?Gajdos=20Tam=C3=A1s?= , Paolo Abeni Subject: [PATCH 6.18 282/395] net: atl1e: fix soft lockup on out-of-range hw_next_to_clean read Date: Wed, 30 Sep 2026 17:29:04 +0200 Message-ID: <20260930152346.777860875@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260930152340.591469096@linuxfoundation.org> References: <20260930152340.591469096@linuxfoundation.org> User-Agent: quilt/0.69 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-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 6.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Gajdos Tamás commit 374bf9e4b90f979e052332c4faca2d745c491a12 upstream. Same issue as atl1c (see the first commit in this series, "net: atl1c: fix soft lockup on out-of-range tpd_cons read"): the hardware can report an out-of-range hw_next_to_clean (seen as 0xffff) while the PCIe link/MAC is resetting. An out-of-range value can never be reached and the loop below would spin forever. Treat it as "nothing new to clean" instead. Fixes: a6a5325239c202 ("atl1e: Atheros L1E Gigabit Ethernet driver") Cc: stable@vger.kernel.org Signed-off-by: Gajdos Tamás Link: https://patch.msgid.link/20260921091334.3571525-3-tamas@rimpianto.com Signed-off-by: Paolo Abeni Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/atheros/atl1e/atl1e_main.c | 3 +++ 1 file changed, 3 insertions(+) --- a/drivers/net/ethernet/atheros/atl1e/atl1e_main.c +++ b/drivers/net/ethernet/atheros/atl1e/atl1e_main.c @@ -1234,6 +1234,9 @@ static bool atl1e_clean_tx_irq(struct at u16 hw_next_to_clean = AT_READ_REGW(&adapter->hw, REG_TPD_CONS_IDX); u16 next_to_clean = atomic_read(&tx_ring->next_to_clean); + if (unlikely(hw_next_to_clean >= tx_ring->count)) + hw_next_to_clean = next_to_clean; + while (next_to_clean != hw_next_to_clean) { tx_buffer = &tx_ring->tx_buffer[next_to_clean]; if (tx_buffer->dma) {