qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Paolo Bonzini <pbonzini@redhat.com>, qemu-devel@nongnu.org
Cc: "Denis V. Lunev" <den@openvz.org>
Subject: Re: [Qemu-devel] [PULL 2/9] apic_common: improve readability of apic_reset_common
Date: Fri, 08 May 2015 14:52:43 +0200	[thread overview]
Message-ID: <554CB19B.50302@suse.de> (raw)
In-Reply-To: <1431089344-20350-3-git-send-email-pbonzini@redhat.com>

Am 08.05.2015 um 14:48 schrieb Paolo Bonzini:
> From: "Denis V. Lunev" <den@openvz.org>
> 
> Replace call of cpu_is_bsp(s->cpu) which really returns
>     !!(s->apicbase & MSR_IA32_APICBASE_BSP)
> with directly collected value. Due to this the tracepoint
>   trace_cpu_get_apic_base((uint64_t)s->apicbase);
> will not be hit anymore in apic_reset_common.
> 
> Signed-off-by: Denis V. Lunev <den@openvz.org>
> CC: Andreas Färber <afaerber@suse.de>

Unchanged...

> CC: Paolo Bonzini <pbonzini@redhat.com>
> Message-Id: <1428414832-3104-1-git-send-email-den@openvz.org>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  hw/intc/apic_common.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)
> 
> diff --git a/hw/intc/apic_common.c b/hw/intc/apic_common.c
> index d38d24b..d595d63 100644
> --- a/hw/intc/apic_common.c
> +++ b/hw/intc/apic_common.c
> @@ -233,11 +233,10 @@ static void apic_reset_common(DeviceState *dev)
>  {
>      APICCommonState *s = APIC_COMMON(dev);
>      APICCommonClass *info = APIC_COMMON_GET_CLASS(s);
> -    bool bsp;
> +    uint32_t bsp;
>  
> -    bsp = cpu_is_bsp(s->cpu);
> -    s->apicbase = APIC_DEFAULT_ADDRESS |
> -        (bsp ? MSR_IA32_APICBASE_BSP : 0) | MSR_IA32_APICBASE_ENABLE;
> +    bsp = s->apicbase & MSR_IA32_APICBASE_BSP;
> +    s->apicbase = APIC_DEFAULT_ADDRESS | bsp | MSR_IA32_APICBASE_ENABLE;
>  
>      s->vapic_paddr = 0;
>      info->vapic_base_update(s);
> 


-- 
SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Felix Imendörffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu,
Graham Norton; HRB 21284 (AG Nürnberg)

  reply	other threads:[~2015-05-08 12:52 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-08 12:48 [Qemu-devel] [PULL v2 0/9] KVM, QOM, NBD, build fixes for 2015-05-08 Paolo Bonzini
2015-05-08 12:48 ` [Qemu-devel] [PULL 1/9] kvm: Silence warning from valgrind Paolo Bonzini
2015-05-09  6:51   ` Thomas Huth
2015-05-10 14:05     ` Paolo Bonzini
2015-05-08 12:48 ` [Qemu-devel] [PULL 2/9] apic_common: improve readability of apic_reset_common Paolo Bonzini
2015-05-08 12:52   ` Andreas Färber [this message]
2015-05-08 12:48 ` [Qemu-devel] [PULL 3/9] mtree: tag & indent a bit better Paolo Bonzini
2015-05-08 12:48 ` [Qemu-devel] [PULL 4/9] mtree: also print disabled regions Paolo Bonzini
2015-05-08 12:49 ` [Qemu-devel] [PULL 5/9] kvm: add support for memory transaction attributes Paolo Bonzini
2015-05-08 12:49 ` [Qemu-devel] [PULL 6/9] exec: move rcu_read_lock/unlock to address_space_translate callers Paolo Bonzini
2015-05-08 12:49 ` [Qemu-devel] [PULL 7/9] configure: require __thread support Paolo Bonzini
2015-05-08 12:49 ` [Qemu-devel] [PULL 9/9] qemu-nbd: only send a limited number of errno codes on the wire Paolo Bonzini
2015-05-11 12:40 ` [Qemu-devel] [PULL v2 0/9] KVM, QOM, NBD, build fixes for 2015-05-08 Peter Maydell

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=554CB19B.50302@suse.de \
    --to=afaerber@suse.de \
    --cc=den@openvz.org \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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).