Linux-NVME Archive mirror
 help / color / mirror / Atom feed
From: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
To: linux-block@vger.kernel.org
Cc: linux-nvme@lists.infradead.org,
	Alan Adamson <alan.adamson@oracle.com>,
	Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Subject: [PATCH blktests] nvme/039: adjust to util-linux v2.40 dmesg format change
Date: Mon, 29 Apr 2024 10:38:51 +0900	[thread overview]
Message-ID: <20240429013851.181700-1-shinichiro.kawasaki@wdc.com> (raw)

Since util-linux version 2.40, dmesg supports "caller ID". When Linux
kernel supports CONFIG_PRINTK_CALLER, dmesg adds thread ID or CPU ID
with parenthesis such as [    T123] or [     C16] to each message. This
made the dmesg string check of the test case nvme/039 fail. Fix this by
filtering out the added caller ID field.

Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
---
 tests/nvme/039 | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/nvme/039 b/tests/nvme/039
index f92f852..a0f135c 100755
--- a/tests/nvme/039
+++ b/tests/nvme/039
@@ -24,7 +24,8 @@ last_dmesg()
 {
 	local nr_lines=$1
 
-	dmesg -t | grep -v "callbacks suppressed" | tail "-$nr_lines"
+	dmesg -t | grep -v "callbacks suppressed" | tail "-$nr_lines" \
+		| sed 's/\[.*\] //'
 }
 
 inject_unrec_read_on_read()
-- 
2.44.0



             reply	other threads:[~2024-04-29  1:39 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-29  1:38 Shin'ichiro Kawasaki [this message]
2024-05-09 10:41 ` [PATCH blktests] nvme/039: adjust to util-linux v2.40 dmesg format change Shinichiro Kawasaki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240429013851.181700-1-shinichiro.kawasaki@wdc.com \
    --to=shinichiro.kawasaki@wdc.com \
    --cc=alan.adamson@oracle.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).