Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 17 Oct 2014 15:24:39 +0000
From:      Ashutosh Kumar <mrashutosh@hotmail.com>
To:        "freebsd-virtualization@freebsd.org" <freebsd-virtualization@freebsd.org>
Subject:   RE: io-apic interrupt migration on bhyve
Message-ID:  <SNT150-W7159835C18B15B9E9A6B86DFA80@phx.gbl>
In-Reply-To: <SNT150-W7ABD0AAB97FA85DFF5464DFA80@phx.gbl>
References:  <SNT150-W7ABD0AAB97FA85DFF5464DFA80@phx.gbl>

next in thread | previous in thread | raw e-mail | index | archive | help

Hi,
On more analysis I found that there is a race condition in Guest OS such that before complete initialization happens for APs the interrupt migration takes place and hence incorrect cpu is written to io-apic's rte for that particular pin. The debug prints either in Guest OS or vmm just kills this race condition.
Thanks.  

RegardsAshutosh

> From: mrashutosh@hotmail.com
> To: freebsd-virtualization@freebsd.org
> Subject: io-apic interrupt migration on bhyve
> Date: Fri, 17 Oct 2014 13:24:34 +0000
> 
>  
> 
> Hi,
> 
>  
> 
> I am witnessing some strange behavior w.r.t io-apic
> interrupt migration on bhyve.
> 
> I have below assignment for a level triggered
> interrupt:
> 
>  
> 
> io-apic pin - p
> 
> cpu vector - v
> 
> cpu id - 0
> 
>  
> 
> when this interrupt is migrated to cpu 1 then
> the assignment is as below
> 
>  
> 
> io-apic pin - p
> 
> cpu vector - v1
> 
> cpu id - 1
> 
>  
> 
> When VM boots up then OS is getting interrupts for 
> 
>  
> 
> io-apic pin - p
> 
> cpu vector - v1
> 
> cpu id - 0
> 
>  
> 
> Added debug prints in vioapic_write function
> to check the values written to io-apic rte for this pin and then VM gets
> correct interrupts i.e (vector v, cpu 0 ) before the interrupts are migrated and
> (vector v1, cpu 1) after the migration When prints are removed then the
> problem happens and we see interrupts for (vector v1 and cpu 0).
> RegardsAshutosh 		 	   		  
> _______________________________________________
> freebsd-virtualization@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization
> To unsubscribe, send any mail to "freebsd-virtualization-unsubscribe@freebsd.org"
 		 	   		  


Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?SNT150-W7159835C18B15B9E9A6B86DFA80>