>> The powerpc kernel needs to have full sync insns in every I/O >> accessor in order to enforce all the ordering rules Linux demands. >> It's a bloody shame, but the alternative would be to make the >> barriers lots more expensive. A third alternative would be to > > Well lots more expensive compared to what you have now. But what > you have now is like having those expensive barriers between > *every* io access.
Yeah. But I/O reads are very expensive anyway, and the barriers are used for more than just I/O ordering. I/O writes are a different thing; ideally, they would use only eieio, if anything at all. Maybe the tradeoff isn't optimal. The I/O primitives didn't have all those "sync"s in there before, they got added because some bad interaction with spinlocks was discovered, if my memory isn't failing me. >> have barrier ops that do not order everything, but just A vs. B >> for various choices of A and B (coherent accesses, MMIO accesses, >> etc.) > > The non-smp_ variant is supposed to order everything, AFAIK. Maybe > you could get more fancy and have PIO vs MMIO etc etc. but it looks > like this whole area is in a pretty sticky state anyway so let's > not think about that. *Thinking* about it is fun. Trying to get the code merged would be a different thing ;-) Segher _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev