public inbox for linux-block@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH blktests] check: Suppress kmemleak scanning failures
@ 2026-03-23 20:05 Bart Van Assche
  2026-03-31  0:36 ` Shinichiro Kawasaki
  0 siblings, 1 reply; 2+ messages in thread
From: Bart Van Assche @ 2026-03-23 20:05 UTC (permalink / raw)
  To: Shin'ichiro Kawasaki; +Cc: Damien Le Moal, linux-block, Bart Van Assche

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")
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH blktests] check: Suppress kmemleak scanning failures
  2026-03-23 20:05 [PATCH blktests] check: Suppress kmemleak scanning failures Bart Van Assche
@ 2026-03-31  0:36 ` Shinichiro Kawasaki
  0 siblings, 0 replies; 2+ messages in thread
From: Shinichiro Kawasaki @ 2026-03-31  0:36 UTC (permalink / raw)
  To: Bart Van Assche; +Cc: Damien Le Moal, linux-block@vger.kernel.org

On Mar 23, 2026 / 13:05, Bart Van Assche wrote:
> 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>

Thanks, I applied this patch.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-03-31  0:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-23 20:05 [PATCH blktests] check: Suppress kmemleak scanning failures Bart Van Assche
2026-03-31  0:36 ` Shinichiro Kawasaki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox