public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370
@ 2017-03-07 15:49 Dexuan Cui
  2017-03-08  1:06 ` Wanpeng Li
  2017-03-09  3:02 ` Han, Huaitong
  0 siblings, 2 replies; 4+ messages in thread
From: Dexuan Cui @ 2017-03-07 15:49 UTC (permalink / raw)
  To: kvm@vger.kernel.org

With today's git://git.kernel.org/pub/scm/virt/kvm/kvm.git (4.11.0-rc1+),  
I got this warning on the host and the VM hung.

Any idea?

[  124.238033] net0: port 2(tap0) entered blocking state
[  124.238047] net0: port 2(tap0) entered forwarding state
[  146.117829] kvm [2853]: vcpu0, guest rIP: 0xffffffff810644b8 disabled perfctr wrmsr: 0xc2 data 0xffff
[  550.713144] walk_shadow_page_get_mmio_spte: detect reserved bits on spte, addr 0x7f48b000, dump hierarchy:
[  550.713175] ------ spte 0x252364107 level 4.
[  550.713186] ------ spte 0x252b14107 level 3.
[  550.713197] ------ spte 0x252d60107 level 2.
[  550.713207] ------ spte 0x224000055 level 1.
[  550.713218] ------------[ cut here ]------------
[  550.713250] WARNING: CPU: 7 PID: 2877 at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370 [kvm]
[  550.713278] Modules linked in: bridge stp llc bnep rfcomm bluetooth nfsd auth_rpcgss nfs_acl nfs lockd grace sunrpc fscache nls_iso8859_1 radeon snd_hda_codec_realtek x86_pkg_temp_thermal snd_hda_codec_generic snd_hda_codec_hdmi intel_powerclamp snd_hda_intel coretemp snd_hda_codec kvm_intel kvm snd_hda_core i2c_algo_bit irqbypass drm_kms_helper snd_pcm crct10dif_pclmul syscopyarea sysfillrect sysimgblt fb_sys_fops snd_hwdep snd_seq_midi snd_seq_midi_event crc32_pclmul snd_rawmidi ttm ghash_clmulni_intel drm snd_seq aesni_intel aes_x86_64 snd_timer crypto_simd snd_seq_device cryptd snd mei_me hp_wmi ppdev sparse_keymap shpchp wmi soundcore glue_helper mei parport_pc lpc_ich mac_hid serio_raw lp parport e1000e ahci ptp psmouse libahci pps_core
[  550.713475] CPU: 7 PID: 2877 Comm: qemu-system-x86 Not tainted 4.11.0-rc1+ #4
[  550.713495] Hardware name: Hewlett-Packard HP Z230 SFF Workstation/1906, BIOS L51 v01.18 01/23/2014
[  550.713520] Call Trace:
[  550.713531]  dump_stack+0x63/0x90
[  550.713543]  __warn+0xd1/0xf0
[  550.713553]  warn_slowpath_null+0x1d/0x20
[  550.713574]  handle_mmio_page_fault+0x362/0x370 [kvm]
[  550.713591]  handle_ept_misconfig+0x42/0x120 [kvm_intel]
[  550.713608]  vmx_handle_exit+0x127/0x13e0 [kvm_intel]
[  550.713631]  kvm_arch_vcpu_ioctl_run+0xb1e/0x1570 [kvm]
[  550.713647]  ? futex_wake+0x81/0x150
[  550.713666]  ? kvm_arch_vcpu_load+0x57/0x270 [kvm]
[  550.713686]  kvm_vcpu_ioctl+0x2fd/0x580 [kvm]
[  550.713700]  ? pick_next_task_fair+0x404/0x530
[  550.713715]  ? __switch_to+0x22d/0x4c0
[  550.713727]  do_vfs_ioctl+0x90/0x5b0
[  550.713745]  ? kvm_on_user_return+0x66/0xa0 [kvm]
[  550.713760]  ? fire_user_return_notifiers+0x3b/0x50
[  550.713774]  SyS_ioctl+0x79/0x90
[  550.713785]  entry_SYSCALL_64_fastpath+0x1e/0xad
[  550.713799] RIP: 0033:0x7f4a24b41337
[  550.713810] RSP: 002b:00007f4a1cd56a48 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
[  550.713832] RAX: ffffffffffffffda RBX: 000000000000ae80 RCX: 00007f4a24b41337
[  550.713852] RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000014
[  550.713872] RBP: 000055bc147e3660 R08: 000055bc1364e050 R09: 0000000000000000
[  550.713891] R10: 0000000000000005 R11: 0000000000000246 R12: 0000000000000000
[  550.713911] R13: 0000000000000007 R14: 00007f4a26d1b000 R15: 000055bc147e3660
[  550.713932] ---[ end trace 0fddbd81a6b111df ]---
[  550.713945] ------------[ cut here ]------------
[  550.713969] WARNING: CPU: 7 PID: 2877 at arch/x86/kvm/vmx.c:6311 handle_ept_misconfig+0xdf/0x120 [kvm_intel]
[  550.715027] Modules linked in: bridge stp llc bnep rfcomm bluetooth nfsd auth_rpcgss nfs_acl nfs lockd grace sunrpc fscache nls_iso8859_1 radeon snd_hda_codec_realtek x86_pkg_temp_thermal snd_hda_codec_generic snd_hda_codec_hdmi intel_powerclamp snd_hda_intel coretemp snd_hda_codec kvm_intel kvm snd_hda_core i2c_algo_bit irqbypass drm_kms_helper snd_pcm crct10dif_pclmul syscopyarea sysfillrect sysimgblt fb_sys_fops snd_hwdep snd_seq_midi snd_seq_midi_event crc32_pclmul snd_rawmidi ttm ghash_clmulni_intel drm snd_seq aesni_intel aes_x86_64 snd_timer crypto_simd snd_seq_device cryptd snd mei_me hp_wmi ppdev sparse_keymap shpchp wmi soundcore glue_helper mei parport_pc lpc_ich mac_hid serio_raw lp parport e1000e ahci ptp psmouse libahci pps_core
[  550.719604] CPU: 7 PID: 2877 Comm: qemu-system-x86 Tainted: G        W       4.11.0-rc1+ #4
[  550.720721] Hardware name: Hewlett-Packard HP Z230 SFF Workstation/1906, BIOS L51 v01.18 01/23/2014
[  550.722373] Call Trace:
[  550.724293]  dump_stack+0x63/0x90
[  550.726185]  __warn+0xd1/0xf0
[  550.728122]  warn_slowpath_null+0x1d/0x20
[  550.730129]  handle_ept_misconfig+0xdf/0x120 [kvm_intel]
[  550.732170]  vmx_handle_exit+0x127/0x13e0 [kvm_intel]
[  550.734239]  kvm_arch_vcpu_ioctl_run+0xb1e/0x1570 [kvm]
[  550.736279]  ? futex_wake+0x81/0x150
[  550.738158]  ? kvm_arch_vcpu_load+0x57/0x270 [kvm]
[  550.740033]  kvm_vcpu_ioctl+0x2fd/0x580 [kvm]
[  550.741844]  ? pick_next_task_fair+0x404/0x530
[  550.743646]  ? __switch_to+0x22d/0x4c0
[  550.745443]  do_vfs_ioctl+0x90/0x5b0
[  550.747252]  ? kvm_on_user_return+0x66/0xa0 [kvm]
[  550.749063]  ? fire_user_return_notifiers+0x3b/0x50
[  550.750864]  SyS_ioctl+0x79/0x90
[  550.752672]  entry_SYSCALL_64_fastpath+0x1e/0xad
[  550.754470] RIP: 0033:0x7f4a24b41337
[  550.756252] RSP: 002b:00007f4a1cd56a48 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
[  550.758057] RAX: ffffffffffffffda RBX: 000000000000ae80 RCX: 00007f4a24b41337
[  550.759876] RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000014
[  550.761689] RBP: 000055bc147e3660 R08: 000055bc1364e050 R09: 0000000000000000
[  550.763493] R10: 0000000000000005 R11: 0000000000000246 R12: 0000000000000000
[  550.765307] R13: 0000000000000007 R14: 00007f4a26d1b000 R15: 000055bc147e3660
[  550.767131] ---[ end trace 0fddbd81a6b111e0 ]---
[ 1137.920049] net0: port 2(tap0) entered disabled state
[ 1137.924350] device tap0 left promiscuous mode
[ 1137.927687] net0: port 2(tap0) entered disabled state

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370
  2017-03-07 15:49 WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370 Dexuan Cui
@ 2017-03-08  1:06 ` Wanpeng Li
  2017-03-08  6:36   ` Dexuan Cui
  2017-03-09  3:02 ` Han, Huaitong
  1 sibling, 1 reply; 4+ messages in thread
From: Wanpeng Li @ 2017-03-08  1:06 UTC (permalink / raw)
  To: Dexuan Cui; +Cc: kvm@vger.kernel.org

2017-03-07 23:49 GMT+08:00 Dexuan Cui <decui@microsoft.com>:
> With today's git://git.kernel.org/pub/scm/virt/kvm/kvm.git (4.11.0-rc1+),
> I got this warning on the host and the VM hung.
>
> Any idea?

How to reproduce?

>
> [  124.238033] net0: port 2(tap0) entered blocking state
> [  124.238047] net0: port 2(tap0) entered forwarding state
> [  146.117829] kvm [2853]: vcpu0, guest rIP: 0xffffffff810644b8 disabled perfctr wrmsr: 0xc2 data 0xffff
> [  550.713144] walk_shadow_page_get_mmio_spte: detect reserved bits on spte, addr 0x7f48b000, dump hierarchy:
> [  550.713175] ------ spte 0x252364107 level 4.
> [  550.713186] ------ spte 0x252b14107 level 3.
> [  550.713197] ------ spte 0x252d60107 level 2.
> [  550.713207] ------ spte 0x224000055 level 1.
> [  550.713218] ------------[ cut here ]------------
> [  550.713250] WARNING: CPU: 7 PID: 2877 at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370 [kvm]
> [  550.713278] Modules linked in: bridge stp llc bnep rfcomm bluetooth nfsd auth_rpcgss nfs_acl nfs lockd grace sunrpc fscache nls_iso8859_1 radeon snd_hda_codec_realtek x86_pkg_temp_thermal snd_hda_codec_generic snd_hda_codec_hdmi intel_powerclamp snd_hda_intel coretemp snd_hda_codec kvm_intel kvm snd_hda_core i2c_algo_bit irqbypass drm_kms_helper snd_pcm crct10dif_pclmul syscopyarea sysfillrect sysimgblt fb_sys_fops snd_hwdep snd_seq_midi snd_seq_midi_event crc32_pclmul snd_rawmidi ttm ghash_clmulni_intel drm snd_seq aesni_intel aes_x86_64 snd_timer crypto_simd snd_seq_device cryptd snd mei_me hp_wmi ppdev sparse_keymap shpchp wmi soundcore glue_helper mei parport_pc lpc_ich mac_hid serio_raw lp parport e1000e ahci ptp psmouse libahci pps_core
> [  550.713475] CPU: 7 PID: 2877 Comm: qemu-system-x86 Not tainted 4.11.0-rc1+ #4
> [  550.713495] Hardware name: Hewlett-Packard HP Z230 SFF Workstation/1906, BIOS L51 v01.18 01/23/2014
> [  550.713520] Call Trace:
> [  550.713531]  dump_stack+0x63/0x90
> [  550.713543]  __warn+0xd1/0xf0
> [  550.713553]  warn_slowpath_null+0x1d/0x20
> [  550.713574]  handle_mmio_page_fault+0x362/0x370 [kvm]
> [  550.713591]  handle_ept_misconfig+0x42/0x120 [kvm_intel]
> [  550.713608]  vmx_handle_exit+0x127/0x13e0 [kvm_intel]
> [  550.713631]  kvm_arch_vcpu_ioctl_run+0xb1e/0x1570 [kvm]
> [  550.713647]  ? futex_wake+0x81/0x150
> [  550.713666]  ? kvm_arch_vcpu_load+0x57/0x270 [kvm]
> [  550.713686]  kvm_vcpu_ioctl+0x2fd/0x580 [kvm]
> [  550.713700]  ? pick_next_task_fair+0x404/0x530
> [  550.713715]  ? __switch_to+0x22d/0x4c0
> [  550.713727]  do_vfs_ioctl+0x90/0x5b0
> [  550.713745]  ? kvm_on_user_return+0x66/0xa0 [kvm]
> [  550.713760]  ? fire_user_return_notifiers+0x3b/0x50
> [  550.713774]  SyS_ioctl+0x79/0x90
> [  550.713785]  entry_SYSCALL_64_fastpath+0x1e/0xad
> [  550.713799] RIP: 0033:0x7f4a24b41337
> [  550.713810] RSP: 002b:00007f4a1cd56a48 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
> [  550.713832] RAX: ffffffffffffffda RBX: 000000000000ae80 RCX: 00007f4a24b41337
> [  550.713852] RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000014
> [  550.713872] RBP: 000055bc147e3660 R08: 000055bc1364e050 R09: 0000000000000000
> [  550.713891] R10: 0000000000000005 R11: 0000000000000246 R12: 0000000000000000
> [  550.713911] R13: 0000000000000007 R14: 00007f4a26d1b000 R15: 000055bc147e3660
> [  550.713932] ---[ end trace 0fddbd81a6b111df ]---
> [  550.713945] ------------[ cut here ]------------
> [  550.713969] WARNING: CPU: 7 PID: 2877 at arch/x86/kvm/vmx.c:6311 handle_ept_misconfig+0xdf/0x120 [kvm_intel]
> [  550.715027] Modules linked in: bridge stp llc bnep rfcomm bluetooth nfsd auth_rpcgss nfs_acl nfs lockd grace sunrpc fscache nls_iso8859_1 radeon snd_hda_codec_realtek x86_pkg_temp_thermal snd_hda_codec_generic snd_hda_codec_hdmi intel_powerclamp snd_hda_intel coretemp snd_hda_codec kvm_intel kvm snd_hda_core i2c_algo_bit irqbypass drm_kms_helper snd_pcm crct10dif_pclmul syscopyarea sysfillrect sysimgblt fb_sys_fops snd_hwdep snd_seq_midi snd_seq_midi_event crc32_pclmul snd_rawmidi ttm ghash_clmulni_intel drm snd_seq aesni_intel aes_x86_64 snd_timer crypto_simd snd_seq_device cryptd snd mei_me hp_wmi ppdev sparse_keymap shpchp wmi soundcore glue_helper mei parport_pc lpc_ich mac_hid serio_raw lp parport e1000e ahci ptp psmouse libahci pps_core
> [  550.719604] CPU: 7 PID: 2877 Comm: qemu-system-x86 Tainted: G        W       4.11.0-rc1+ #4
> [  550.720721] Hardware name: Hewlett-Packard HP Z230 SFF Workstation/1906, BIOS L51 v01.18 01/23/2014
> [  550.722373] Call Trace:
> [  550.724293]  dump_stack+0x63/0x90
> [  550.726185]  __warn+0xd1/0xf0
> [  550.728122]  warn_slowpath_null+0x1d/0x20
> [  550.730129]  handle_ept_misconfig+0xdf/0x120 [kvm_intel]
> [  550.732170]  vmx_handle_exit+0x127/0x13e0 [kvm_intel]
> [  550.734239]  kvm_arch_vcpu_ioctl_run+0xb1e/0x1570 [kvm]
> [  550.736279]  ? futex_wake+0x81/0x150
> [  550.738158]  ? kvm_arch_vcpu_load+0x57/0x270 [kvm]
> [  550.740033]  kvm_vcpu_ioctl+0x2fd/0x580 [kvm]
> [  550.741844]  ? pick_next_task_fair+0x404/0x530
> [  550.743646]  ? __switch_to+0x22d/0x4c0
> [  550.745443]  do_vfs_ioctl+0x90/0x5b0
> [  550.747252]  ? kvm_on_user_return+0x66/0xa0 [kvm]
> [  550.749063]  ? fire_user_return_notifiers+0x3b/0x50
> [  550.750864]  SyS_ioctl+0x79/0x90
> [  550.752672]  entry_SYSCALL_64_fastpath+0x1e/0xad
> [  550.754470] RIP: 0033:0x7f4a24b41337
> [  550.756252] RSP: 002b:00007f4a1cd56a48 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
> [  550.758057] RAX: ffffffffffffffda RBX: 000000000000ae80 RCX: 00007f4a24b41337
> [  550.759876] RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000014
> [  550.761689] RBP: 000055bc147e3660 R08: 000055bc1364e050 R09: 0000000000000000
> [  550.763493] R10: 0000000000000005 R11: 0000000000000246 R12: 0000000000000000
> [  550.765307] R13: 0000000000000007 R14: 00007f4a26d1b000 R15: 000055bc147e3660
> [  550.767131] ---[ end trace 0fddbd81a6b111e0 ]---
> [ 1137.920049] net0: port 2(tap0) entered disabled state
> [ 1137.924350] device tap0 left promiscuous mode
> [ 1137.927687] net0: port 2(tap0) entered disabled state
>
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370
  2017-03-08  1:06 ` Wanpeng Li
@ 2017-03-08  6:36   ` Dexuan Cui
  0 siblings, 0 replies; 4+ messages in thread
From: Dexuan Cui @ 2017-03-08  6:36 UTC (permalink / raw)
  To: Wanpeng Li; +Cc: kvm@vger.kernel.org

> From: Wanpeng Li [mailto:kernellwp@gmail.com]
> Sent: Wednesday, March 8, 2017 09:07
> To: Dexuan Cui <decui@microsoft.com>
> Cc: kvm@vger.kernel.org
> Subject: Re: WARNING: at arch/x86/kvm/mmu.c:3589
> handle_mmio_page_fault+0x362/0x370 [kvm]
> 
> 2017-03-07 23:49 GMT+08:00 Dexuan Cui <decui@microsoft.com>:
> > With today's git://git.kernel.org/pub/scm/virt/kvm/kvm.git (4.11.0-rc1+),
> > I got this warning on the host and the VM hung.
> >
> > Any idea?
> 
> How to reproduce?

My host's CPU is "Intel(R) Xeon(R) CPU E3-1240 v3 @ 3.40GHz" and 
the kernel version is 4.11.0-rc1+ (i.e. today's mainline, c1ae3cfa0e).

My qemu is yesterday's qemu:
 git://git.qemu-project.org/qemu.git, commit d6780c822144.

I installed a Ubuntu 16.04 VM from .iso and tried to build the same
kernel in the VM with "make -j8" and got the issue. 

This is the command I used to start the VM:
qemu-system-x86_64 -enable-kvm -smp 8 -m 4096 
	-drive file=/root/kvm/u1604/u1604.img,format=raw,if=virtio
	-netdev type=tap,script=/etc/qemu-ifup,id=net0 -device
	virtio-net-pci,netdev=net0 
	-cdrom /root/kvm/u1604/ubuntu-16.04.1-desktop-amd64.iso

It looks I only reproduced it once: today I tried the same steps, but
couldn't reproduce it any more.

I post the related info here in case others may see the same issue.

Thanks,
-- Dexuan


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370
  2017-03-07 15:49 WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370 Dexuan Cui
  2017-03-08  1:06 ` Wanpeng Li
@ 2017-03-09  3:02 ` Han, Huaitong
  1 sibling, 0 replies; 4+ messages in thread
From: Han, Huaitong @ 2017-03-09  3:02 UTC (permalink / raw)
  To: decui@microsoft.com; +Cc: kvm@vger.kernel.org

On Tue, 2017-03-07 at 15:49 +0000, Dexuan Cui wrote:
> With today's git://git.kernel.org/pub/scm/virt/kvm/kvm.git (4.11.0-rc1+),  
> I got this warning on the host and the VM hung.
> 
> Any idea?
> 
> [  124.238033] net0: port 2(tap0) entered blocking state
> [  124.238047] net0: port 2(tap0) entered forwarding state
> [  146.117829] kvm [2853]: vcpu0, guest rIP: 0xffffffff810644b8 disabled perfctr wrmsr: 0xc2 data 0xffff
> [  550.713144] walk_shadow_page_get_mmio_spte: detect reserved bits on spte, addr 0x7f48b000, dump hierarchy:
> [  550.713175] ------ spte 0x252364107 level 4.
> [  550.713186] ------ spte 0x252b14107 level 3.
> [  550.713197] ------ spte 0x252d60107 level 2.
> [  550.713207] ------ spte 0x224000055 level 1.

Bit3-5 of pte 0x224000055 is memory type, the value is 2 leads EPT
misconfig, the root cause cannot be found only with code reading, it
depends on you to reproduce the issue repeatedly.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-03-09  4:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-07 15:49 WARNING: at arch/x86/kvm/mmu.c:3589 handle_mmio_page_fault+0x362/0x370 Dexuan Cui
2017-03-08  1:06 ` Wanpeng Li
2017-03-08  6:36   ` Dexuan Cui
2017-03-09  3:02 ` Han, Huaitong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox