Thanks, I had no idea that the sync functions neutralize themselves this way. That is, since commit 591c1ee465ce ("of: configure the platform device dma parameters") from back in April 2014.+static void xilly_sync_for_device(struct xilly_endpoint *ep,These wrappers should not even be needed. When the device is
> + dma_addr_t dma_handle,
> + size_t size,
> + int direction)
> +{
> + if (ep->make_sync_calls)
> + dma_sync_single_for_device(ep->dev, dma_handle,
> + size, direction);
> +}
marked as coherent in DT, the dma_sync_*() calls are supposed
to do nothing, in a relatively efficient way. I would not expect
the extra conditional to give you any measurable performance
benefit over what you get normally, and it should not make a
functional difference either.
Can you remove the inlines and the ->make_sync_calls flag?