Re: [PATCH rfcv1 7/8] iommu/arm-smmu-v3: Add arm_smmu_invs based arm_smmu_domain_inv_range()

From: Nicolin Chen
Date: Mon Sep 08 2025 - 14:46:34 EST


On Mon, Sep 08, 2025 at 03:24:04PM -0300, Jason Gunthorpe wrote:
> On Mon, Sep 08, 2025 at 11:19:40AM -0700, Nicolin Chen wrote:
> > So, would it be better to just always take the read lock, while
> > applying the ATS condition to the writer side:
>
> No, the whole optimization is to avoid read side locking on the fairly
> common no-ATS case.
>
> Always taking the lock destroys that.

OK. I skimmed through the lock_acquire(). It seems to be a bit
heavier than I expected. Perhaps this is the part we wanted to
avoid.

Thanks
Nicolin