On 4 October 2011 07:29, Paolo Bonzini <pbonz...@redhat.com> wrote: > On 10/04/2011 07:55 AM, Stefan Weil wrote: >> I learned now that ppc will need flush_icache_range() for kvm, too. >> So it won't be possible to implement a uniform handling of >> flush_icache_range() for all host architectures. > > x86 and IIRC s390 flush_icache_range is a no-op, so it is possible to "call" > it for all KVM architectures without incurring penalties.
...but presumably when ARM KVM actually lands we'll need to make flush_icache_range() available for it too. If flushing the icache isn't a TCG-specific operation, then we should have implementations in some other per-target-architecture file. Doesn't particularly matter where as long as we're consistent for all architectures. (I'd also like to see more of the ifdef-target-foo ladders in common files broken out into more cleanly defined interfaces provided by per-target source files, personally.) -- PMM