lkml.org 
[lkml]   [2022]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
Subject[PATCH v2 1/2] selftests/damon: suppress compiler warnings for huge_count_read_write
From
The test case added in commit db7a347b26fe ("mm/damon/dbgfs:
use '__GFP_NOWARN' for user-specified size buffer allocation")
intentionally writes and reads with a large count to cause
allocation failure and check for kernel warnings. We suppress
the compiler warnings for these calls as they work as intended.

Signed-off-by: Yuanchu Xie <yuanchu@google.com>
---
tools/testing/selftests/damon/Makefile | 3 +++
1 file changed, 3 insertions(+)

diff --git a/tools/testing/selftests/damon/Makefile b/tools/testing/selftests/damon/Makefile
index 0470c5f3e690..a300b4c5b373 100644
--- a/tools/testing/selftests/damon/Makefile
+++ b/tools/testing/selftests/damon/Makefile
@@ -1,6 +1,9 @@
# SPDX-License-Identifier: GPL-2.0
# Makefile for damon selftests

+CFLAGS += -Wno-stringop-overread
+CFLAGS += -Wno-stringop-overflow
+
TEST_GEN_FILES += huge_count_read_write

TEST_FILES = _chk_dependency.sh _debugfs_common.sh
--
2.36.0.464.gb9c8b46e94-goog
\
 
 \ /
  Last update: 2022-05-04 02:05    [W:1.360 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site