From: Vaibhav Jain <vaibhav@linux.ibm.com>
To: Amit Machhiwal <amachhiw@linux.ibm.com>,
linuxppc-dev@lists.ozlabs.org, kvm@vger.kernel.org,
kvm-ppc@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, Nicholas Piggin <npiggin@gmail.com>,
Vaidyanathan Srinivasan <svaidy@linux.ibm.com>,
"Aneesh Kumar K . V" <aneesh.kumar@kernel.org>,
Amit Machhiwal <amachhiw@linux.ibm.com>,
Jordan Niethe <jniethe5@gmail.com>,
"Naveen N . Rao" <naveen.n.rao@linux.ibm.com>
Subject: Re: [PATCH v2] KVM: PPC: Book3S HV: Fix L2 guest reboot failure due to empty 'arch_compat'
Date: Mon, 05 Feb 2024 23:05:23 +0530 [thread overview]
Message-ID: <87h6img6g4.fsf@vajain21.in.ibm.com> (raw)
In-Reply-To: <20240205132607.2776637-1-amachhiw@linux.ibm.com>
Hi Amit,
Thanks for the patch. Minor comment on the patch below:
Amit Machhiwal <amachhiw@linux.ibm.com> writes:
<snip>
>
> +static inline unsigned long map_pcr_to_cap(unsigned long pcr)
> +{
> + unsigned long cap = 0;
> +
> + switch (pcr) {
> + case PCR_ARCH_300:
> + cap = H_GUEST_CAP_POWER9;
> + break;
> + case PCR_ARCH_31:
> + cap = H_GUEST_CAP_POWER10;
Though CONFIG_CC_IMPLICIT_FALLTHROUGH and '-Wimplicit-fallthrough'
doesnt explicitly flag this usage, please consider using the
'fallthrough;' keyword here.
However you probably dont want this switch-case to fallthrough so please
use a 'break' instead.
> + default:
> + break;
> + }
> +
> + return cap;
> +}
> +
>
<snip>
With the suggested change above
Reviewed-by: Vaibhav Jain <vaibhav@linux.ibm.com>
--
Cheers
~ Vaibhav
next prev parent reply other threads:[~2024-02-05 17:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-05 13:26 [PATCH v2] KVM: PPC: Book3S HV: Fix L2 guest reboot failure due to empty 'arch_compat' Amit Machhiwal
2024-02-05 13:39 ` Aneesh Kumar K.V
2024-02-05 17:35 ` Vaibhav Jain [this message]
2024-02-05 18:09 ` Amit Machhiwal
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=87h6img6g4.fsf@vajain21.in.ibm.com \
--to=vaibhav@linux.ibm.com \
--cc=amachhiw@linux.ibm.com \
--cc=aneesh.kumar@kernel.org \
--cc=jniethe5@gmail.com \
--cc=kvm-ppc@vger.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=naveen.n.rao@linux.ibm.com \
--cc=npiggin@gmail.com \
--cc=svaidy@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