From: Claudio Imbrenda <imbrenda@linux.ibm.com>
To: linux-kernel@vger.kernel.org
Cc: linux-s390@vger.kernel.org, kvm@vger.kernel.org,
david@redhat.com, frankja@linux.ibm.com, seiden@linux.ibm.com,
nsg@linux.ibm.com, nrb@linux.ibm.com, schlameuss@linux.ibm.com,
hca@linux.ibm.com, mhartmay@linux.ibm.com,
borntraeger@de.ibm.com
Subject: [PATCH v3 0/2] KVM: s390: Fix two bugs
Date: Mon, 25 Aug 2025 17:18:29 +0200 [thread overview]
Message-ID: <20250825151831.78221-1-imbrenda@linux.ibm.com> (raw)
This small series fixes two bugs in s390 KVM. One is small and trivial,
the other is pretty bad.
* The wrong type of flag was being passed to vcpu_dat_fault_handler();
it expects a FOLL_* flag, but a FAULT_FLAG_* was passed instead.
* Due to incorrect usage of mmu_notifier_register(), in some rare cases
when running a secure guest, the struct mm for the userspace process
would get freed too early and cause a use-after-free.
v2->v3
* Make sure .ops is not NULL before calling mmu_notifier_register() to
avoid NULL pointer errors (thanks Marc)
v1->v2
* Rename the parameters of __kvm_s390_handle_dat_fault() and
vcpu_dat_fault_handler() from flags to foll (thanks Christian)
Claudio Imbrenda (2):
KVM: s390: Fix incorrect usage of mmu_notifier_register()
KVM: s390: Fix FOLL_*/FAULT_FLAG_* confusion
arch/s390/kvm/kvm-s390.c | 24 ++++++++++++------------
arch/s390/kvm/pv.c | 16 +++++++++++-----
2 files changed, 23 insertions(+), 17 deletions(-)
--
2.51.0
next reply other threads:[~2025-08-25 15:18 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-25 15:18 Claudio Imbrenda [this message]
2025-08-25 15:18 ` [PATCH v3 1/2] KVM: s390: Fix incorrect usage of mmu_notifier_register() Claudio Imbrenda
2025-08-25 15:18 ` [PATCH v3 2/2] KVM: s390: Fix FOLL_*/FAULT_FLAG_* confusion Claudio Imbrenda
2025-09-02 9:22 ` Christoph Schlameuss
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=20250825151831.78221-1-imbrenda@linux.ibm.com \
--to=imbrenda@linux.ibm.com \
--cc=borntraeger@de.ibm.com \
--cc=david@redhat.com \
--cc=frankja@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=mhartmay@linux.ibm.com \
--cc=nrb@linux.ibm.com \
--cc=nsg@linux.ibm.com \
--cc=schlameuss@linux.ibm.com \
--cc=seiden@linux.ibm.com \
/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®