Re: [PATCH 2/2] mm: Remember young bit for page migrations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Aug 03, 2022 at 08:21:43PM +0800, kernel test robot wrote:
> Hi Peter,
> 
> Thank you for the patch! Yet something to improve:
> 
> [auto build test ERROR on akpm-mm/mm-everything]
> 
> url:    https://github.com/intel-lab-lkp/linux/commits/Peter-Xu/mm-Remember-young-bit-for-migration-entries/20220803-092311
> base:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything
> config: openrisc-randconfig-r016-20220803 (https://download.01.org/0day-ci/archive/20220803/202208032031.PVcMB0Hr-lkp@xxxxxxxxx/config)
> compiler: or1k-linux-gcc (GCC) 12.1.0
> reproduce (this is a W=1 build):
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         # https://github.com/intel-lab-lkp/linux/commit/2fca6cb25745d1404fc34e0ec2ea89b6195a8c27
>         git remote add linux-review https://github.com/intel-lab-lkp/linux
>         git fetch --no-tags linux-review Peter-Xu/mm-Remember-young-bit-for-migration-entries/20220803-092311
>         git checkout 2fca6cb25745d1404fc34e0ec2ea89b6195a8c27
>         # save the config file
>         mkdir build_dir && cp config build_dir/.config
>         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=openrisc SHELL=/bin/bash
> 
> If you fix the issue, kindly add following tag where applicable
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> 
> All errors (new ones prefixed by >>):
> 
>    or1k-linux-ld: mm/rmap.o: in function `migration_entry_supports_young':
> >> include/linux/swapops.h:288: undefined reference to `max_swapfile_size'
>    include/linux/swapops.h:288:(.text+0x31a0): relocation truncated to fit: R_OR1K_INSN_REL_26 against undefined symbol `max_swapfile_size'
>    or1k-linux-ld: mm/migrate.o: in function `migration_entry_supports_young':
> >> include/linux/swapops.h:288: undefined reference to `max_swapfile_size'
>    include/linux/swapops.h:288:(.text+0x158): relocation truncated to fit: R_OR1K_INSN_REL_26 against undefined symbol `max_swapfile_size'

Hmm, a bit surprised to know swapops.h will be used without CONFIG_SWAP..
I'll squash this in the next version (if not going via a page flag based
approach):

diff --git a/include/linux/swapops.h b/include/linux/swapops.h
index 9ddede3790a4..d689f59479c3 100644
--- a/include/linux/swapops.h
+++ b/include/linux/swapops.h
@@ -285,7 +285,11 @@ static inline bool migration_entry_supports_young(void)
         * entry has the offset larger than storing the PFN value, then it
         * means there's extra bit(s) where we can store the young bit.
         */
+#ifdef CONFIG_SWAP
        return max_swapfile_size() > SWP_MIG_YOUNG_BIT;
+#else
+       return false;
+#endif
 }
 
 static inline swp_entry_t make_migration_entry_young(swp_entry_t entry)

-- 
Peter Xu





[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux