linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* arch/x86/kvm/mmu/mmu.c:227:1: error: unused function 'is_cr4_la57'
@ 2021-09-02  8:54 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-09-02  8:54 UTC (permalink / raw)
  To: Sean Christopherson; +Cc: llvm, kbuild-all, linux-kernel, Paolo Bonzini

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   4ac6d90867a4de2e12117e755dbd76e08d88697f
commit: 6066772455f21ce1e90f003243c9864091621773 KVM: x86/mmu: Add accessors to query mmu_role bits
date:   10 weeks ago
config: i386-randconfig-r005-20210901 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 4b1fde8a2b681dad2ce0c082a5d6422caa06b0bc)
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
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=6066772455f21ce1e90f003243c9864091621773
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 6066772455f21ce1e90f003243c9864091621773
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=i386 

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 >>):

   arch/x86/kvm/mmu/mmu.c:220:1: error: unused function 'is_cr0_pg' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr0, pg);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:95:1: note: expanded from here
   is_cr0_pg
   ^
   arch/x86/kvm/mmu/mmu.c:221:1: error: unused function 'is_cr0_wp' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(base, cr0, wp);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:100:1: note: expanded from here
   is_cr0_wp
   ^
   arch/x86/kvm/mmu/mmu.c:222:1: error: unused function 'is_cr4_pse' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pse);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:105:1: note: expanded from here
   is_cr4_pse
   ^
   arch/x86/kvm/mmu/mmu.c:223:1: error: unused function 'is_cr4_pae' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pae);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:110:1: note: expanded from here
   is_cr4_pae
   ^
   arch/x86/kvm/mmu/mmu.c:225:1: error: unused function 'is_cr4_smap' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, smap);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:120:1: note: expanded from here
   is_cr4_smap
   ^
   arch/x86/kvm/mmu/mmu.c:226:1: error: unused function 'is_cr4_pke' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pke);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:125:1: note: expanded from here
   is_cr4_pke
   ^
>> arch/x86/kvm/mmu/mmu.c:227:1: error: unused function 'is_cr4_la57' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, la57);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:130:1: note: expanded from here
   is_cr4_la57
   ^
   arch/x86/kvm/mmu/mmu.c:228:1: error: unused function 'is_efer_nx' [-Werror,-Wunused-function]
   BUILD_MMU_ROLE_ACCESSOR(base, efer, nx);
   ^
   arch/x86/kvm/mmu/mmu.c:216:20: note: expanded from macro 'BUILD_MMU_ROLE_ACCESSOR'
   static inline bool is_##reg##_##name(struct kvm_mmu *mmu)       \
                      ^
   <scratch space>:135:1: note: expanded from here
   is_efer_nx
   ^
   8 errors generated.


vim +/is_cr4_la57 +227 arch/x86/kvm/mmu/mmu.c

   208	
   209	/*
   210	 * The MMU itself (with a valid role) is the single source of truth for the
   211	 * MMU.  Do not use the regs used to build the MMU/role, nor the vCPU.  The
   212	 * regs don't account for dependencies, e.g. clearing CR4 bits if CR0.PG=1,
   213	 * and the vCPU may be incorrect/irrelevant.
   214	 */
   215	#define BUILD_MMU_ROLE_ACCESSOR(base_or_ext, reg, name)		\
   216	static inline bool is_##reg##_##name(struct kvm_mmu *mmu)	\
   217	{								\
   218		return !!(mmu->mmu_role. base_or_ext . reg##_##name);	\
   219	}
   220	BUILD_MMU_ROLE_ACCESSOR(ext,  cr0, pg);
   221	BUILD_MMU_ROLE_ACCESSOR(base, cr0, wp);
   222	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pse);
   223	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pae);
   224	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, smep);
   225	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, smap);
   226	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, pke);
 > 227	BUILD_MMU_ROLE_ACCESSOR(ext,  cr4, la57);
   228	BUILD_MMU_ROLE_ACCESSOR(base, efer, nx);
   229	

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

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

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

only message in thread, other threads:[~2021-09-02  8:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-02  8:54 arch/x86/kvm/mmu/mmu.c:227:1: error: unused function 'is_cr4_la57' kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).