linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list.
@ 2022-06-14 23:01 Emma Anholt
  2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Emma Anholt @ 2022-06-14 23:01 UTC (permalink / raw)
  To: dri-devel, linux-arm-msm, freedreno, Rob Clark, Jordan Crouse,
	Andy Gross, Bjorn Andersson, Rob Herring, Will Deacon,
	Robin Murphy, Joerg Roedel
  Cc: linux-kernel, iommu, linux-arm-kernel, Emma Anholt

Required for turning on per-process page tables for the GPU.

Signed-off-by: Emma Anholt <emma@anholt.net>
---

 drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
index d8e1ef83c01b..bb9220937068 100644
--- a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
+++ b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
@@ -233,6 +233,7 @@ static const struct of_device_id qcom_smmu_client_of_match[] __maybe_unused = {
 	{ .compatible = "qcom,sc7280-mdss" },
 	{ .compatible = "qcom,sc7280-mss-pil" },
 	{ .compatible = "qcom,sc8180x-mdss" },
+	{ .compatible = "qcom,sm8250-mdss" },
 	{ .compatible = "qcom,sdm845-mdss" },
 	{ .compatible = "qcom,sdm845-mss-pil" },
 	{ }
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables.
  2022-06-14 23:01 [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Emma Anholt
@ 2022-06-14 23:01 ` Emma Anholt
  2022-06-15 10:28   ` Dmitry Baryshkov
  2022-07-03  3:56   ` (subset) " Bjorn Andersson
  2022-06-15 10:28 ` [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Dmitry Baryshkov
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 7+ messages in thread
From: Emma Anholt @ 2022-06-14 23:01 UTC (permalink / raw)
  To: dri-devel, linux-arm-msm, freedreno, Rob Clark, Jordan Crouse,
	Andy Gross, Bjorn Andersson, Rob Herring, Will Deacon,
	Robin Murphy, Joerg Roedel
  Cc: linux-kernel, iommu, linux-arm-kernel, Emma Anholt

This is an SMMU for the adreno gpu, and adding this compatible lets
the driver use per-fd page tables, which are required for security
between GPU clients.

Signed-off-by: Emma Anholt <emma@anholt.net>
---

Tested with a full deqp-vk run on RB5, which did involve some iommu faults.

 arch/arm64/boot/dts/qcom/sm8250.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi
index a92230bec1dd..483c0e0f1d1a 100644
--- a/arch/arm64/boot/dts/qcom/sm8250.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi
@@ -2513,7 +2513,7 @@ gpucc: clock-controller@3d90000 {
 		};
 
 		adreno_smmu: iommu@3da0000 {
-			compatible = "qcom,sm8250-smmu-500", "arm,mmu-500";
+			compatible = "qcom,sm8250-smmu-500", "arm,mmu-500", "qcom,adreno-smmu";
 			reg = <0 0x03da0000 0 0x10000>;
 			#iommu-cells = <2>;
 			#global-interrupts = <2>;
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables.
  2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
@ 2022-06-15 10:28   ` Dmitry Baryshkov
  2022-07-03  3:56   ` (subset) " Bjorn Andersson
  1 sibling, 0 replies; 7+ messages in thread
From: Dmitry Baryshkov @ 2022-06-15 10:28 UTC (permalink / raw)
  To: Emma Anholt
  Cc: dri-devel, linux-arm-msm, freedreno, Rob Clark, Jordan Crouse,
	Andy Gross, Bjorn Andersson, Rob Herring, Will Deacon,
	Robin Murphy, Joerg Roedel, linux-kernel, iommu,
	linux-arm-kernel

On Wed, 15 Jun 2022 at 02:01, Emma Anholt <emma@anholt.net> wrote:
>
> This is an SMMU for the adreno gpu, and adding this compatible lets
> the driver use per-fd page tables, which are required for security
> between GPU clients.
>
> Signed-off-by: Emma Anholt <emma@anholt.net>
> ---
>
> Tested with a full deqp-vk run on RB5, which did involve some iommu faults.
>
>  arch/arm64/boot/dts/qcom/sm8250.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi
> index a92230bec1dd..483c0e0f1d1a 100644
> --- a/arch/arm64/boot/dts/qcom/sm8250.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi
> @@ -2513,7 +2513,7 @@ gpucc: clock-controller@3d90000 {
>                 };
>
>                 adreno_smmu: iommu@3da0000 {
> -                       compatible = "qcom,sm8250-smmu-500", "arm,mmu-500";
> +                       compatible = "qcom,sm8250-smmu-500", "arm,mmu-500", "qcom,adreno-smmu";

I see that other dtsi files use a bit different order for the
compatibility strings. They put "qcom,adreno-smmu" before
"arm,mmu-500". Can we please follow them?

With that fixed:
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>

>                         reg = <0 0x03da0000 0 0x10000>;
>                         #iommu-cells = <2>;
>                         #global-interrupts = <2>;
> --
> 2.36.1
>


-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list.
  2022-06-14 23:01 [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Emma Anholt
  2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
@ 2022-06-15 10:28 ` Dmitry Baryshkov
  2022-06-18 23:39 ` Konrad Dybcio
  2022-07-06 16:50 ` Will Deacon
  3 siblings, 0 replies; 7+ messages in thread
From: Dmitry Baryshkov @ 2022-06-15 10:28 UTC (permalink / raw)
  To: Emma Anholt
  Cc: dri-devel, linux-arm-msm, freedreno, Rob Clark, Jordan Crouse,
	Andy Gross, Bjorn Andersson, Rob Herring, Will Deacon,
	Robin Murphy, Joerg Roedel, linux-kernel, iommu,
	linux-arm-kernel

On Wed, 15 Jun 2022 at 02:01, Emma Anholt <emma@anholt.net> wrote:
>
> Required for turning on per-process page tables for the GPU.
>
> Signed-off-by: Emma Anholt <emma@anholt.net>

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>

> ---
>
>  drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> index d8e1ef83c01b..bb9220937068 100644
> --- a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> +++ b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> @@ -233,6 +233,7 @@ static const struct of_device_id qcom_smmu_client_of_match[] __maybe_unused = {
>         { .compatible = "qcom,sc7280-mdss" },
>         { .compatible = "qcom,sc7280-mss-pil" },
>         { .compatible = "qcom,sc8180x-mdss" },
> +       { .compatible = "qcom,sm8250-mdss" },
>         { .compatible = "qcom,sdm845-mdss" },
>         { .compatible = "qcom,sdm845-mss-pil" },
>         { }
> --
> 2.36.1
>


-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list.
  2022-06-14 23:01 [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Emma Anholt
  2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
  2022-06-15 10:28 ` [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Dmitry Baryshkov
@ 2022-06-18 23:39 ` Konrad Dybcio
  2022-07-06 16:50 ` Will Deacon
  3 siblings, 0 replies; 7+ messages in thread
From: Konrad Dybcio @ 2022-06-18 23:39 UTC (permalink / raw)
  To: Emma Anholt, dri-devel, linux-arm-msm, freedreno, Rob Clark,
	Jordan Crouse, Andy Gross, Bjorn Andersson, Rob Herring,
	Will Deacon, Robin Murphy, Joerg Roedel
  Cc: linux-kernel, iommu, linux-arm-kernel



On 15.06.2022 01:01, Emma Anholt wrote:
> Required for turning on per-process page tables for the GPU.
> 
> Signed-off-by: Emma Anholt <emma@anholt.net>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@somainline.org>

Konrad
> 
>  drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> index d8e1ef83c01b..bb9220937068 100644
> --- a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> +++ b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c
> @@ -233,6 +233,7 @@ static const struct of_device_id qcom_smmu_client_of_match[] __maybe_unused = {
>  	{ .compatible = "qcom,sc7280-mdss" },
>  	{ .compatible = "qcom,sc7280-mss-pil" },
>  	{ .compatible = "qcom,sc8180x-mdss" },
> +	{ .compatible = "qcom,sm8250-mdss" },
>  	{ .compatible = "qcom,sdm845-mdss" },
>  	{ .compatible = "qcom,sdm845-mss-pil" },
>  	{ }
> 

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: (subset) [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables.
  2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
  2022-06-15 10:28   ` Dmitry Baryshkov
@ 2022-07-03  3:56   ` Bjorn Andersson
  1 sibling, 0 replies; 7+ messages in thread
From: Bjorn Andersson @ 2022-07-03  3:56 UTC (permalink / raw)
  To: Will Deacon, Rob Herring, Andy Gross, linux-arm-msm,
	Joerg Roedel, Robin Murphy, dri-devel, Rob Clark, Jordan Crouse,
	Emma Anholt, freedreno
  Cc: iommu, linux-kernel, linux-arm-kernel

On Tue, 14 Jun 2022 16:01:36 -0700, Emma Anholt wrote:
> This is an SMMU for the adreno gpu, and adding this compatible lets
> the driver use per-fd page tables, which are required for security
> between GPU clients.
> 
> 

Applied, thanks!

[2/2] arm64: dts: qcom: sm8250: Enable per-process page tables.
      commit: 213d7368723709cf4567488e63dd667802378202

Best regards,
-- 
Bjorn Andersson <bjorn.andersson@linaro.org>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list.
  2022-06-14 23:01 [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Emma Anholt
                   ` (2 preceding siblings ...)
  2022-06-18 23:39 ` Konrad Dybcio
@ 2022-07-06 16:50 ` Will Deacon
  3 siblings, 0 replies; 7+ messages in thread
From: Will Deacon @ 2022-07-06 16:50 UTC (permalink / raw)
  To: Jordan Crouse, Rob Herring, Robin Murphy, Rob Clark, freedreno,
	Emma Anholt, Bjorn Andersson, dri-devel, Joerg Roedel,
	Andy Gross, linux-arm-msm
  Cc: catalin.marinas, kernel-team, Will Deacon, iommu,
	linux-arm-kernel, linux-kernel

On Tue, 14 Jun 2022 16:01:35 -0700, Emma Anholt wrote:
> Required for turning on per-process page tables for the GPU.
> 
> 

Applied to will (for-joerg/arm-smmu/updates), thanks!

[1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list.
      https://git.kernel.org/will/c/3482c0b73073
[2/2] arm64: dts: qcom: sm8250: Enable per-process page tables.
      (no commit info)

Cheers,
-- 
Will

https://fixes.arm64.dev
https://next.arm64.dev
https://will.arm64.dev

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-07-06 16:50 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-14 23:01 [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Emma Anholt
2022-06-14 23:01 ` [PATCH 2/2] arm64: dts: qcom: sm8250: Enable per-process page tables Emma Anholt
2022-06-15 10:28   ` Dmitry Baryshkov
2022-07-03  3:56   ` (subset) " Bjorn Andersson
2022-06-15 10:28 ` [PATCH 1/2] iommu: arm-smmu-impl: Add 8250 display compatible to the client list Dmitry Baryshkov
2022-06-18 23:39 ` Konrad Dybcio
2022-07-06 16:50 ` Will Deacon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).