On 06/11/2012 09:36 PM, Anthony Liguori wrote: >> >> cpu_physical_memory_rw() would be implemented as >> memory_region_rw(system_memory, ...) while pci_dma_rw() would be >> implemented as memory_region_rw(pcibm, ...). This would allow different >> address transformations for the two accesses. > > BTW, the main problem with the memory API right now is that there isn't > a 'MemoryRegion *mr' as the first argument to the dispatch functions.
Why is it a problem? > This could be fixed by introducing yet another set of function pointers > and keeping the existing callers unchanged though. I prefer a full s///, I hate the huge number of thunks we go through to deliver some transaction. Note we had a *mr parameter originally, it was removed in favour of *opaque. -- error compiling committee.c: too many arguments to function