From: "Jan Beulich" Subject: Re: [for-xen-4.5 v9 2/2] dpci: Replace tasklet with an softirq (v12) Date: Tue, 04 Nov 2014 10:37:29 +0000 Message-ID: <5458BA790200007800044B58@mail.emea.novell.com> References: <1415042078-8337-1-git-send-email-konrad.wilk@oracle.com> <1415042078-8337-3-git-send-email-konrad.wilk@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XlbUV-0004dV-32 for xen-devel@lists.xenproject.org; Tue, 04 Nov 2014 10:37:35 +0000 In-Reply-To: <1415042078-8337-3-git-send-email-konrad.wilk@oracle.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Konrad Rzeszutek Wilk Cc: keir@xen.org, ian.campbell@citrix.com, andrew.cooper3@citrix.com, tim@xen.org, xen-devel@lists.xenproject.org, ian.jackson@eu.citrix.com List-Id: xen-devel@lists.xenproject.org >>> On 03.11.14 at 20:14, wrote: > +/* > + * Should only be called from hvm_do_IRQ_dpci. We use the This statement together with the comment in pt_pirq_softirq_active() is at least confusing: If the function is to be called in only one place, there shouldn't be a second place where its use is being suggested. Plus, a function with such required limited use would very likely better not be a separate function at all. > @@ -159,7 +279,16 @@ int pt_irq_create_bind( > { > rc = msixtbl_pt_register(d, info, pt_irq_bind->u.msi.gtable); > if ( unlikely(rc) ) > + { > pirq_guest_unbind(d, info); > + /* > + * Between 'pirq_guest_bind' and before 'pirq_guest_unbind' > + * an interrupt can be scheduled. No more of them are going > + * to be scheduled but we must deal with the one that is in s/ is / may be /? > @@ -269,6 +398,10 @@ int pt_irq_create_bind( > { > if ( pt_irq_need_timer(pirq_dpci->flags) ) > kill_timer(&pirq_dpci->timer); > + /* > + * There is no path for __do_IRQ to schedule softirq as > + * IRQ_GUEST is not set. As such we can reset 'dom' right away. "right away" suggests the alternative handling defers it in any way. Maybe better "directly"? Jan