From nobody Tue Jul 26 19:33:21 2022 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 4LsnBp3PGqz4WxHN; Tue, 26 Jul 2022 19:33:22 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LsnBp2FQnz47KS; Tue, 26 Jul 2022 19:33:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658864002; 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=ADm1JSPitC2J0xFkVJuckuLrUKdubuKtPHZPG9z0LKg=; b=xjyWF1Vzwfx4J5mt1rL2laBAh66agsOS/cQEgVtNoXRzHM28LYfFHg5uU+1GFE2dq07pH5 a/hEJF3rgpkZlfuvvFF6IuJEBKjdTJ1bIeY+7VkTDCdfeWuYd6//K/YLVRXL4H6qj2XiIQ XZwNS6J2tYQmchCbWabkD9EyoLvxSuhVlG6KnHNY+trfG0OhgFlVPcBnd55FxKCTBAR7bg 1zzCKFWyomlT9wYva5w251eVoG+y/7dcJNB3N52stnhvMRMMbXTEd7N+EDPTP2+yNRl3y0 /EMgTRDy3N1NA7V48d8kxo1rMXdJCvVdGZvRSqCwiBk5GSHsQeJ0m+VPvY4JeA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4LsnBn5nLZzpR1; Tue, 26 Jul 2022 19:33:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 26QJXL76033748; Tue, 26 Jul 2022 19:33:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26QJXL9P033747; Tue, 26 Jul 2022 19:33:21 GMT (envelope-from git) Date: Tue, 26 Jul 2022 19:33:21 GMT Message-Id: <202207261933.26QJXL9P033747@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Marcin Wojtas Subject: git: a244d6ec4ea8 - stable/12 - ena: Extend debug prints for invalid req_id resets 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mw X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: a244d6ec4ea86b777f8cd813964aa256e6ef9826 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658864002; 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=ADm1JSPitC2J0xFkVJuckuLrUKdubuKtPHZPG9z0LKg=; b=F6457gdt+OyJCKpRKilmJYznN/c8wk7x70MIV8M/CNoAu1B5L2IYXyHDBAH9yidoPolwzt Wu35DqPsbro7V4alxGJ6xDYG4kiaJvMMG4PJGt7h6PwrdGA176t+lIqUT1xSX1+68umcY8 ueUm6DWutSOkI0ycvOwcOJLCQvhVClQK1OBmkz6vTYsdrYIvGSX7MLLGQwGMpbvPJGCjxZ 7tG/DQWwxMRAmezGoKQiNNAE0fV8g1XK5/FnLrAKSNNfusWSTG3RCZKKTJG0d/ZKNM9bbB JgtsaVrUjCo1X7DAs4/0TGlECmV42P7PyMQGGKocTFxFmr+MFYJyLVwYnq3urQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1658864002; a=rsa-sha256; cv=none; b=JzEr5Hv3Glcn+eAgx4f4/Mm2w4BNp4Irqdm88mKNhAnKA1SEPh+kJ6XenxCOCc4/dh1zH1 L1vo54iutKIVViYPQBEoq54kyUDTet7BN1fklc0B3w56SeE3TaZfgDWrwePW3TIiJocV2I zrnstT/IDWMaYRslD+dxKrxxDP+ud/QcZTgbI08004Tq5jyqWoFZxgt4XNFDxfAcHirzlJ vPgT9E1PcT8SjXztM9aSz6zGYR8I7B/hDRkR8IEgzzBVoBBWOJrma8l+sEHt7fOqJ3ODs+ flg3hFMYcAHRwGhsYS9Fi9YehFK9EqwIHL+d0LNlPs+LxXOaOThCXLqcEydxTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by mw: URL: https://cgit.FreeBSD.org/src/commit/?id=a244d6ec4ea86b777f8cd813964aa256e6ef9826 commit a244d6ec4ea86b777f8cd813964aa256e6ef9826 Author: Dawid Gorecki AuthorDate: 2022-06-10 09:18:07 +0000 Commit: Marcin Wojtas CommitDate: 2022-07-26 19:33:02 +0000 ena: Extend debug prints for invalid req_id resets Print information about qid if req_id is invalid. Add information about qid and req_id if mbuf is invalid. Obtained from: Semihalf MFC after: 2 weeks Sponsored by: Amazon, Inc. (cherry picked from commit a9c39b031fe89a6414174e3db82da6548d7fff0f) --- sys/dev/ena/ena_datapath.c | 7 +++++-- sys/dev/ena/ena_netmap.c | 3 ++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/sys/dev/ena/ena_datapath.c b/sys/dev/ena/ena_datapath.c index fac8cdf488f3..e3d30b32fceb 100644 --- a/sys/dev/ena/ena_datapath.c +++ b/sys/dev/ena/ena_datapath.c @@ -213,7 +213,8 @@ ena_get_tx_req_id(struct ena_ring *tx_ring, struct ena_com_io_cq *io_cq, return (EAGAIN); if (unlikely(rc != 0)) { - ena_log(adapter->pdev, ERR, "Invalid req_id: %hu\n", *req_id); + ena_log(adapter->pdev, ERR, "Invalid req_id %hu in qid %hu\n", + *req_id, tx_ring->qid); counter_u64_add(tx_ring->tx_stats.bad_req_id, 1); goto err; } @@ -221,7 +222,9 @@ ena_get_tx_req_id(struct ena_ring *tx_ring, struct ena_com_io_cq *io_cq, if (tx_ring->tx_buffer_info[*req_id].mbuf != NULL) return (0); - ena_log(adapter->pdev, ERR, "tx_info doesn't have valid mbuf\n"); + ena_log(adapter->pdev, ERR, + "tx_info doesn't have valid mbuf. qid %hu req_id %hu\n", + tx_ring->qid, *req_id); err: ena_trigger_reset(adapter, ENA_REGS_RESET_INV_TX_REQ_ID); diff --git a/sys/dev/ena/ena_netmap.c b/sys/dev/ena/ena_netmap.c index e9511b033fd3..476926da373d 100644 --- a/sys/dev/ena/ena_netmap.c +++ b/sys/dev/ena/ena_netmap.c @@ -884,7 +884,8 @@ validate_tx_req_id(struct ena_ring *tx_ring, uint16_t req_id) if (likely(req_id < tx_ring->ring_size)) return (0); - ena_log_nm(adapter->pdev, WARN, "Invalid req_id: %hu\n", req_id); + ena_log_nm(adapter->pdev, WARN, "Invalid req_id %hu in qid %hu\n", + req_id, tx_ring->qid); counter_u64_add(tx_ring->tx_stats.bad_req_id, 1); ena_trigger_reset(adapter, ENA_REGS_RESET_INV_TX_REQ_ID);