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

Re: [Xen-devel] [PATCH 1/3] xen/vt-d: need barriers to workaround CLFLUSH



On 2015/5/5 17:24, Jan Beulich wrote:
On 05.05.15 at 04:45, <tiejun.chen@xxxxxxxxx> wrote:
Does this work for everyone?

Please first of all explain why the interfaces in asm/flushtlb.h can't
be used here (at least when flushing entire pages). Because - as

I also don't understand any reason we didn't use this previously on IOMMU side...

said before - for a complete fix you'd need to deal with the CLFLUSH
use(s) elsewhere in the system too.

Looks we need to do this in xen/arch/x86/flushtlb.c:flush_area_local().


Btw, isn't the !iommus_incoherent check in that function inverted?
I.e. why would we _not_ need to flush caches when IOMMUs
are not coherent (and why would flushing be needed when they're
coherent anyway)?


I guess you're misunderstanding this

    if ( !ecap_coherent(iommu->ecap) )
        iommus_incoherent = 1;

So here !iommus_incoherent means IOMMU is coherent and then we don't need to flush cache in this case.

Thanks
Tiejun

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.