Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
* Re: [RFC PATCH v2 3/5] mm: thp: add struct ops for BPF based THP adjustment
       [not found] <20250520060504.20251-4-laoar.shao@gmail.com>
@ 2025-05-20 17:03 ` kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-05-20 17:03 UTC (permalink / raw)
  To: Yafang Shao; +Cc: llvm, oe-kbuild-all

Hi Yafang,

[This is a private test report for your RFC patch.]
kernel test robot noticed the following build errors:

[auto build test ERROR on akpm-mm/mm-everything]

url:    https://github.com/intel-lab-lkp/linux/commits/Yafang-Shao/mm-thp-Add-a-new-mode-bpf/20250520-140834
base:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything
patch link:    https://lore.kernel.org/r/20250520060504.20251-4-laoar.shao%40gmail.com
patch subject: [RFC PATCH v2 3/5] mm: thp: add struct ops for BPF based THP adjustment
config: s390-randconfig-002-20250520 (https://download.01.org/0day-ci/archive/20250521/202505210026.wIUy2SJG-lkp@intel.com/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project f819f46284f2a79790038e1f6649172789734ae8)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250521/202505210026.wIUy2SJG-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/202505210026.wIUy2SJG-lkp@intel.com/

All errors (new ones prefixed by >>):

   s390x-linux-ld: mm/memory.o: in function `thp_vma_allowable_orders':
>> include/linux/huge_mm.h:309:(.text+0x43bc0): undefined reference to `hugepage_bpf_allowable'
   s390x-linux-ld: mm/khugepaged.o: in function `thp_vma_allowable_orders':
   include/linux/huge_mm.h:309:(.text+0x1628): undefined reference to `hugepage_bpf_allowable'
   s390x-linux-ld: fs/proc/task_mmu.o: in function `thp_vma_allowable_orders':
   include/linux/huge_mm.h:309:(.text+0xb00e): undefined reference to `hugepage_bpf_allowable'


vim +309 include/linux/huge_mm.h

3485b88390b0af9 Ryan Roberts   2023-12-07  274  
3485b88390b0af9 Ryan Roberts   2023-12-07  275  unsigned long __thp_vma_allowable_orders(struct vm_area_struct *vma,
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  276  					 unsigned long vm_flags,
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  277  					 unsigned long tva_flags,
3485b88390b0af9 Ryan Roberts   2023-12-07  278  					 unsigned long orders);
3485b88390b0af9 Ryan Roberts   2023-12-07  279  
3485b88390b0af9 Ryan Roberts   2023-12-07  280  /**
3485b88390b0af9 Ryan Roberts   2023-12-07  281   * thp_vma_allowable_orders - determine hugepage orders that are allowed for vma
3485b88390b0af9 Ryan Roberts   2023-12-07  282   * @vma:  the vm area to check
3485b88390b0af9 Ryan Roberts   2023-12-07  283   * @vm_flags: use these vm_flags instead of vma->vm_flags
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  284   * @tva_flags: Which TVA flags to honour
3485b88390b0af9 Ryan Roberts   2023-12-07  285   * @orders: bitfield of all orders to consider
3485b88390b0af9 Ryan Roberts   2023-12-07  286   *
3485b88390b0af9 Ryan Roberts   2023-12-07  287   * Calculates the intersection of the requested hugepage orders and the allowed
3485b88390b0af9 Ryan Roberts   2023-12-07  288   * hugepage orders for the provided vma. Permitted orders are encoded as a set
3485b88390b0af9 Ryan Roberts   2023-12-07  289   * bit at the corresponding bit position (bit-2 corresponds to order-2, bit-3
3485b88390b0af9 Ryan Roberts   2023-12-07  290   * corresponds to order-3, etc). Order-0 is never considered a hugepage order.
3485b88390b0af9 Ryan Roberts   2023-12-07  291   *
3485b88390b0af9 Ryan Roberts   2023-12-07  292   * Return: bitfield of orders allowed for hugepage in the vma. 0 if no hugepage
3485b88390b0af9 Ryan Roberts   2023-12-07  293   * orders are allowed.
3485b88390b0af9 Ryan Roberts   2023-12-07  294   */
3485b88390b0af9 Ryan Roberts   2023-12-07  295  static inline
3485b88390b0af9 Ryan Roberts   2023-12-07  296  unsigned long thp_vma_allowable_orders(struct vm_area_struct *vma,
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  297  				       unsigned long vm_flags,
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  298  				       unsigned long tva_flags,
3485b88390b0af9 Ryan Roberts   2023-12-07  299  				       unsigned long orders)
3485b88390b0af9 Ryan Roberts   2023-12-07  300  {
3485b88390b0af9 Ryan Roberts   2023-12-07  301  	/* Optimization to check if required orders are enabled early. */
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  302  	if ((tva_flags & TVA_ENFORCE_SYSFS) && vma_is_anonymous(vma)) {
3485b88390b0af9 Ryan Roberts   2023-12-07  303  		unsigned long mask = READ_ONCE(huge_anon_orders_always);
3485b88390b0af9 Ryan Roberts   2023-12-07  304  
3485b88390b0af9 Ryan Roberts   2023-12-07  305  		if (vm_flags & VM_HUGEPAGE)
3485b88390b0af9 Ryan Roberts   2023-12-07  306  			mask |= READ_ONCE(huge_anon_orders_madvise);
3485b88390b0af9 Ryan Roberts   2023-12-07  307  		if (hugepage_global_always() ||
31f9439b0bbc383 Yafang Shao    2025-05-20  308  		    ((vm_flags & VM_HUGEPAGE) && hugepage_global_enabled()) ||
31f9439b0bbc383 Yafang Shao    2025-05-20 @309  		    hugepage_bpf_allowable())
3485b88390b0af9 Ryan Roberts   2023-12-07  310  			mask |= READ_ONCE(huge_anon_orders_inherit);
3485b88390b0af9 Ryan Roberts   2023-12-07  311  
3485b88390b0af9 Ryan Roberts   2023-12-07  312  		orders &= mask;
3485b88390b0af9 Ryan Roberts   2023-12-07  313  		if (!orders)
3485b88390b0af9 Ryan Roberts   2023-12-07  314  			return 0;
3485b88390b0af9 Ryan Roberts   2023-12-07  315  	}
3485b88390b0af9 Ryan Roberts   2023-12-07  316  
e0ffb29bc54d86b Matthew Wilcox 2024-04-25  317  	return __thp_vma_allowable_orders(vma, vm_flags, tva_flags, orders);
3485b88390b0af9 Ryan Roberts   2023-12-07  318  }
43675e6fbbeadca Yang Shi       2019-07-18  319  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-05-20 17:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20250520060504.20251-4-laoar.shao@gmail.com>
2025-05-20 17:03 ` [RFC PATCH v2 3/5] mm: thp: add struct ops for BPF based THP adjustment kernel test robot

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