From: kbuild test robot <lkp@intel.com>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: kbuild-all@01.org, linux-kernel@vger.kernel.org,
"Gabriel L. Somlo" <gsomlo@gmail.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Radim Krčmář" <rkrcmar@redhat.com>,
"Jonathan Corbet" <corbet@lwn.net>,
"Thomas Gleixner" <tglx@linutronix.de>,
"Ingo Molnar" <mingo@redhat.com>,
"H. Peter Anvin" <hpa@zytor.com>,
x86@kernel.org, "Joerg Roedel" <joro@8bytes.org>,
kvm@vger.kernel.org, linux-doc@vger.kernel.org
Subject: Re: [PATCH v4] kvm: better MWAIT emulation for guests
Date: Thu, 16 Mar 2017 15:34:41 +0800 [thread overview]
Message-ID: <201703161558.dkk9XW6R%fengguang.wu@intel.com> (raw)
In-Reply-To: <1489605443-21045-1-git-send-email-mst@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 7298 bytes --]
Hi Michael,
[auto build test WARNING on kvm/linux-next]
[also build test WARNING on v4.11-rc2 next-20170310]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Michael-S-Tsirkin/kvm-better-MWAIT-emulation-for-guests/20170316-143518
base: https://git.kernel.org/pub/scm/virt/kvm/kvm.git linux-next
config: i386-randconfig-x018-201711 (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All warnings (new ones prefixed by >>):
In file included from include/uapi/linux/stddef.h:1:0,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/linux/kvm_host.h:9,
from arch/x86/kvm/x86.c:22:
arch/x86/kvm/x86.h: In function 'kvm_mwait_in_guest':
arch/x86/kvm/x86.h:231:34: error: 'CPUID_MWAIT_LEAF' undeclared (first use in this function)
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
>> arch/x86/kvm/x86.h:231:2: note: in expansion of macro 'if'
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^~
arch/x86/kvm/x86.h:231:34: note: each undeclared identifier is reported only once for each function it appears in
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
>> arch/x86/kvm/x86.h:231:2: note: in expansion of macro 'if'
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^~
In file included from arch/x86/kvm/x86.c:28:0:
arch/x86/kvm/x86.h:234:45: error: 'mwait_substates' undeclared (first use in this function)
cpuid(CPUID_MWAIT_LEAF, &eax, &ebx, &ecx, &mwait_substates);
^~~~~~~~~~~~~~~
In file included from include/uapi/linux/stddef.h:1:0,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/linux/kvm_host.h:9,
from arch/x86/kvm/x86.c:22:
arch/x86/kvm/x86.h:236:14: error: 'CPUID5_ECX_INTERRUPT_BREAK' undeclared (first use in this function)
if (!(ecx & CPUID5_ECX_INTERRUPT_BREAK))
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
arch/x86/kvm/x86.h:236:2: note: in expansion of macro 'if'
if (!(ecx & CPUID5_ECX_INTERRUPT_BREAK))
^~
In file included from arch/x86/kvm/x86.c:28:0:
arch/x86/kvm/x86.h:238:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
--
In file included from include/uapi/linux/stddef.h:1:0,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/linux/mm_types_task.h:10,
from include/linux/mm_types.h:4,
from arch/x86/kvm/irq.h:25,
from arch/x86/kvm/mmu.c:21:
arch/x86/kvm/x86.h: In function 'kvm_mwait_in_guest':
arch/x86/kvm/x86.h:231:34: error: 'CPUID_MWAIT_LEAF' undeclared (first use in this function)
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
>> arch/x86/kvm/x86.h:231:2: note: in expansion of macro 'if'
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^~
arch/x86/kvm/x86.h:231:34: note: each undeclared identifier is reported only once for each function it appears in
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
>> arch/x86/kvm/x86.h:231:2: note: in expansion of macro 'if'
if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
^~
In file included from arch/x86/kvm/mmu.c:23:0:
arch/x86/kvm/x86.h:234:45: error: 'mwait_substates' undeclared (first use in this function)
cpuid(CPUID_MWAIT_LEAF, &eax, &ebx, &ecx, &mwait_substates);
^~~~~~~~~~~~~~~
In file included from include/uapi/linux/stddef.h:1:0,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/linux/mm_types_task.h:10,
from include/linux/mm_types.h:4,
from arch/x86/kvm/irq.h:25,
from arch/x86/kvm/mmu.c:21:
arch/x86/kvm/x86.h:236:14: error: 'CPUID5_ECX_INTERRUPT_BREAK' undeclared (first use in this function)
if (!(ecx & CPUID5_ECX_INTERRUPT_BREAK))
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^~~~
arch/x86/kvm/x86.h:236:2: note: in expansion of macro 'if'
if (!(ecx & CPUID5_ECX_INTERRUPT_BREAK))
^~
In file included from arch/x86/kvm/mmu.c:23:0:
At top level:
arch/x86/kvm/x86.h:216:13: warning: 'kvm_mwait_in_guest' defined but not used [-Wunused-function]
static bool kvm_mwait_in_guest(void)
^~~~~~~~~~~~~~~~~~
vim +/if +231 arch/x86/kvm/x86.h
215
216 static bool kvm_mwait_in_guest(void)
217 {
218 unsigned int eax, ebx, ecx;
219
220 if (!cpu_has(&boot_cpu_data, X86_FEATURE_MWAIT))
221 return -ENODEV;
222
223 if (boot_cpu_data.x86_vendor != X86_VENDOR_INTEL)
224 return -ENODEV;
225
226 /*
227 * Intel CPUs without CPUID5_ECX_INTERRUPT_BREAK are problematic as
228 * they would allow guest to stop the CPU completely by disabling
229 * interrupts then invoking MWAIT.
230 */
> 231 if (boot_cpu_data.cpuid_level < CPUID_MWAIT_LEAF)
232 return -ENODEV;
233
234 cpuid(CPUID_MWAIT_LEAF, &eax, &ebx, &ecx, &mwait_substates);
235
236 if (!(ecx & CPUID5_ECX_INTERRUPT_BREAK))
237 return -ENODEV;
238 }
239
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 32586 bytes --]
prev parent reply other threads:[~2017-03-16 7:35 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-15 19:28 Michael S. Tsirkin
2017-03-15 20:13 ` Radim Krčmář
2017-03-15 20:21 ` Gabriel L. Somlo
2017-03-15 20:25 ` Gabriel L. Somlo
2017-03-15 20:46 ` Radim Krčmář
2017-03-15 23:22 ` Gabriel L. Somlo
2017-03-16 9:30 ` Wanpeng Li
2017-03-16 7:26 ` kbuild test robot
2017-03-16 7:34 ` kbuild test robot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201703161558.dkk9XW6R%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=corbet@lwn.net \
--cc=gsomlo@gmail.com \
--cc=hpa@zytor.com \
--cc=joro@8bytes.org \
--cc=kbuild-all@01.org \
--cc=kvm@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=rkrcmar@redhat.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®