Skip to contentSkip to conversation

arch/s390/mm/mmap.c:188:3: error: call to undeclared function 'mm_flag_set'; ISO C99 and later do not support implicit function declarations

PATCH kernel test robot 2 participants 2 messages Aug 13, 2025 Memory management

lore
Share & tools
lore

kernel test robot

author build bot
#0 lore raw

Hi Lorenzo,

FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-new
head:   694c8e78f486b09137ee3efadae044d01aba971b
commit: 70fd92efa9e96967353bb39665bac8f5276aaaae [123/137] mm: convert arch-specific code to mm_flags_*() accessors
config: s390-allnoconfig (https://download.01.org/0day-ci/archive/20250813/[email protected]/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 3769ce013be2879bf0b329c14a16f5cb766f26ce)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250813/[email protected]/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 <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

All errors (new ones prefixed by >>):

>> arch/s390/mm/mmap.c:188:3: error: call to undeclared function 'mm_flag_set'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
     188 |                 mm_flag_set(MMF_TOPDOWN, mm);
         |                 ^

arch/s390/mm/mmap.c:188:3: note: did you mean 'mm_flags_set'? include/linux/mm.h:740:20: note: 'mm_flags_set' declared here
740 | static inline void mm_flags_set(int flag, struct mm_struct *mm)
| ^
1 error generated.

vim +/mm_flag_set +188 arch/s390/mm/mmap.c

167
168 /*
169 * This function, called very early during the creation of a new
170 * process VM image, sets up which VM layout function to use:
171 */
172 void arch_pick_mmap_layout(struct mm_struct *mm, struct rlimit *rlim_stack)
173 {
174 unsigned long random_factor = 0UL;
175
176 if (current->flags & PF_RANDOMIZE)
177 random_factor = arch_mmap_rnd();
178
179 /*
180 * Fall back to the standard layout if the personality
181 * bit is set, or if the expected stack growth is unlimited:
182 */
183 if (mmap_is_legacy(rlim_stack)) {
184 mm->mmap_base = mmap_base_legacy(random_factor);
185 mm_flags_clear(MMF_TOPDOWN, mm);
186 } else {
187 mm->mmap_base = mmap_base(random_factor, rlim_stack);

 > 188			mm_flag_set(MMF_TOPDOWN, mm);

189 }
190 }
191

Signature · 2 lines
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
#1 lore raw
Quoted 16 lines · kernel test robot

Hi Lorenzo,

FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-new
head:   694c8e78f486b09137ee3efadae044d01aba971b
commit: 70fd92efa9e96967353bb39665bac8f5276aaaae [123/137] mm: convert arch-specific code to mm_flags_*() accessors
config: s390-allnoconfig (https://download.01.org/0day-ci/archive/20250813/[email protected]/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 3769ce013be2879bf0b329c14a16f5cb766f26ce)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250813/[email protected]/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 <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

Quoted 4 lines

All errors (new ones prefixed by >>):

Quoted 1 line
Quoted 1 line

arch/s390/mm/mmap.c:188:3: error: call to undeclared function 'mm_flag_set'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]

     188 |                 mm_flag_set(MMF_TOPDOWN, mm);

Oops I typo'd this! Apologies. should be mm_flags_set().

Will send a fixpatch.