From: "Jan Beulich" Subject: Re: [PATCH 1/2] hvmloader: also cover PCI MMIO ranges above 4G with UC MTRR ranges Date: Wed, 21 May 2014 15:05:22 +0100 Message-ID: <537CCEC2020000780001491D@mail.emea.novell.com> References: <537A1D1E0200007800013A2C@mail.emea.novell.com> <537A1F790200007800013A4D@mail.emea.novell.com> <1400675073.4856.46.camel@kazak.uk.xensource.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 1Wn795-0000uY-HO for xen-devel@lists.xenproject.org; Wed, 21 May 2014 14:05:27 +0000 In-Reply-To: <1400675073.4856.46.camel@kazak.uk.xensource.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: Ian Campbell Cc: xen-devel , Ian Jackson , Stefano Stabellini List-Id: xen-devel@lists.xenproject.org >>> On 21.05.14 at 14:24, wrote: > On Mon, 2014-05-19 at 14:12 +0100, Jan Beulich wrote: >> @@ -163,6 +176,17 @@ DefinitionBlock ("DSDT.aml", "DSDT", 2, >> Add(MMIN, MLEN, MMAX) >> Subtract(MMAX, One, MMAX) >> >> + CreateQWordField(PRT0, \_SB.PCI0._CRS._Y02._MIN, HMIN) >> + CreateQWordField(PRT0, \_SB.PCI0._CRS._Y02._MAX, HMAX) >> + CreateQWordField(PRT0, \_SB.PCI0._CRS._Y02._LEN, HLEN) >> + >> + Store(\_SB.HMIN, HMIN) >> + Store(\_SB.HLEN, HLEN) >> + Add(HMIN, HLEN, HMAX) >> + If(LOr(HMIN, HLEN)) { >> + Subtract(HMAX, One, HMAX) >> + } > > This is (unlike the low version) conditional because HLEN might be 0? Yes. > Is the fact that _Y02 might continue to contain all zeroes OK? Yes, it is - for Linux at least things end up being slightly wrong (in that the region then gets treated as disabled rather than absent) when doing the subtraction of 1 unconditionally. Additionally I have a physical system where such an empty range (all zeros) exists, which I take as additional proof that this is okay. Jan