Re: [PATCH v11 9/9] KVM: X86: Set CET feature bits for CPUID enumeration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Yang,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on kvm/linux-next]
[also build test ERROR on next-20200326]
[cannot apply to vhost/linux-next tip/auto-latest linus/master linux/master v5.6-rc7]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Yang-Weijiang/Introduce-support-for-guest-CET-feature/20200327-040801
base:   https://git.kernel.org/pub/scm/virt/kvm/kvm.git linux-next
config: x86_64-randconfig-g001-20200327 (attached as .config)
compiler: gcc-7 (Debian 7.5.0-5) 7.5.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

   In file included from include/linux/kvm_host.h:36:0,
                    from arch/x86/kvm/emulate.c:21:
   arch/x86/kvm/emulate.c: In function 'check_cr_write':
>> arch/x86/include/asm/kvm_host.h:99:8: error: 'X86_CR4_CET' undeclared (first use in this function); did you mean 'X86_CR4_PCE'?
         | X86_CR4_CET))
           ^
   arch/x86/kvm/emulate.c:4206:3: note: in expansion of macro 'CR4_RESERVED_BITS'
      CR4_RESERVED_BITS,
      ^~~~~~~~~~~~~~~~~
   arch/x86/include/asm/kvm_host.h:99:8: note: each undeclared identifier is reported only once for each function it appears in
         | X86_CR4_CET))
           ^
   arch/x86/kvm/emulate.c:4206:3: note: in expansion of macro 'CR4_RESERVED_BITS'
      CR4_RESERVED_BITS,
      ^~~~~~~~~~~~~~~~~

vim +99 arch/x86/include/asm/kvm_host.h

    51	
    52	#define KVM_DIRTY_LOG_MANUAL_CAPS   (KVM_DIRTY_LOG_MANUAL_PROTECT_ENABLE | \
    53						KVM_DIRTY_LOG_INITIALLY_SET)
    54	
    55	/* x86-specific vcpu->requests bit members */
    56	#define KVM_REQ_MIGRATE_TIMER		KVM_ARCH_REQ(0)
    57	#define KVM_REQ_REPORT_TPR_ACCESS	KVM_ARCH_REQ(1)
    58	#define KVM_REQ_TRIPLE_FAULT		KVM_ARCH_REQ(2)
    59	#define KVM_REQ_MMU_SYNC		KVM_ARCH_REQ(3)
    60	#define KVM_REQ_CLOCK_UPDATE		KVM_ARCH_REQ(4)
    61	#define KVM_REQ_LOAD_MMU_PGD		KVM_ARCH_REQ(5)
    62	#define KVM_REQ_EVENT			KVM_ARCH_REQ(6)
    63	#define KVM_REQ_APF_HALT		KVM_ARCH_REQ(7)
    64	#define KVM_REQ_STEAL_UPDATE		KVM_ARCH_REQ(8)
    65	#define KVM_REQ_NMI			KVM_ARCH_REQ(9)
    66	#define KVM_REQ_PMU			KVM_ARCH_REQ(10)
    67	#define KVM_REQ_PMI			KVM_ARCH_REQ(11)
    68	#define KVM_REQ_SMI			KVM_ARCH_REQ(12)
    69	#define KVM_REQ_MASTERCLOCK_UPDATE	KVM_ARCH_REQ(13)
    70	#define KVM_REQ_MCLOCK_INPROGRESS \
    71		KVM_ARCH_REQ_FLAGS(14, KVM_REQUEST_WAIT | KVM_REQUEST_NO_WAKEUP)
    72	#define KVM_REQ_SCAN_IOAPIC \
    73		KVM_ARCH_REQ_FLAGS(15, KVM_REQUEST_WAIT | KVM_REQUEST_NO_WAKEUP)
    74	#define KVM_REQ_GLOBAL_CLOCK_UPDATE	KVM_ARCH_REQ(16)
    75	#define KVM_REQ_APIC_PAGE_RELOAD \
    76		KVM_ARCH_REQ_FLAGS(17, KVM_REQUEST_WAIT | KVM_REQUEST_NO_WAKEUP)
    77	#define KVM_REQ_HV_CRASH		KVM_ARCH_REQ(18)
    78	#define KVM_REQ_IOAPIC_EOI_EXIT		KVM_ARCH_REQ(19)
    79	#define KVM_REQ_HV_RESET		KVM_ARCH_REQ(20)
    80	#define KVM_REQ_HV_EXIT			KVM_ARCH_REQ(21)
    81	#define KVM_REQ_HV_STIMER		KVM_ARCH_REQ(22)
    82	#define KVM_REQ_LOAD_EOI_EXITMAP	KVM_ARCH_REQ(23)
    83	#define KVM_REQ_GET_VMCS12_PAGES	KVM_ARCH_REQ(24)
    84	#define KVM_REQ_APICV_UPDATE \
    85		KVM_ARCH_REQ_FLAGS(25, KVM_REQUEST_WAIT | KVM_REQUEST_NO_WAKEUP)
    86	
    87	#define CR0_RESERVED_BITS                                               \
    88		(~(unsigned long)(X86_CR0_PE | X86_CR0_MP | X86_CR0_EM | X86_CR0_TS \
    89				  | X86_CR0_ET | X86_CR0_NE | X86_CR0_WP | X86_CR0_AM \
    90				  | X86_CR0_NW | X86_CR0_CD | X86_CR0_PG))
    91	
    92	#define CR4_RESERVED_BITS                                               \
    93		(~(unsigned long)(X86_CR4_VME | X86_CR4_PVI | X86_CR4_TSD | X86_CR4_DE\
    94				  | X86_CR4_PSE | X86_CR4_PAE | X86_CR4_MCE     \
    95				  | X86_CR4_PGE | X86_CR4_PCE | X86_CR4_OSFXSR | X86_CR4_PCIDE \
    96				  | X86_CR4_OSXSAVE | X86_CR4_SMEP | X86_CR4_FSGSBASE \
    97				  | X86_CR4_OSXMMEXCPT | X86_CR4_LA57 | X86_CR4_VMXE \
    98				  | X86_CR4_SMAP | X86_CR4_PKE | X86_CR4_UMIP \
  > 99				  | X86_CR4_CET))
   100	

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux