lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87h6img6g4.fsf@vajain21.in.ibm.com>
Date: Mon, 05 Feb 2024 23:05:23 +0530
From: Vaibhav Jain <vaibhav@...ux.ibm.com>
To: Amit Machhiwal <amachhiw@...ux.ibm.com>, linuxppc-dev@...ts.ozlabs.org,
        kvm@...r.kernel.org, kvm-ppc@...r.kernel.org
Cc: Nicholas Piggin <npiggin@...il.com>,
        Michael Ellerman
 <mpe@...erman.id.au>,
        Jordan Niethe <jniethe5@...il.com>,
        Vaidyanathan
 Srinivasan <svaidy@...ux.ibm.com>,
        "Aneesh Kumar K . V"
 <aneesh.kumar@...nel.org>,
        "Naveen N . Rao" <naveen.n.rao@...ux.ibm.com>,
        Christophe Leroy <christophe.leroy@...roup.eu>,
        Amit Machhiwal
 <amachhiw@...ux.ibm.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] KVM: PPC: Book3S HV: Fix L2 guest reboot failure due
 to empty 'arch_compat'

Hi Amit,

Thanks for the patch. Minor comment on the patch below:

Amit Machhiwal <amachhiw@...ux.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@...ux.ibm.com>

-- 
Cheers
~ Vaibhav

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ