xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: David Vrabel <david.vrabel@citrix.com>
To: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: xen-devel@lists.xensource.com, Lisa Nguyen <lisa@xenapiadmin.com>,
	Ian.Campbell@citrix.com,
	Zhenzhong Duan <zhenzhong.duan@oracle.com>,
	Konrad Rzeszutek Wilk <konrad@kernel.org>,
	Ben Guthro <benjamin.guthro@citrix.com>,
	boris.ostrovsky@oracle.com
Subject: Re: [PATCH] xen: Support 64-bit PV guest receiving NMIs
Date: Mon, 22 Jul 2013 16:26:47 +0100	[thread overview]
Message-ID: <51ED4F37.7050904@citrix.com> (raw)
In-Reply-To: <20130722144829.GB30300@phenom.dumpdata.com>

On 22/07/13 15:48, Konrad Rzeszutek Wilk wrote:
> On Mon, Jul 22, 2013 at 01:15:17PM +0100, David Vrabel wrote:
>> On 19/07/13 16:51, Konrad Rzeszutek Wilk wrote:
[...]

> What version of them would that be ? Anything prior to 3.4 cannot
> boot with the Linux pvops.

Ok. 3.4 has all the required functionality.

>>> --- a/drivers/xen/events.c
>>> +++ b/drivers/xen/events.c
>>> @@ -1213,6 +1214,16 @@ EXPORT_SYMBOL_GPL(evtchn_put);
>>>  void xen_send_IPI_one(unsigned int cpu, enum ipi_vector vector)
>>>  {
>>>  	int irq = per_cpu(ipi_to_irq, cpu)[vector];
>>> +
>>> +	/*
>>> +	 * In which the IRQ will be -1.
>>> +	 */
>>> +	if (unlikely(vector == XEN_NMI_VECTOR)) {
>>> +		int rc =  HYPERVISOR_vcpu_op(VCPUOP_send_nmi, cpu, NULL);
>>> +		if (rc < 0)
>>> +			printk(KERN_WARNING "Sending nmi to CPU%d failed (rc:%d)\n", cpu, rc);
>>> +		return;
>>> +	}
>>
>> Move the assignment of irq after this block, then you can drop the
>> (unhelpful) comment.
> 
> I guess? I was thinking it would be helpfull to know if it does not work.

I meant the comment not the printk.  e.g.,

{
  	int irq;

	if (unlikely(vector == XEN_NMI_VECTOR)) {
		int rc =  HYPERVISOR_vcpu_op(VCPUOP_send_nmi, cpu, NULL);
		if (rc < 0)
			printk(KERN_WARNING "Sending nmi to CPU%d failed (rc:%d)\n", cpu, rc);
		return;
	}

	irq = per_cpu(ipi_to_irq, cpu)[vector];
	...

David

  reply	other threads:[~2013-07-22 15:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-19 15:51 [PATCH] xen: Support 64-bit PV guest receiving NMIs Konrad Rzeszutek Wilk
2013-07-19 16:19 ` Ben Guthro
2013-07-22 12:15 ` David Vrabel
2013-07-22 14:48   ` Konrad Rzeszutek Wilk
2013-07-22 15:26     ` David Vrabel [this message]
2013-07-31 17:32       ` Konrad Rzeszutek Wilk
2013-08-01 12:11         ` David Vrabel

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=51ED4F37.7050904@citrix.com \
    --to=david.vrabel@citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=benjamin.guthro@citrix.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=konrad.wilk@oracle.com \
    --cc=konrad@kernel.org \
    --cc=lisa@xenapiadmin.com \
    --cc=xen-devel@lists.xensource.com \
    --cc=zhenzhong.duan@oracle.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).