tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pci_mapreg_map(9) and prefetchable BARs
On Tue, Aug 09, 2011 at 05:38:43PM -0400, Michael wrote:
> Hello,
>
> Why would it fail if the BAR is marked as prefetchable but someone
> requests a non-prefetchable mapping? The bit is just a hint.
My phrasing was probably awkward. It wouldn't fail in that case.
Here's the proposal:
1 Safety first: pci_mapreg_map() should map every BAR as
if it is non-prefetchable (i.e., non-cached, non-write
combining, order enforced) unless the caller passes the hint
BUS_SPACE_MAP_PREFETCHABLE.
2 pci_mapreg_map() should turn on caching, write-combining, et cetera,
on a prefetchable BAR if the caller passes BUS_SPACE_MAP_PREFETCHABLE.
3 pci_mapreg_map() should return 1 (indicating an error) before it
violates #1.
Dave
--
David Young OJC Technologies
dyoung%ojctech.com@localhost Urbana, IL * (217) 344-0444 x24
Home |
Main Index |
Thread Index |
Old Index