From: Keir Fraser Subject: Re: [PATCH] x86: don't allow Dom0 to map MSI-X table writably Date: Tue, 14 Feb 2012 18:32:31 +0000 Message-ID: References: <4F3A83D20200007800072ED4@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4F3A83D20200007800072ED4@nat28.tlf.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jan Beulich , "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On 14/02/2012 14:54, "Jan Beulich" wrote: > With the traditional qemu tree fixed to not use PROT_WRITE anymore in > the mmap() call for this region, and with the upstream qemu tree not > being capable of handling passthrough, yet, there's no need to treat > Dom specially here anymore. > > This continues to leave unaddressed the case where PV guests map the > MSI-X table page(s) before setting up the first MSI-X interrupt (see > the original c/s 22182:68cc3c514a0a description for options). > > Signed-off-by: Jan Beulich Acked-by: Keir Fraser > --- a/xen/arch/x86/mm.c > +++ b/xen/arch/x86/mm.c > @@ -869,7 +869,7 @@ get_page_from_l1e( > return -EINVAL; > } > > - if ( !(l1f & _PAGE_RW) || IS_PRIV(pg_owner) || > + if ( !(l1f & _PAGE_RW) || > !rangeset_contains_singleton(mmio_ro_ranges, mfn) ) > return 0; > dprintk(XENLOG_G_WARNING, > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel