From nobody Wed Aug 26 00:57:02 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4hV5p65dL2z6qKsh for ; Wed, 26 Aug 2026 00:57:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hV5p63T7Kz3vLB for ; Wed, 26 Aug 2026 00:57:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1787705822; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Dx4feXnBGES5QNf+08DLBTDvRjHufmTl5WZG66fqcIQ=; b=wluEipxWROTRSetJ1RNGkN+Ku7PCHI8FhI4PCXeu0YvZ98e8x7FJbkmxGZucHHVdAABoiX VkDyKR5K4U1bUmKKK1yWvTI4tc8kr3yWONftkc8TiA1qJ2sY+tCYFv20b1NFKtoiNPFsv/ D7W4LpGgOXZWaPsFWODvSpBF6WWXh4Pa0ZoKpIqr2izl21bcFyShhb6pcswK+4d2wrJYHS gdC+ZoYI3NBeaHPsmX8mDDbAN5i7D5AfLxEhOaLovM0FjVZO1J/K+dEaeANQ8KDPVZ0dpp Ehi6wb/aSTe08eYH50EJ1oJoC+LAxP+mj7iTEEuH9uAKqpb91WW6cyTPjuPHDQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1787705822; a=rsa-sha256; cv=none; b=VozAYCzXYIDyAGBYr7vHBx5zNIgoYxcTsvqaVJVDjRHRDzYSYDfOoHnG81SAznnBbjZpsF k/dYX/e0pQAQuqqjK0gyOVEvMPR3TedMcigKrwpZZa7vkN6rqBfV4vXJyYMgRW7zc3Pl7I qRBdVToPwiqIJwfDGtMoC6XSM416pe/hSKSvX2fhWTcOJ4ulaZcQo8KStU3D3fb8EOryFW aSnGdJom3WP5mIY4hEP/GrbwLTWpZH0lRj1sGfVYCc7gSv/5hGP3YzQ/p3/S0+fcGYdCDf D7G2lDhbQLYKtxHDpMrcEyDGMU+ohDqk4dUCGoJzs8+ozQmZMCDRm2HgwhXx/g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1787705822; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Dx4feXnBGES5QNf+08DLBTDvRjHufmTl5WZG66fqcIQ=; b=sxzYrwej1AyHLErEO5EqAxc+N7zpSESvVugaUEs2forU+Hp01+HZ5RTFwfvkVeRDf9XRRw q68iceI9AO4lYQO/oh/WtAn5XwgQ4eHDJLYD5strXGrXk7JzVRjubwlKhiB0/zdwE4vdf2 lO7U888LleLzhkrEdS+kLlH0xroznxGBaSH2cGr0OoEmVHwL+NOhQoNHLms1VqFg2ELOS1 k7WY6JZKJPxN6kxUTnLaqru1LnuaB13S141/nEOhPiMiefVcNGTOzKlvlcYod2mYrZ9IA3 sulUTiqxduydvQmBVJ4cBnQUfaLZRQwe9oDszHJCvqD+Of35LoklDyr9NKySWg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hV5p610pTz19J for ; Wed, 26 Aug 2026 00:57:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 427e9 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 26 Aug 2026 00:57:02 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kevin Bowling Subject: git: 5122a6181aa4 - stable/15 - e1000: Fix the multiqueue debug register dump List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 5122a6181aa4268761cda41980af62c0245f1816 Auto-Submitted: auto-generated Date: Wed, 26 Aug 2026 00:57:02 +0000 Message-Id: <6a8e39de.427e9.76243e1@gitrepo.freebsd.org> The branch stable/15 has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=5122a6181aa4268761cda41980af62c0245f1816 commit 5122a6181aa4268761cda41980af62c0245f1816 Author: Kevin Bowling AuthorDate: 2026-08-12 00:33:18 +0000 Commit: Kevin Bowling CommitDate: 2026-08-26 00:56:51 +0000 e1000: Fix the multiqueue debug register dump The debug routine advanced ring pointers as if rings were contiguous. They are embedded in queue structures, so rings beyond queue zero had the wrong stride. The bogus queue index could cause an invalid MMIO read and panic the machine. Index the queue arrays first and then select the embedded ring. (cherry picked from commit 7dd826171b69a01c234ba6e9117917398ba2705e) --- sys/dev/e1000/if_em.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c index 6032c7945947..bf3369a20bad 100644 --- a/sys/dev/e1000/if_em.c +++ b/sys/dev/e1000/if_em.c @@ -6043,9 +6043,11 @@ em_print_debug_info(struct e1000_softc *sc) { device_t dev = iflib_get_dev(sc->ctx); if_t ifp = iflib_get_ifp(sc->ctx); - struct tx_ring *txr = &sc->tx_queues->txr; - struct rx_ring *rxr = &sc->rx_queues->rxr; + if (sc->tx_queues == NULL || sc->rx_queues == NULL) { + device_printf(dev, "queue state is unavailable\n"); + return; + } if (if_getdrvflags(ifp) & IFF_DRV_RUNNING) printf("Interface is RUNNING "); else @@ -6056,14 +6058,14 @@ em_print_debug_info(struct e1000_softc *sc) else printf("and ACTIVE\n"); - for (int i = 0; i < sc->tx_num_queues; i++, txr++) { + for (int i = 0; i < sc->tx_num_queues; i++) { device_printf(dev, "TX Queue %d ------\n", i); device_printf(dev, "hw tdh = %d, hw tdt = %d\n", E1000_READ_REG(&sc->hw, E1000_TDH(i)), E1000_READ_REG(&sc->hw, E1000_TDT(i))); } - for (int j=0; j < sc->rx_num_queues; j++, rxr++) { + for (int j = 0; j < sc->rx_num_queues; j++) { device_printf(dev, "RX Queue %d ------\n", j); device_printf(dev, "hw rdh = %d, hw rdt = %d\n", E1000_READ_REG(&sc->hw, E1000_RDH(j)),