[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a0689d30-2214-c92e-8387-8f1d3b22909b@arm.com>
Date: Mon, 26 Jul 2021 14:09:00 +0100
From: Robin Murphy <robin.murphy@....com>
To: Joerg Roedel <joro@...tes.org>
Cc: will@...nel.org, iommu@...ts.linux-foundation.org,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
suravee.suthikulpanit@....com, baolu.lu@...ux.intel.com,
john.garry@...wei.com, dianders@...omium.org
Subject: Re: [PATCH 16/23] iommu/arm-smmu: Prepare for multiple DMA domain
types
On 2021-07-26 13:46, Joerg Roedel wrote:
> On Wed, Jul 21, 2021 at 07:20:27PM +0100, Robin Murphy wrote:
>> - if (type == IOMMU_DOMAIN_DMA && using_legacy_binding)
>> + if ((type & __IOMMU_DOMAIN_DMA_API) && using_legacy_binding)
>
> Hmm, I wonder whether it is time to introduce helpers for these checks?
>
> Something like iommu_domain_is_dma() is more readable.
Ha, I had exactly that at one point, except I think in the order of
iommu_is_dma_domain() :)
The end result didn't seem to give enough extra clarity to justify the
header churn for me, but I'm happy to be wrong about that if you prefer.
Cheers,
Robin.
Powered by blists - more mailing lists