On 2/25/21 6:51 PM, Stefano Stabellini wrote: > Newer Xen versions expose two Xen feature flags to tell us if the domain > is directly mapped or not. Only when a domain is directly mapped it > makes sense to enable swiotlb-xen on ARM. > > Introduce a function on ARM to check the new Xen feature flags and also > to deal with the legacy case. Call the function xen_swiotlb_detect. > > Also rename the existing pci_xen_swiotlb_detect on x86 to > xen_swiotlb_detect so that we can share a common function declaration. > > Signed-off-by: Stefano Stabellini <stefano.stabell...@xilinx.com> > --- > > This is the corresponding Xen patch under review: > https://marc.info/?l=xen-devel&m=161421618217686 > > We don't *have to* make the x86 function and the ARM function exactly > the same, but I thought it would be much nicer if we did. However, we > can't really call it pci_* on ARM as there is no PCI necessarily.
I would prefer to keep existing names for consistency on x86 side (but making that inconsistent with ARM, as you point out). But if you feel strongly about making the change you would have to have x86 maintainers agree to this (arch/x86/kernel/pci-swiotlb.c). -boris