From: "Marcus Comstedt" <marcus@mc.pp.se>
To: kvm-ppc@vger.kernel.org
Subject: KVM regression on 64-bit big endian in 5.4
Date: Mon, 09 Dec 2019 09:52:38 +0000 [thread overview]
Message-ID: <yf9d0cxn7vd.fsf@mc.pp.se> (raw)
Hi.
I discovered after upgrading to kernel 5.4 on my Talos II (Power9
Nimbus DD2.2) that KVM didn't work anymore. The guest would crash
already in SLOF.
After bisecting, I found that the culprit was this commit:
| From 6c85b7bc637b64e681760f62c0eafba2f56745c6 Mon Sep 17 00:00:00 2001
| From: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com>
| Date: Thu, 22 Aug 2019 00:48:38 -0300
| Subject: powerpc/kvm: Use UV_RETURN ucall to return to ultravisor
|
| When an SVM makes an hypercall or incurs some other exception, the
| Ultravisor usually forwards (a.k.a. reflects) the exceptions to the
| Hypervisor. After processing the exception, Hypervisor uses the
| UV_RETURN ultracall to return control back to the SVM.
Looking at the diff, this change caught my eye:
- ld r6, VCPU_CR(r4)
+ lwz r0, VCPU_CR(r4)
So the loading of VPU_CR has changed from ld to lwz. This seems
wrong. ccr is an unsigned long, and the store to VCPU_CR in the same
file uses std, not stw. So loading VCPU_CR must be done with ld,
otherwise the result will be wrong (truncated on LE, truncated and
left shifted by 16 bits on BE)...
// Marcus
reply other threads:[~2019-12-09 9:52 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=yf9d0cxn7vd.fsf@mc.pp.se \
--to=marcus@mc.pp.se \
--cc=kvm-ppc@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.