All of lore.kernel.org
 help / color / mirror / Atom feed
* [akpm-mm:mm-new 358/388] mm/sparse-vmemmap.c:507:48: error: passing argument 2 of 'vmemmap_shared_tail_page' makes pointer from integer without a cast
@ 2026-09-10 15:42 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-09-10 15:42 UTC (permalink / raw)
  To: Andrew Morton
  Cc: oe-kbuild-all, David Hildenbrand, Linux Memory Management List,
	mm-commits, Muchun Song

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-new
head:   cf558a250cf4475a8936902b8978fbb6c61016f8
commit: dd35ca2f2cac9d6439a2ba2f523b98b5a9a9f8f5 [358/388] mm-sparse-vmemmap-switch-device-dax-to-shared-tail-vmemmap-pages-fix
config: x86_64-allnoconfig-bpf (https://download.01.org/0day-ci/archive/20260910/202609101047.wFyYfjz9-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260910/202609101047.wFyYfjz9-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/202609101047.wFyYfjz9-lkp@intel.com/

All errors (new ones prefixed by >>):

   mm/sparse-vmemmap.c: In function 'vmemmap_populate_compound_pages':
   mm/sparse-vmemmap.c:507:48: error: implicit declaration of function 'device_zone'; did you mean 'device_move'? [-Wimplicit-function-declaration]
     507 |         page = vmemmap_shared_tail_page(order, device_zone(node));
         |                                                ^~~~~~~~~~~
         |                                                device_move
>> mm/sparse-vmemmap.c:507:48: error: passing argument 2 of 'vmemmap_shared_tail_page' makes pointer from integer without a cast [-Wint-conversion]
     507 |         page = vmemmap_shared_tail_page(order, device_zone(node));
         |                                                ^~~~~~~~~~~~~~~~~
         |                                                |
         |                                                int
   mm/sparse-vmemmap.c:172:78: note: expected 'struct zone *' but argument is of type 'int'
     172 | struct page __ref *vmemmap_shared_tail_page(unsigned int order, struct zone *zone)
         |                                                                 ~~~~~~~~~~~~~^~~~


vim +/vmemmap_shared_tail_page +507 mm/sparse-vmemmap.c

4917f55b4ef963 Joao Martins    2022-04-28  494  
4917f55b4ef963 Joao Martins    2022-04-28  495  static int __meminit vmemmap_populate_compound_pages(unsigned long start_pfn,
4917f55b4ef963 Joao Martins    2022-04-28  496  						     unsigned long start,
4917f55b4ef963 Joao Martins    2022-04-28  497  						     unsigned long end, int node,
4917f55b4ef963 Joao Martins    2022-04-28  498  						     struct dev_pagemap *pgmap)
4917f55b4ef963 Joao Martins    2022-04-28  499  {
4917f55b4ef963 Joao Martins    2022-04-28  500  	unsigned long size, addr;
4917f55b4ef963 Joao Martins    2022-04-28  501  	pte_t *pte;
4917f55b4ef963 Joao Martins    2022-04-28  502  	int rc;
d1d11861d8a018 Muchun Song     2026-09-08  503  	unsigned long flags = VMEMMAP_POPULATE_DAX;
8fbaacc4a64bd1 Muchun Song     2026-09-08  504  	struct page *page;
8fbaacc4a64bd1 Muchun Song     2026-09-08  505  	unsigned int order = pfn_to_section_order(start_pfn);
4917f55b4ef963 Joao Martins    2022-04-28  506  
8fbaacc4a64bd1 Muchun Song     2026-09-08 @507  	page = vmemmap_shared_tail_page(order, device_zone(node));
8fbaacc4a64bd1 Muchun Song     2026-09-08  508  	if (!page)
4917f55b4ef963 Joao Martins    2022-04-28  509  		return -ENOMEM;
4917f55b4ef963 Joao Martins    2022-04-28  510  
8fbaacc4a64bd1 Muchun Song     2026-09-08  511  	if (reuse_compound_section(start_pfn, pgmap))
4917f55b4ef963 Joao Martins    2022-04-28  512  		return vmemmap_populate_range(start, end, node, NULL,
8fbaacc4a64bd1 Muchun Song     2026-09-08  513  					      page_to_pfn(page), flags);
4917f55b4ef963 Joao Martins    2022-04-28  514  
8fbaacc4a64bd1 Muchun Song     2026-09-08  515  	size = min(end - start, (1UL << order) * sizeof(struct page));
4917f55b4ef963 Joao Martins    2022-04-28  516  	for (addr = start; addr < end; addr += size) {
55896f935a60b9 Gautam Menghani 2022-06-12  517  		unsigned long next, last = addr + size;
4917f55b4ef963 Joao Martins    2022-04-28  518  
4917f55b4ef963 Joao Martins    2022-04-28  519  		/* Populate the head page vmemmap page */
d1d11861d8a018 Muchun Song     2026-09-08  520  		pte = vmemmap_populate_address(addr, node, NULL, -1, flags);
4917f55b4ef963 Joao Martins    2022-04-28  521  		if (!pte)
4917f55b4ef963 Joao Martins    2022-04-28  522  			return -ENOMEM;
4917f55b4ef963 Joao Martins    2022-04-28  523  
4917f55b4ef963 Joao Martins    2022-04-28  524  		/* Populate the tail pages vmemmap page */
4917f55b4ef963 Joao Martins    2022-04-28  525  		next = addr + PAGE_SIZE;
d1d11861d8a018 Muchun Song     2026-09-08  526  		pte = vmemmap_populate_address(next, node, NULL, -1, flags);
4917f55b4ef963 Joao Martins    2022-04-28  527  		if (!pte)
4917f55b4ef963 Joao Martins    2022-04-28  528  			return -ENOMEM;
4917f55b4ef963 Joao Martins    2022-04-28  529  
4917f55b4ef963 Joao Martins    2022-04-28  530  		/*
8fbaacc4a64bd1 Muchun Song     2026-09-08  531  		 * Reuse the shared page for the rest of tail pages
ee65728e103bb7 Mike Rapoport   2022-06-27  532  		 * See layout diagram in Documentation/mm/vmemmap_dedup.rst
4917f55b4ef963 Joao Martins    2022-04-28  533  		 */
4917f55b4ef963 Joao Martins    2022-04-28  534  		next += PAGE_SIZE;
4917f55b4ef963 Joao Martins    2022-04-28  535  		rc = vmemmap_populate_range(next, last, node, NULL,
8fbaacc4a64bd1 Muchun Song     2026-09-08  536  					    page_to_pfn(page), flags);
4917f55b4ef963 Joao Martins    2022-04-28  537  		if (rc)
4917f55b4ef963 Joao Martins    2022-04-28  538  			return -ENOMEM;
4917f55b4ef963 Joao Martins    2022-04-28  539  	}
4917f55b4ef963 Joao Martins    2022-04-28  540  
4917f55b4ef963 Joao Martins    2022-04-28  541  	return 0;
2beea70a3edc03 Joao Martins    2022-04-28  542  }
2beea70a3edc03 Joao Martins    2022-04-28  543  

:::::: The code at line 507 was first introduced by commit
:::::: 8fbaacc4a64bd1bfbfb11bfb48b5db3f4943cbd7 mm/sparse-vmemmap: switch device DAX to shared tail vmemmap pages

:::::: TO: Muchun Song <songmuchun@bytedance.com>
:::::: CC: Andrew Morton <akpm@linux-foundation.org>

--
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:[~2026-09-10 15:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-10 15:42 [akpm-mm:mm-new 358/388] mm/sparse-vmemmap.c:507:48: error: passing argument 2 of 'vmemmap_shared_tail_page' makes pointer from integer without a cast kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.