From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keir Fraser Subject: Re: Re: IRQs, move_in_progress, -EBUSY &c Date: Wed, 11 Aug 2010 20:12:57 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: George Dunlap Cc: Fitzhardinge , "xen-devel@lists.xensource.com" , "Zhang, Xiantao" , Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org On 11/08/2010 20:06, "George Dunlap" wrote: > Looks like there are other callers of __assign_irq_vector() which also > don't handle the -EBUSY return value, namely > xen/arch/x86/io_apic.c:set_desc_affinity(). Looks like its callers do the same as on native Linux though -- namely silently bail on error. I think the set_affinity type callers are pretty benign if they fail-as-noop. In all of this, where possible I think we just have to stay close to what Linux does. -- Keir > Unfortunately, set_desc_affinity() cannot simply loop until it stops > getting -EBUSY, as it is almost always called with irqs disabled -- so > the very IPI which will call the function to make it not busy anymore > is blocked. And it only returns one value (a cpu mask), and the > function which calls it returns no value at all; so we can's pass the > "loop and retry" up one more level; we'd have to do a ton more code > rewriting to be able to handle retries. > > Can we just call the cleanup function directly if we get -EBUSY?