Re: powerpc64-linux-ld: mm/page_alloc.o:undefined reference to `node_reclaim_distance'

From: Randy Dunlap
Date: Sun Aug 30 2020 - 17:19:55 EST


On 8/30/20 12:32 PM, kernel test robot wrote:
> Hi Matt,
>
> FYI, the error/warning still remains.
>
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: 1127b219ce9481c84edad9711626d856127d5e51
> commit: a55c7454a8c887b226a01d7eed088ccb5374d81e sched/topology: Improve load balancing on AMD EPYC systems
> date: 12 months ago
> config: powerpc64-randconfig-c003-20200831 (attached as .config)
> compiler: powerpc64-linux-gcc (GCC) 9.3.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
> git checkout a55c7454a8c887b226a01d7eed088ccb5374d81e
> # save the attached .config to linux build tree
> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc64
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
>
> All errors (new ones prefixed by >>):
>
> powerpc64-linux-ld: warning: orphan section `.gnu.hash' from `linker stubs' being placed in section `.gnu.hash'
> powerpc64-linux-ld: arch/powerpc/perf/perf_regs.o: in function `perf_reg_value':
> arch/powerpc/perf/perf_regs.c:80: undefined reference to `.is_sier_available'
>>> powerpc64-linux-ld: mm/page_alloc.o:(.toc+0x0): undefined reference to `node_reclaim_distance'
>
> ---

Build error for undefined "node_reclaim_distance" has been reported on both
arch/sh/ and arch/powerpc64/.

Matt's patch here
https://lore.kernel.org/lkml/20191223164220.GA14394@xxxxxxxxxxxxxxxxxxx/

fixes the build error in both cases (both $ARCH-es), although it needs to be
resent as a patch instead of "can someone test this?".

Matt?

Acked-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx> # build-tested

thanks.
--
~Randy