From: Tom Rotenberg Subject: Re: Question about the dynamic sizing of the PCI hole Date: Mon, 25 May 2009 12:48:15 +0300 Message-ID: <8686c3cd0905250248u1a52561aud00d8dcd5d667f78@mail.gmail.com> References: <8686c3cd0905250224k320537b3s3b9cbcc0fd3ce51@mail.gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1947462868==" 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: Keir Fraser Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org --===============1947462868== Content-Type: multipart/alternative; boundary=0016e64713ee59771f046ab982c0 --0016e64713ee59771f046ab982c0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Well, can u give me any pointer to which code updates it? (my English is better than my ASL :) 2009/5/25 Keir Fraser > That field is updated dynamically. Can't you fluently read ASL? ;-) > > -- Keir > > On 25/05/2009 10:24, "Tom Rotenberg" wrote: > > > And, won't we have any problem if we dynamically size the PCI hole, and > not > > update it in the DSDT we give for the HVM (in the DSDT it's always > > 0xf0000...)? > > > > 2009/5/25 Keir Fraser > >> On 25/05/2009 10:01, "Tom Rotenberg" wrote: > >> > >>> I am reviewing the code of the hvmloader from Xen 3.4, and i saw that > in > >>> changeset 19021, there was a patch which added the ability to > dynamically > >>> size > >>> the PCI hole. I have seen that this patch calculates the total memory > size, > >>> but i failed to understand the following lines: > >>> > >>> while ( (mmio_total > (pci_mem_end - pci_mem_start)) && > >>> ((pci_mem_start << 1) != 0) ) > >>> pci_mem_start <<= 1; > >>> > >>> It looks as if the pci mem start will be increased if there isn't > enough > >>> space > >>> for the PCI devices, although, as far as i understand, it should be > >>> decreased > >>> (so the PCI hole will be enlarged). So, shouldn't it be: "pci_mem_start > >> = > >>> 1" ? > >> > >> Leading bits of this 32-bit value are 1s. Hence left shift is what we > want. > >> > >> -- Keir > >> > >> > > > > > --0016e64713ee59771f046ab982c0 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Well, can u give me any pointer to which code updates it? = (my English is better than my ASL :)

2009= /5/25 Keir Fraser <keir.fraser@eu.citrix.com>
That field is upd= ated dynamically. Can't you fluently read ASL? ;-)

=A0-- Keir

On 25/05/2009 10:24, "Tom Rotenberg" <tom.rotenberg@gmail.com> wrote:

> And, won't we have any problem if we dynamically size the PCI hole= , and not
> update it in the DSDT we give for the HVM (in the DSDT it's always=
> 0xf0000...)?
>
> 2009/5/25 Keir Fraser <keir.fraser@eu.citrix.com>
>> On 25/05/2009 10:01, "Tom Rotenberg" <tom.rotenberg@gmail.com> wrote:
>>
>>> I am reviewing the code of the hvmloader from Xen 3.4, and i s= aw that in
>>> changeset 19021, there was a patch which added the ability to = dynamically
>>> size
>>> the PCI hole. I have seen that this patch calculates the total= memory size,
>>> but i failed to understand the following lines:
>>>
>>> while ( (mmio_total > (pci_mem_end - pci_mem_start)) &&= amp;
>>> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 ((pci_mem_start << 1) = !=3D 0) )
>>> =A0=A0=A0=A0=A0=A0=A0 pci_mem_start <<=3D 1;
>>>
>>> It looks as if the pci mem start will be increased if there is= n't enough
>>> space
>>> for the PCI devices, although, as far as i understand, it shou= ld be
>>> decreased
>>> (so the PCI hole will be enlarged). So, shouldn't it be: &= quot;pci_mem_start >> =3D
>>> 1" ?
>>
>> Leading bits of this 32-bit value are 1s. Hence left shift is what= we want.
>>
>> =A0-- Keir
>>
>>
>


--0016e64713ee59771f046ab982c0-- --===============1947462868== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --===============1947462868==--