qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Vitaly Kuznetsov <vkuznets@redhat.com>,
	qemu-devel@nongnu.org, Eduardo Habkost <ehabkost@redhat.com>
Cc: Igor Mammedov <imammedo@redhat.com>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	Peter Maydell <peter.maydell@linaro.org>
Subject: Re: [PATCH 2/2] i386: Fix coding style in kvm_hyperv_expand_features()
Date: Thu, 29 Jul 2021 09:50:59 +0200	[thread overview]
Message-ID: <f97532bb-9df3-f27f-6fbb-7f0b4679526b@redhat.com> (raw)
In-Reply-To: <20210716115852.418293-2-vkuznets@redhat.com>

On 16/07/21 13:58, Vitaly Kuznetsov wrote:
> QEMU coding style requires braces around bodies of ifs.
> 
> Reported-by: Peter Maydell <peter.maydell@linaro.org>
> Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
> ---
>   target/i386/kvm/kvm.c | 6 ++++--
>   1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
> index e69abe48e3f8..28ca682b1089 100644
> --- a/target/i386/kvm/kvm.c
> +++ b/target/i386/kvm/kvm.c
> @@ -1219,8 +1219,9 @@ bool kvm_hyperv_expand_features(X86CPU *cpu, Error **errp)
>       Error *local_err = NULL;
>       int feat;
>   
> -    if (!hyperv_enabled(cpu))
> +    if (!hyperv_enabled(cpu)) {
>           return true;
> +    }
>   
>       /*
>        * When kvm_hyperv_expand_features is called at CPU feature expansion
> @@ -1228,8 +1229,9 @@ bool kvm_hyperv_expand_features(X86CPU *cpu, Error **errp)
>        * when KVM_CAP_SYS_HYPERV_CPUID is supported.
>        */
>       if (!cs->kvm_state &&
> -        !kvm_check_extension(kvm_state, KVM_CAP_SYS_HYPERV_CPUID))
> +        !kvm_check_extension(kvm_state, KVM_CAP_SYS_HYPERV_CPUID)) {
>           return true;
> +    }
>   
>       if (cpu->hyperv_passthrough) {
>           cpu->hyperv_vendor_id[0] =
> 

Queued both, thanks.

Paolo



      reply	other threads:[~2021-07-29  7:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-16 11:58 [PATCH 1/2] i386: assert 'cs->kvm_state' is not null Vitaly Kuznetsov
2021-07-16 11:58 ` [PATCH 2/2] i386: Fix coding style in kvm_hyperv_expand_features() Vitaly Kuznetsov
2021-07-29  7:50   ` Paolo Bonzini [this message]

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=f97532bb-9df3-f27f-6fbb-7f0b4679526b@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=ehabkost@redhat.com \
    --cc=imammedo@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=vkuznets@redhat.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;
as well as URLs for NNTP newsgroup(s).