[linux-next:master 3561/4143] mm/sparse.c:730:24: error: implicit declaration of function 'bootmem_type'

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

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   d61a00525464bfc5fe92c6ad713350988e492b88
commit: 8010bda4cd9c0dded1cb1e52ac1d14f4e6a55ec9 [3561/4143] bootmem: stop using page->index
config: loongarch-randconfig-r061-20241012 (https://download.01.org/0day-ci/archive/20241012/202410120526.Ud7TRejf-lkp@xxxxxxxxx/config)
compiler: loongarch64-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241012/202410120526.Ud7TRejf-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202410120526.Ud7TRejf-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

   mm/sparse.c: In function 'free_map_bootmem':
>> mm/sparse.c:730:24: error: implicit declaration of function 'bootmem_type' [-Wimplicit-function-declaration]
     730 |                 type = bootmem_type(page);
         |                        ^~~~~~~~~~~~
>> mm/sparse.c:735:39: error: implicit declaration of function 'bootmem_info' [-Wimplicit-function-declaration]
     735 |                 removing_section_nr = bootmem_info(page);
         |                                       ^~~~~~~~~~~~


vim +/bootmem_type +730 mm/sparse.c

   719	
   720	static void free_map_bootmem(struct page *memmap)
   721	{
   722		unsigned long maps_section_nr, removing_section_nr, i;
   723		unsigned long type, nr_pages;
   724		struct page *page = virt_to_page(memmap);
   725	
   726		nr_pages = PAGE_ALIGN(PAGES_PER_SECTION * sizeof(struct page))
   727			>> PAGE_SHIFT;
   728	
   729		for (i = 0; i < nr_pages; i++, page++) {
 > 730			type = bootmem_type(page);
   731	
   732			BUG_ON(type == NODE_INFO);
   733	
   734			maps_section_nr = pfn_to_section_nr(page_to_pfn(page));
 > 735			removing_section_nr = bootmem_info(page);
   736	
   737			/*
   738			 * When this function is called, the removing section is
   739			 * logical offlined state. This means all pages are isolated
   740			 * from page allocator. If removing section's memmap is placed
   741			 * on the same section, it must not be freed.
   742			 * If it is freed, page allocator may allocate it which will
   743			 * be removed physically soon.
   744			 */
   745			if (maps_section_nr != removing_section_nr)
   746				put_page_bootmem(page);
   747		}
   748	}
   749	

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




[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