From: Marc Zyngier <maz@kernel.org>
To: David Brazdil <dbrazdil@google.com>
Cc: linux-arm-kernel@lists.infradead.org, kvm@vger.kernel.org,
kvmarm@lists.cs.columbia.edu, ascull@google.com,
James Morse <james.morse@arm.com>,
Suzuki K Poulose <suzuki.poulose@arm.com>,
Alexandru Elisei <alexandru.elisei@arm.com>,
kernel-team@android.com
Subject: Re: [PATCH] KVM: arm64: Allow KVM to be disabled from the command line
Date: Thu, 30 Sep 2021 11:22:58 +0100 [thread overview]
Message-ID: <87bl4atla5.wl-maz@kernel.org> (raw)
In-Reply-To: <YVMtgBw+qG713+4k@google.com>
Hi David,
On Tue, 28 Sep 2021 15:58:08 +0100,
David Brazdil <dbrazdil@google.com> wrote:
>
> Hey Marc,
> that all makes sense:
>
> Reviewed-by: David Brazdil <dbrazdil@google.com>
>
> > @@ -2137,8 +2142,15 @@ static int __init early_kvm_mode_cfg(char *arg)
> > return 0;
> > }
> >
> > - if (strcmp(arg, "nvhe") == 0 && !WARN_ON(is_kernel_in_hyp_mode()))
> > + if (strcmp(arg, "nvhe") == 0 && !WARN_ON(is_kernel_in_hyp_mode())) {
> > + kvm_mode = KVM_MODE_DEFAULT;
> > return 0;
> > + }
> > +
> > + if (strcmp(arg, "none") == 0 && !WARN_ON(is_kernel_in_hyp_mode())) {
> nit: I noticed we check is_kernel_in_hyp_mode here for nvhe/none but for
> protected it is checked in is_kvm_protected_mode. May be worth unifying?
is_kvm_protected_mode() drives a capability (as we rely on the
associated static key), and we don't need this with either 'nvhe' nor
'none'.
So I'm unsure what we can unify, to be honest. Can you suggest a
patch?
Thanks,
M.
--
Without deviation from the norm, progress is not possible.
next prev parent reply other threads:[~2021-09-30 10:23 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-03 9:16 [PATCH] KVM: arm64: Allow KVM to be disabled from the command line Marc Zyngier
2021-09-28 14:58 ` David Brazdil
2021-09-30 10:22 ` Marc Zyngier [this message]
2021-09-29 10:28 ` Will Deacon
2021-09-29 10:35 ` Suzuki K Poulose
2021-09-30 10:29 ` Marc Zyngier
2021-10-01 9:27 ` Suzuki K Poulose
2021-10-01 14:54 ` Marc Zyngier
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=87bl4atla5.wl-maz@kernel.org \
--to=maz@kernel.org \
--cc=alexandru.elisei@arm.com \
--cc=ascull@google.com \
--cc=dbrazdil@google.com \
--cc=james.morse@arm.com \
--cc=kernel-team@android.com \
--cc=kvm@vger.kernel.org \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=suzuki.poulose@arm.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