From: Bart Van Assche <bvanassche@acm.org>
To: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Cc: Damien Le Moal <dlemoal@kernel.org>,
linux-block@vger.kernel.org, Bart Van Assche <bvanassche@acm.org>
Subject: [PATCH blktests] check: Suppress kmemleak scanning failures
Date: Mon, 23 Mar 2026 13:05:12 -0700 [thread overview]
Message-ID: <20260323200512.1237426-1-bvanassche@acm.org> (raw)
kmemleak disables itself if an internal error has been encountered. If
this happens, any attempt to write into /sys/kernel/debug/kmemleak
triggers the error "Operation not permitted". Suppress this error
message instead of displaying it on stdout.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
check | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/check b/check
index f170458fdb69..d2232828a9e3 100755
--- a/check
+++ b/check
@@ -233,7 +233,7 @@ _check_kmemleak() {
((KMEMLEAK)) || return 0
- echo scan > "$KMEMLEAK_FILE"
+ { echo scan > "$KMEMLEAK_FILE"; } 2>/dev/null || return 0
sleep 1
kmemleak=$(cat "$KMEMLEAK_FILE")
next reply other threads:[~2026-03-23 20:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-23 20:05 Bart Van Assche [this message]
2026-03-31 0:36 ` [PATCH blktests] check: Suppress kmemleak scanning failures 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=20260323200512.1237426-1-bvanassche@acm.org \
--to=bvanassche@acm.org \
--cc=dlemoal@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=shinichiro.kawasaki@wdc.com \
/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