[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <010101747c43f329-e6376c08-27e9-4b2e-92cd-f2e0a28d9e3c-000000@us-west-2.amazonses.com>
Date: Fri, 11 Sep 2020 08:24:22 +0000
From: Sai Prakash Ranjan <saiprakash.ranjan@...eaurora.org>
To: Bjorn Andersson <bjorn.andersson@...aro.org>
Cc: Will Deacon <will@...nel.org>, Robin Murphy <robin.murphy@....com>,
Joerg Roedel <joro@...tes.org>,
Jordan Crouse <jcrouse@...eaurora.org>,
Rob Clark <robdclark@...omium.org>,
Sibi Sankar <sibis@...eaurora.org>,
linux-arm-kernel@...ts.infradead.org,
iommu@...ts.linux-foundation.org, linux-kernel@...r.kernel.org,
linux-arm-msm@...r.kernel.org
Subject: Re: [PATCH v3 3/8] iommu/arm-smmu: Consult context bank allocator for
identify domains
On 2020-09-04 21:25, Bjorn Andersson wrote:
> For implementations of the ARM SMMU where stream mappings of bypass
> type
> are prohibited identity domains can be implemented by using context
> banks with translation disabled.
>
> Postpone the decision to skip allocating a context bank until the
> implementation specific context bank allocator has been consulted and
> if
> it decides to use a context bank for the identity map, don't enable
> translation (i.e. omit ARM_SMMU_SCTLR_M).
>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@...aro.org>
> ---
>
<snip>...
> diff --git a/drivers/iommu/arm/arm-smmu/arm-smmu.h
> b/drivers/iommu/arm/arm-smmu/arm-smmu.h
> index ddf2ca4c923d..235d9a3a6ab6 100644
> --- a/drivers/iommu/arm/arm-smmu/arm-smmu.h
> +++ b/drivers/iommu/arm/arm-smmu/arm-smmu.h
> @@ -243,6 +243,8 @@ enum arm_smmu_cbar_type {
> #define TLB_LOOP_TIMEOUT 1000000 /* 1s! */
> #define TLB_SPIN_COUNT 10
>
> +#define ARM_SMMU_CBNDX_BYPASS 0xffff
> +
> /* Shared driver definitions */
> enum arm_smmu_arch_version {
> ARM_SMMU_V1,
> @@ -346,6 +348,7 @@ struct arm_smmu_cfg {
> u32 sctlr_clr; /* bits to mask in SCTLR */
> enum arm_smmu_cbar_type cbar;
> enum arm_smmu_context_fmt fmt;
> + bool m;
Can we use mmu_enable instead of m here to be more descriptive?
Thanks,
Sai
--
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a
member
of Code Aurora Forum, hosted by The Linux Foundation
Powered by blists - more mailing lists