mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
To: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	Stefano Stabellini <Stefano.Stabellini@eu.citrix.com>
Subject: Re: [PATCH 3/4] xen/smp/pvhvm: Don't point per_cpu(xen_vpcu, 33 and larger) to shared_info
Date: Mon, 6 May 2013 16:00:22 +0100	[thread overview]
Message-ID: <alpine.DEB.2.02.1305061600140.4756@kaball.uk.xensource.com> (raw)
In-Reply-To: <1367845498-14290-4-git-send-email-konrad.wilk@oracle.com>

On Mon, 6 May 2013, Konrad Rzeszutek Wilk wrote:
> As it will point to some data, but not event channel data (the
> shared_info has an array limited to 32).
> 
> This means that for PVHVM guests with more than 32 VCPUs without
> the usage of VCPUOP_register_info any interrupts to VCPUs
> larger than 32 would have gone unnoticed during early bootup.
> 
> That is OK, as during early bootup, in smp_init we end up calling
> the hotplug mechanism (xen_hvm_cpu_notify) which makes the
> VCPUOP_register_vcpu_info call for all VCPUs and we can receive
> interrupts on VCPUs 33 and further.
> 
> This is just a cleanup.
> 
> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>

Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>


>  arch/x86/xen/enlighten.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
> index 9b34475..18a4009 100644
> --- a/arch/x86/xen/enlighten.c
> +++ b/arch/x86/xen/enlighten.c
> @@ -1638,6 +1638,9 @@ void __ref xen_hvm_init_shared_info(void)
>  	 * online but xen_hvm_init_shared_info is run at resume time too and
>  	 * in that case multiple vcpus might be online. */
>  	for_each_online_cpu(cpu) {
> +		/* Leave it to be NULL. */
> +		if (cpu >= MAX_VIRT_CPUS)
> +			continue;
>  		per_cpu(xen_vcpu, cpu) = &HYPERVISOR_shared_info->vcpu_info[cpu];
>  	}
>  }
> -- 
> 1.8.1.4
> 

  reply	other threads:[~2013-05-06 15:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-06 13:04 [PATCH] Patches to make PVHVM VCPU hotplug work with VCPUOP_register_info (v1) Konrad Rzeszutek Wilk
2013-05-06 13:04 ` [PATCH 1/4] xen/vcpu/pvhvm: Fix vcpu hotplugging hanging Konrad Rzeszutek Wilk
2013-05-06 15:08   ` Stefano Stabellini
2013-05-06 13:04 ` [PATCH 2/4] xen/vcpu: Document the xen_vcpu_info and xen_vcpu Konrad Rzeszutek Wilk
2013-05-06 14:58   ` Stefano Stabellini
2013-05-07  9:30   ` [Xen-devel] " Ian Campbell
2013-05-07 14:06     ` Konrad Rzeszutek Wilk
2013-05-06 13:04 ` [PATCH 3/4] xen/smp/pvhvm: Don't point per_cpu(xen_vpcu, 33 and larger) to shared_info Konrad Rzeszutek Wilk
2013-05-06 15:00   ` Stefano Stabellini [this message]
2013-05-06 13:04 ` [PATCH 4/4] xen/spinlock: Fix check from greater than to be also be greater or equal to Konrad Rzeszutek Wilk
2013-05-06 14:57   ` Stefano Stabellini

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=alpine.DEB.2.02.1305061600140.4756@kaball.uk.xensource.com \
    --to=stefano.stabellini@eu.citrix.com \
    --cc=konrad.wilk@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=xen-devel@lists.xensource.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

all inboxes | Powered by JetHome®