* [freescale-fslc:6.6-1.0.x-imx 3832/11728] drivers/vfio/fsl-mc/vfio_fsl_mc.c:375:45: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct pgprot'} from type 'int'
@ 2024-04-27 22:26 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-04-27 22:26 UTC (permalink / raw
To: Otavio Salvador; +Cc: oe-kbuild-all
tree: https://github.com/Freescale/linux-fslc 6.6-1.0.x-imx
head: 37770f55ac9c4f6cd958eb5544939207eed8478f
commit: 156e54bbc99018164252576ccb464eaf23a84266 [3832/11728] vfio/fsl-mc: Map the VFIO region according to the flags received from the mc firmware
config: x86_64-buildonly-randconfig-001-20240428 (https://download.01.org/0day-ci/archive/20240428/202404280605.XStxDLHa-lkp@intel.com/config)
compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240428/202404280605.XStxDLHa-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/202404280605.XStxDLHa-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/vfio/fsl-mc/vfio_fsl_mc.c: In function 'vfio_fsl_mc_mmap_mmio':
drivers/vfio/fsl-mc/vfio_fsl_mc.c:375:45: error: implicit declaration of function 'pgprot_cached_ns' [-Werror=implicit-function-declaration]
375 | vma->vm_page_prot = pgprot_cached_ns(vma->vm_page_prot);
| ^~~~~~~~~~~~~~~~
>> drivers/vfio/fsl-mc/vfio_fsl_mc.c:375:45: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct pgprot'} from type 'int'
cc1: some warnings being treated as errors
vim +375 drivers/vfio/fsl-mc/vfio_fsl_mc.c
359
360 static int vfio_fsl_mc_mmap_mmio(struct vfio_fsl_mc_region region,
361 struct vm_area_struct *vma)
362 {
363 u64 size = vma->vm_end - vma->vm_start;
364 u64 pgoff, base;
365
366 pgoff = vma->vm_pgoff &
367 ((1U << (VFIO_FSL_MC_OFFSET_SHIFT - PAGE_SHIFT)) - 1);
368 base = pgoff << PAGE_SHIFT;
369
370 if (region.size < PAGE_SIZE || base + size > region.size)
371 return -EINVAL;
372
373 if (region.type & FSL_MC_REGION_CACHEABLE) {
374 if (!(region.type & FSL_MC_REGION_SHAREABLE))
> 375 vma->vm_page_prot = pgprot_cached_ns(vma->vm_page_prot);
376 } else
377 vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot);
378
379 vma->vm_pgoff = (region.addr >> PAGE_SHIFT) + pgoff;
380
381 return remap_pfn_range(vma, vma->vm_start, vma->vm_pgoff,
382 size, vma->vm_page_prot);
383 }
384
--
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:[~2024-04-27 22:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-27 22:26 [freescale-fslc:6.6-1.0.x-imx 3832/11728] drivers/vfio/fsl-mc/vfio_fsl_mc.c:375:45: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct pgprot'} from type 'int' 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.