[Bug 1714420] Re: kernel oops - kvm guest started at boot time
*** This bug is a duplicate of bug 1710646 *** https://bugs.launchpad.net/bugs/1710646 Was fixed in upstream stable 4.4.80 as "KVM: PPC: Book3S HV: Reload HTM registers explicitly". I will mark this bug as duplicate of the stable tracking bug for reference. ** This bug has been marked a duplicate of bug 1710646 Xenial update to 4.4.80 stable release -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
** Also affects: linux (Ubuntu Xenial) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
** Description changed: + [SRU Justification] + + [Impact] + System OOPSes shortly after boot when KVM guests are started. + + [Fix] + Cherry-pick patch e47057151422a67ce08747176fa21cb3b526a2c9 + + [Testcase] + Tested at IBM - boot a machine with a KVM guest configured to start at boot. Without this patch, observe OOPS, with this patch, observe no OOPS. + + [Regression Potential] + Patch is contained in arch/powerpc; so regression potential limited to that arch. Patch accepted to kernel stable trees, suggesting others also believe it to be of low risk. + + [Original Report] + [0.00] Linux version 4.4.0-93-generic (buildd@bos01-ppc64el-025) (gcc version 5.4.0 20160609 (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.4) ) #116-Ubuntu SMP Fri Aug 11 16:30:16 UTC 2017 (Ubuntu 4.4.0-93.116-generic 4.4.79) ... [ 380.184554] KVM guest htab at c0799900 (order 29), LPID 2 [ 380.527576] Facility 'TM' unavailable, exception at 0xd0003aad7f10, MSR=90009033 [ 380.527717] Oops: Unexpected facility unavailable exception, sig: 6 [#2] [ 380.527775] SMP NR_CPUS=2048 NUMA PowerNV [ 380.527823] Modules linked in: vhost_net vhost macvtap macvlan xt_CHECKSUM iptable_mangle ipt_REJECT nf_reject_ipv4 xt_tcpudp ebtable_filter ebtables ip6table_filter ip6_tables ipt_MASQUERADE nf_nat_masquerade_ipv4 xfrm_user xfrm_algo iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 xt_addrtype iptable_filter ip_tables xt_conntrack x_tables nf_nat nf_conntrack br_netfilter overlay binfmt_misc bridge stp llc kvm_hv uio_pdrv_genirq uio leds_powernv ipmi_powernv ibmpowernv vmx_crypto powernv_rng ipmi_msghandler kvm_pr kvm autofs4 xfs btrfs raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid0 multipath linear raid1 raid10 ses enclosure mlx4_en be2net lpfc vxlan mlx4_core scsi_transport_fc ip6_udp_tunnel udp_tunnel ipr [ 380.528781] CPU: 24 PID: 4277 Comm: qemu-system-ppc Tainted: G D 4.4.0-93-generic #116-Ubuntu [ 380.528861] task: c3c389b0 ti: c01fb2428000 task.ti: c01fb2428000 [ 380.528929] NIP: d0003aad7f10 LR: d00037d52a14 CTR: d0003aad7e40 [ 380.528997] REGS: c01fb242b7b0 TRAP: 0f60 Tainted: G D (4.4.0-93-generic) [ 380.529076] MSR: 90009033 CR: 22024848 XER: [ 380.529247] CFAR: d0003aad7ea4 SOFTE: 1 -GPR00: d00037d52a14 c01fb242ba30 d0003aaec018 c01fdbf6 -GPR04: c01f8580 c01fb242bbc0 -GPR08: 0001 c3c389b0 0001 d00037d578f8 -GPR12: d0003aad7e40 cfb4e400 001f -GPR16: 3fff7206 0080 3fff892c4390 3fff7285f200 -GPR20: 010009988430 0100099affd0 3fff7285eb60 100c1ff0 -GPR24: 3bcf4e10 3fff72040028 c01fdbf6 -GPR28: c01f8580 c01fdbf6 c01f8580 + GPR00: d00037d52a14 c01fb242ba30 d0003aaec018 c01fdbf6 + GPR04: c01f8580 c01fb242bbc0 + GPR08: 0001 c3c389b0 0001 d00037d578f8 + GPR12: d0003aad7e40 cfb4e400 001f + GPR16: 3fff7206 0080 3fff892c4390 3fff7285f200 + GPR20: 010009988430 0100099affd0 3fff7285eb60 100c1ff0 + GPR24: 3bcf4e10 3fff72040028 c01fdbf6 + GPR28: c01f8580 c01fdbf6 c01f8580 [ 380.530119] NIP [d0003aad7f10] kvmppc_vcpu_run_hv+0xd0/0xff0 [kvm_hv] [ 380.530188] LR [d00037d52a14] kvmppc_vcpu_run+0x44/0x60 [kvm] [ 380.530245] Call Trace: [ 380.530270] [c01fb242ba30] [c01fb242bab0] 0xc01fb242bab0 (unreliable) [ 380.530353] [c01fb242bb70] [d00037d52a14] kvmppc_vcpu_run+0x44/0x60 [kvm] [ 380.530436] [c01fb242bba0] [d00037d4f674] kvm_arch_vcpu_ioctl_run+0x64/0x170 [kvm] [ 380.530519] [c01fb242bbe0] [d00037d43918] kvm_vcpu_ioctl+0x528/0x7b0 [kvm] [ 380.530602] [c01fb242bd40] [c02fff60] do_vfs_ioctl+0x480/0x7d0 [ 380.530671] [c01fb242bde0] [c0300384] SyS_ioctl+0xd4/0xf0 [ 380.530742] [c01fb242be30] [c0009204] system_call+0x38/0xb4 [ 380.530837] Instruction dump: [ 380.530904] e92d02a0 e9290a50 e9290108 792a07e3 41820058 e92d02a0 e9290a50 e9290108 [ 380.531126] 7927e8a4 78e71f87 40820ed8 e92d02a0 <7d4022a6> f9490ee8 e92d02a0 7d4122a6 [ 380.531350] ---[ end trace 8f9b3b82f9a07d76 ]--- - - Needs kernel patch e47057151422a67ce0874
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
danielgb@p87:~$ apt-get source linux-image-4.4.0-93-generic danielgb@p87:~$ cd linux-4.4.0/ danielgb@p87:~/linux-4.4.0$ patch -p1 < ../index.html\?id\=e47057151422a67ce08747176fa21cb3b526a2c9 checking file arch/powerpc/kvm/book3s_hv.c Hunk #1 succeeded at 2708 (offset -503 lines). danielgb@p87:~/linux-4.4.0$ fakeroot debian/rules clean danielgb@p87:~/linux-4.4.0$ AUTOBUILD=1 fakeroot debian/rules binary-debs .. danielgb@p87:~/linux-4.4.0$ ls ../*deb ../linux-headers-4.4.0-93-generic_4.4.0-93.116_ppc64el.deb ../linux-image-extra-4.4.0-93-generic_4.4.0-93.116_ppc64el.deb ../linux-tools-4.4.0-93-generic_4.4.0-93.116_ppc64el.deb ../linux-image-4.4.0-93-generic_4.4.0-93.116_ppc64el.deb ../linux-tools-4.4.0-93_4.4.0-93.116_ppc64el.deb danielgb@p87:~/linux-4.4.0$ sudo dpkg -i ../*deb danielgb@p87:~/linux-4.4.0$ sudo reboot [0.00] Linux version 4.4.0-93-generic (root@p87) (gcc version 5.4.0 20160609 (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.4) ) #116 SMP Mon Sep 4 10:00:39 AEST 2017 (Ubuntu 4.4.0-93.116-generic 4.4.79) root@p87:~# dmesg | grep -i kvm [ 259.411176] KVM guest htab at c0795900 (order 30), LPID 1 [ 288.766819] KVM guest htab at c0799900 (order 29), LPID 2 root@p87:~# dmesg | grep -i oops root@p87:~# -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
** Changed in: linux (Ubuntu) Assignee: (unassigned) => Daniel Axtens (daxtens) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
Introduced 4.4.0-88.111 "KVM: PPC: Book3S HV: Preserve userspace HTM state properly" according to changelog. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1714420] Re: kernel oops - kvm guest started at boot time
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e47057151422a67ce08747176fa21cb3b526a2c9 is the missing commit. This is a fix to commit 46a704f8409f ( https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=46a704f8409f), which I have validated exists in linux_4.4.0-93.116.diff.gz -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1714420 Title: kernel oops - kvm guest started at boot time To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1714420/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs