All of lore.kernel.org
 help / color / mirror / Atom feed
* [openeuler:OLK-6.6 3214/3214] mm/memory.c:2802:5: sparse: sparse: symbol '__remap_pfn_range' was not declared. Should it be static?
@ 2025-11-18 16:46 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-11-18 16:46 UTC (permalink / raw)
  To: kernel, Yin Tirui; +Cc: oe-kbuild-all

tree:   https://gitee.com/openeuler/kernel.git OLK-6.6
head:   b4a3c05741e1650e8bb8399196fb5d7a318a4698
commit: 923e224a12462d640fa37f3069c6bfafd378ac3b [3214/3214] mm: introduce remap_pfn_range_try_pmd() for PMD-level hugepage mapping
config: x86_64-randconfig-r111-20251118 (https://download.01.org/0day-ci/archive/20251119/202511190025.obom3fen-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/20251119/202511190025.obom3fen-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/202511190025.obom3fen-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> mm/memory.c:2802:5: sparse: sparse: symbol '__remap_pfn_range' was not declared. Should it be static?
   mm/memory.c:301:9: sparse: sparse: incompatible types in conditional expression (different base types):
   mm/memory.c:301:9: sparse:    void
   mm/memory.c:301:9: sparse:    int

vim +/__remap_pfn_range +2802 mm/memory.c

  2789	
  2790	/**
  2791	 * remap_pfn_range - remap kernel memory to userspace
  2792	 * @vma: user vma to map to
  2793	 * @addr: target page aligned user address to start at
  2794	 * @pfn: page frame number of kernel physical memory address
  2795	 * @size: size of mapping area
  2796	 * @prot: page protection flags for this mapping
  2797	 *
  2798	 * Note: this is only safe if the mm semaphore is held when called.
  2799	 *
  2800	 * Return: %0 on success, negative error code otherwise.
  2801	 */
> 2802	int __remap_pfn_range(struct vm_area_struct *vma, unsigned long addr,
  2803			    unsigned long pfn, unsigned long size, pgprot_t prot,
  2804				unsigned int page_shift)
  2805	{
  2806		int err;
  2807	
  2808		err = track_pfn_remap(vma, &prot, pfn, addr, PAGE_ALIGN(size));
  2809		if (err)
  2810			return -EINVAL;
  2811	
  2812		err = __remap_pfn_range_notrack(vma, addr, pfn, size, prot, page_shift);
  2813		if (err)
  2814			untrack_pfn(vma, pfn, PAGE_ALIGN(size), true);
  2815		return err;
  2816	}
  2817	

-- 
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:[~2025-11-18 16:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-18 16:46 [openeuler:OLK-6.6 3214/3214] mm/memory.c:2802:5: sparse: sparse: symbol '__remap_pfn_range' was not declared. Should it be static? 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.