Re: [kbuild-all] Re: undefined reference to `node_data'

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

 





On 03/25/2022 09:16 AM, Chen, Rong A wrote:


On 3/24/2022 8:40 PM, Michal Hocko wrote:
On Thu 24-03-22 10:04:43, Thomas Bogendoerfer wrote:
On Wed, Mar 23, 2022 at 05:46:59PM +0100, Michal Hocko wrote:
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

    mips64-linux-ld: mm/page_alloc.o: in function `free_area_init':
(.init.text+0x1680): undefined reference to `node_data'
    mips64-linux-ld: (.init.text+0x1690): undefined reference to
`node_data'

OK, I can see what is going here. The page allocator normally
uses NODE_DATA but arch_refresh_nodedata refers to node_data directly.
This is a problem with
arch/mips/include/asm/mach-loongson64/mmzone.h:
extern struct pglist_data *__node_data[];

#define NODE_DATA(n)            (__node_data[n])

Unfortunately we cannot use NODE_DATA there because of header
inclusion
ordering. I will think about a solution.

Is there any reason why (some?) MIPS arches use __node_data rather than
node_data as most other architectures? Would it be acceptable to do the
renaming? It would help to cover the above compilation problem because
arch_refresh_nodedata could keep using node_data directly.

I've just checked history and I don't see a reason for __node_data.
So I'm fine with changing it to node_data.

Thanks a lot for double checking Thomas! This is a dump&simple sed over
mips file. 0-day guys, could you give it a try please?


Hi Michal,

It returns another error:

Hi,

I think the following patch should fix the build error
"undefined reference to `node_data'":

https://git.kernel.org/pub/scm/linux/kernel/git/mips/linux.git/commit/?id=f8f9f21c7848

Thanks,
Tiezhu





[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