From: kernel test robot <lkp@intel.com>
To: David Heidelberg via B4 Relay <devnull+david.ixit.cz@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Uladzislau Rezki <urezki@gmail.com>,
"Vishal Moola (Oracle)" <vishal.moola@gmail.com>
Cc: oe-kbuild-all@lists.linux.dev,
Linux Memory Management List <linux-mm@kvack.org>,
linux-kernel@vger.kernel.org, phone-devel@vger.kernel.org,
David Heidelberg <david@ixit.cz>
Subject: Re: [PATCH] mm/vmalloc: warn only once when vmalloc detect invalid gfp flags
Date: Tue, 18 Nov 2025 08:53:58 +0800 [thread overview]
Message-ID: <202511180838.vEBLp7Hm-lkp@intel.com> (raw)
In-Reply-To: <20251118-only-one-vmalloc-v1-1-29f8eacb4605@ixit.cz>
Hi David,
kernel test robot noticed the following build errors:
[auto build test ERROR on 0c1c7a6a83feaf2cf182c52983ffe330ffb50280]
url: https://github.com/intel-lab-lkp/linux/commits/David-Heidelberg-via-B4-Relay/mm-vmalloc-warn-only-once-when-vmalloc-detect-invalid-gfp-flags/20251118-080722
base: 0c1c7a6a83feaf2cf182c52983ffe330ffb50280
patch link: https://lore.kernel.org/r/20251118-only-one-vmalloc-v1-1-29f8eacb4605%40ixit.cz
patch subject: [PATCH] mm/vmalloc: warn only once when vmalloc detect invalid gfp flags
config: alpha-allnoconfig (https://download.01.org/0day-ci/archive/20251118/202511180838.vEBLp7Hm-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 15.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251118/202511180838.vEBLp7Hm-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202511180838.vEBLp7Hm-lkp@intel.com/
All error/warnings (new ones prefixed by >>):
In file included from arch/alpha/include/asm/bug.h:23,
from include/linux/bug.h:5,
from include/linux/alloc_tag.h:8,
from include/linux/vmalloc.h:5,
from mm/vmalloc.c:11:
mm/vmalloc.c: In function 'vmalloc_fix_flags':
>> mm/vmalloc.c:3938:19: error: expected ')' before 'invalid_mask'
3938 | invalid_mask, &invalid_mask, flags, &flags);
| ^~~~~~~~~~~~
include/asm-generic/bug.h:105:62: note: in definition of macro '__WARN_printf'
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
include/asm-generic/bug.h:105:34: note: to match this '('
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^
include/asm-generic/bug.h:141:17: note: in expansion of macro '__WARN_printf'
141 | __WARN_printf(TAINT_WARN, format); \
| ^~~~~~~~~~~~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
>> mm/vmalloc.c:3937:22: warning: format '%x' expects a matching 'unsigned int' argument [-Wformat=]
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/bug.h:105:62: note: in definition of macro '__WARN_printf'
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
mm/vmalloc.c:3937:41: note: format string is defined here
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ~~^
| |
| unsigned int
>> mm/vmalloc.c:3937:22: warning: format '%p' expects a matching 'void *' argument [-Wformat=]
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/bug.h:105:62: note: in definition of macro '__WARN_printf'
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
mm/vmalloc.c:3937:45: note: format string is defined here
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ~^
| |
| void *
>> mm/vmalloc.c:3937:22: warning: format '%x' expects a matching 'unsigned int' argument [-Wformat=]
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/bug.h:105:62: note: in definition of macro '__WARN_printf'
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
mm/vmalloc.c:3937:71: note: format string is defined here
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ~~^
| |
| unsigned int
>> mm/vmalloc.c:3937:22: warning: format '%p' expects a matching 'void *' argument [-Wformat=]
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/bug.h:105:62: note: in definition of macro '__WARN_printf'
105 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \
| ^~~
include/linux/once_lite.h:31:25: note: in expansion of macro 'WARN'
31 | func(__VA_ARGS__); \
| ^~~~
include/asm-generic/bug.h:159:9: note: in expansion of macro 'DO_ONCE_LITE_IF'
159 | DO_ONCE_LITE_IF(condition, WARN, 1, format)
| ^~~~~~~~~~~~~~~
mm/vmalloc.c:3937:9: note: in expansion of macro 'WARN_ONCE'
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ^~~~~~~~~
mm/vmalloc.c:3937:75: note: format string is defined here
3937 | WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
| ~^
| |
| void *
>> mm/vmalloc.c:3934:15: warning: unused variable 'invalid_mask' [-Wunused-variable]
3934 | gfp_t invalid_mask = flags & ~GFP_VMALLOC_SUPPORTED;
| ^~~~~~~~~~~~
vim +3938 mm/vmalloc.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 3921
7179b225631532 Vishal Moola (Oracle 2025-11-12 3922) /*
7179b225631532 Vishal Moola (Oracle 2025-11-12 3923) * See __vmalloc_node_range() for a clear list of supported vmalloc flags.
7179b225631532 Vishal Moola (Oracle 2025-11-12 3924) * This gfp lists all flags currently passed through vmalloc. Currently,
7179b225631532 Vishal Moola (Oracle 2025-11-12 3925) * __GFP_ZERO is used by BPF and __GFP_NORETRY is used by percpu. Both drm
7179b225631532 Vishal Moola (Oracle 2025-11-12 3926) * and BPF also use GFP_USER, which is GFP_KERNEL | __GFP_HARDWALL.
7179b225631532 Vishal Moola (Oracle 2025-11-12 3927) */
7179b225631532 Vishal Moola (Oracle 2025-11-12 3928) #define GFP_VMALLOC_SUPPORTED (GFP_KERNEL | GFP_ATOMIC | GFP_NOWAIT |\
7179b225631532 Vishal Moola (Oracle 2025-11-12 3929) __GFP_NOFAIL | __GFP_ZERO | __GFP_NORETRY |\
7179b225631532 Vishal Moola (Oracle 2025-11-12 3930) __GFP_HARDWALL)
7179b225631532 Vishal Moola (Oracle 2025-11-12 3931)
7179b225631532 Vishal Moola (Oracle 2025-11-12 3932) static gfp_t vmalloc_fix_flags(gfp_t flags)
7179b225631532 Vishal Moola (Oracle 2025-11-12 3933) {
7179b225631532 Vishal Moola (Oracle 2025-11-12 @3934) gfp_t invalid_mask = flags & ~GFP_VMALLOC_SUPPORTED;
7179b225631532 Vishal Moola (Oracle 2025-11-12 3935)
7179b225631532 Vishal Moola (Oracle 2025-11-12 3936) flags &= GFP_VMALLOC_SUPPORTED;
bf791000a32caf David Heidelberg 2025-11-18 @3937 WARN_ONCE(1, "Unexpected gfp: %#x (%pGg). Fixing up to gfp: %#x (%pGg). Fix your code!\n"
7179b225631532 Vishal Moola (Oracle 2025-11-12 @3938) invalid_mask, &invalid_mask, flags, &flags);
7179b225631532 Vishal Moola (Oracle 2025-11-12 3939) return flags;
7179b225631532 Vishal Moola (Oracle 2025-11-12 3940) }
7179b225631532 Vishal Moola (Oracle 2025-11-12 3941)
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2025-11-18 0:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-18 0:05 David Heidelberg via B4 Relay
2025-11-18 0:34 ` Vishal Moola (Oracle)
[not found] ` <b7e215ee-fce6-4a7c-995d-8ea6625b1ae8@ixit.cz>
2025-11-18 1:06 ` Vishal Moola (Oracle)
2025-11-18 0:53 ` kernel test robot [this message]
2025-11-18 1:16 ` Vishal Moola (Oracle)
2025-11-18 9:31 ` Uladzislau Rezki
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=202511180838.vEBLp7Hm-lkp@intel.com \
--to=lkp@intel.com \
--cc=akpm@linux-foundation.org \
--cc=david@ixit.cz \
--cc=devnull+david.ixit.cz@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=phone-devel@vger.kernel.org \
--cc=urezki@gmail.com \
--cc=vishal.moola@gmail.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