Re: dynamic BAR

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jun 24, 2011 at 1:52 PM, Matthew Wilcox <matthew@xxxxxx> wrote:
> On Fri, Jun 24, 2011 at 09:15:24AM -0700, Jesse Barnes wrote:
>> On Thu, 23 Jun 2011 23:16:57 -0500
>> Xianghua Xiao <xiaoxianghua@xxxxxxxxx> wrote:
>>
>> > We're using a ARM that only has 256MB PCI space, however I have a PCI
>> > device that has a BAR(for its own memory) that is 512MB, for ARM to
>> > allocate it I modified the BAR size on the device to 128MB(there are
>> > other PCI devices to use portion of the rest 128MB)
>> >
>> > I can modify the BAR at run time, is it ok for me to change the BAR
>> > address to address all the 512MB on PCI device? The PCI memory address
>> > ARM allocates at boot time can stay the same, but the BAR will be
>> > changed to re-map to all the 512MB space on the PCI device(each time
>> > for 128M), is this do-able?
>>
>> Sounds pretty hackish, but as long as you can deal with the decode
>> priorities for the address space on your platform (e.g. make sure your
>> 512M device doesn't start decoding cycles meant for RAM or some other
>> fixed resource region) then doing the above should be possible.
>
> I doubt it's possible ... it'd only be possible if the 256MB PCI address
> space were not aligned to a 256MB boundary.  And nobody builds systems
> like that.
>
> --
> Matthew Wilcox                          Intel Open Source Technology Centre
> "Bill, look, we understand that you're interested in selling us this
> operating system, but compare it to ours.  We can't possibly take such
> a retrograde step."
>
can you explain a little more on this, the 256MB is aligned of course,
why does the modifiable BAR needs an unaligned pci mem space?

Thanks,
Xianghua
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux