All of lore.kernel.org
 help / color / mirror / Atom feed
* [sashal-linux-stable:queue-5.4 25/33] drivers/vfio/vfio_iommu_type1.c:366:22: error: implicit declaration of function 'pte_write'
@ 2021-03-22 21:04 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-03-22 21:04 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 6354 bytes --]

Hi Jason,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git queue-5.4
head:   52992c043a324332256525c1be1cd6b34b766048
commit: e2b35dbc9cd294d70cac30fbe89b14c526d813ec [25/33] vfio: IOMMU_API should be selected
config: arm-randconfig-r026-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 14696baaf4c43fe53f738bc292bbe169eed93d5d)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install arm cross compiling tool for clang build
        # apt-get install binutils-arm-linux-gnueabi
        # https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git/commit/?id=e2b35dbc9cd294d70cac30fbe89b14c526d813ec
        git remote add sashal-linux-stable https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
        git fetch --no-tags sashal-linux-stable queue-5.4
        git checkout e2b35dbc9cd294d70cac30fbe89b14c526d813ec
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> drivers/vfio/vfio_iommu_type1.c:366:22: error: implicit declaration of function 'pte_write' [-Werror,-Wimplicit-function-declaration]
           if (write_fault && !pte_write(*ptep))
                               ^
>> drivers/vfio/vfio_iommu_type1.c:369:10: error: implicit declaration of function 'pte_pfn' [-Werror,-Wimplicit-function-declaration]
                   *pfn = pte_pfn(*ptep);
                          ^
   drivers/vfio/vfio_iommu_type1.c:369:10: note: did you mean 'put_pfn'?
   drivers/vfio/vfio_iommu_type1.c:327:12: note: 'put_pfn' declared here
   static int put_pfn(unsigned long pfn, int prot)
              ^
>> drivers/vfio/vfio_iommu_type1.c:371:2: error: implicit declaration of function 'pte_unmap' [-Werror,-Wimplicit-function-declaration]
           pte_unmap_unlock(ptep, ptl);
           ^
   include/linux/mm.h:1988:2: note: expanded from macro 'pte_unmap_unlock'
           pte_unmap(pte);                                 \
           ^
   3 errors generated.
--
>> arch/arm/kernel/module-plts.c:67:34: error: implicit declaration of function '__opcode_to_mem_thumb32' [-Werror,-Wimplicit-function-declaration]
                           { [0 ... PLT_ENT_COUNT - 1] = PLT_ENT_LDR, },
                                                         ^
   arch/arm/kernel/module-plts.c:19:22: note: expanded from macro 'PLT_ENT_LDR'
   #define PLT_ENT_LDR             __opcode_to_mem_thumb32(0xf8dff000 | \
                                   ^
   arch/arm/kernel/module-plts.c:188:5: warning: no previous prototype for function 'module_frob_arch_sections' [-Wmissing-prototypes]
   int module_frob_arch_sections(Elf_Ehdr *ehdr, Elf_Shdr *sechdrs,
       ^
   arch/arm/kernel/module-plts.c:188:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   int module_frob_arch_sections(Elf_Ehdr *ehdr, Elf_Shdr *sechdrs,
   ^
   static 
   1 warning and 1 error generated.


vim +/pte_write +366 drivers/vfio/vfio_iommu_type1.c

73fa0d10d077d9 Alex Williamson 2012-07-31  338  
270c35d0723a2f Ajay Kaher      2020-09-06  339  static int follow_fault_pfn(struct vm_area_struct *vma, struct mm_struct *mm,
270c35d0723a2f Ajay Kaher      2020-09-06  340  			    unsigned long vaddr, unsigned long *pfn,
270c35d0723a2f Ajay Kaher      2020-09-06  341  			    bool write_fault)
270c35d0723a2f Ajay Kaher      2020-09-06  342  {
e41bb745fd0fca Alex Williamson 2021-02-16  343  	pte_t *ptep;
e41bb745fd0fca Alex Williamson 2021-02-16  344  	spinlock_t *ptl;
270c35d0723a2f Ajay Kaher      2020-09-06  345  	int ret;
270c35d0723a2f Ajay Kaher      2020-09-06  346  
e41bb745fd0fca Alex Williamson 2021-02-16  347  	ret = follow_pte(vma->vm_mm, vaddr, &ptep, &ptl);
270c35d0723a2f Ajay Kaher      2020-09-06  348  	if (ret) {
270c35d0723a2f Ajay Kaher      2020-09-06  349  		bool unlocked = false;
270c35d0723a2f Ajay Kaher      2020-09-06  350  
270c35d0723a2f Ajay Kaher      2020-09-06  351  		ret = fixup_user_fault(NULL, mm, vaddr,
270c35d0723a2f Ajay Kaher      2020-09-06  352  				       FAULT_FLAG_REMOTE |
270c35d0723a2f Ajay Kaher      2020-09-06  353  				       (write_fault ?  FAULT_FLAG_WRITE : 0),
270c35d0723a2f Ajay Kaher      2020-09-06  354  				       &unlocked);
270c35d0723a2f Ajay Kaher      2020-09-06  355  		if (unlocked)
270c35d0723a2f Ajay Kaher      2020-09-06  356  			return -EAGAIN;
270c35d0723a2f Ajay Kaher      2020-09-06  357  
270c35d0723a2f Ajay Kaher      2020-09-06  358  		if (ret)
270c35d0723a2f Ajay Kaher      2020-09-06  359  			return ret;
270c35d0723a2f Ajay Kaher      2020-09-06  360  
e41bb745fd0fca Alex Williamson 2021-02-16  361  		ret = follow_pte(vma->vm_mm, vaddr, &ptep, &ptl);
e41bb745fd0fca Alex Williamson 2021-02-16  362  		if (ret)
e41bb745fd0fca Alex Williamson 2021-02-16  363  			return ret;
270c35d0723a2f Ajay Kaher      2020-09-06  364  	}
270c35d0723a2f Ajay Kaher      2020-09-06  365  
e41bb745fd0fca Alex Williamson 2021-02-16 @366  	if (write_fault && !pte_write(*ptep))
e41bb745fd0fca Alex Williamson 2021-02-16  367  		ret = -EFAULT;
e41bb745fd0fca Alex Williamson 2021-02-16  368  	else
e41bb745fd0fca Alex Williamson 2021-02-16 @369  		*pfn = pte_pfn(*ptep);
e41bb745fd0fca Alex Williamson 2021-02-16  370  
e41bb745fd0fca Alex Williamson 2021-02-16 @371  	pte_unmap_unlock(ptep, ptl);
270c35d0723a2f Ajay Kaher      2020-09-06  372  	return ret;
270c35d0723a2f Ajay Kaher      2020-09-06  373  }
270c35d0723a2f Ajay Kaher      2020-09-06  374  

:::::: The code at line 366 was first introduced by commit
:::::: e41bb745fd0fcaa1d37a7bd4da46230822ffe18f vfio/type1: Use follow_pte()

:::::: TO: Alex Williamson <alex.williamson@redhat.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 26571 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-03-22 21:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-22 21:04 [sashal-linux-stable:queue-5.4 25/33] drivers/vfio/vfio_iommu_type1.c:366:22: error: implicit declaration of function 'pte_write' 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.