linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support
@ 2023-12-01  9:33 Luca Weiss
  2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Luca Weiss @ 2023-12-01  9:33 UTC (permalink / raw)
  To: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Mauro Carvalho Chehab, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree, Luca Weiss

Devices with Qualcomm firmware (compared to ChromeOS firmware) need some
changes in the venus driver and dts layout so that venus can initialize.

Do these changes, similar to sc7180.

Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
Changes in v3:
- Move 0x2184 iommu from sc7280.dtsi to sc7280-chrome-common.dtsi since
  it seems to cause crash on some boards (Vikash)
- Pick up tags
- Link to v2: https://lore.kernel.org/r/20231002-sc7280-venus-pas-v2-0-bd2408891317@fairphone.com

Changes in v2:
- Reword commit message 2/3 to be clearer (Konrad)
- Link to v1: https://lore.kernel.org/r/20230929-sc7280-venus-pas-v1-0-9c6738cf157a@fairphone.com

---
Luca Weiss (3):
      media: venus: core: Set up secure memory ranges for SC7280
      arm64: dts: qcom: sc7280: Move video-firmware to chrome-common
      arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node

 arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts |  5 +++++
 arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi | 11 +++++++++++
 arch/arm64/boot/dts/qcom/sc7280.dtsi               |  9 +++------
 drivers/media/platform/qcom/venus/core.c           |  4 ++++
 4 files changed, 23 insertions(+), 6 deletions(-)
---
base-commit: b2a4d0696192f24f79ea71fea2d775da28fb9157
change-id: 20230929-sc7280-venus-pas-ea9630525753

Best regards,
-- 
Luca Weiss <luca.weiss@fairphone.com>


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

* [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280
  2023-12-01  9:33 [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Luca Weiss
@ 2023-12-01  9:33 ` Luca Weiss
  2023-12-11  8:12   ` Luca Weiss
  2023-12-17 17:46   ` Bjorn Andersson
  2023-12-01  9:33 ` [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common Luca Weiss
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 9+ messages in thread
From: Luca Weiss @ 2023-12-01  9:33 UTC (permalink / raw)
  To: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Mauro Carvalho Chehab, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree, Luca Weiss

Not all SC7280 devices ship with ChromeOS firmware. Other devices need
PAS for image authentication. That requires the predefined virtual
address ranges to be passed via scm calls. Define them to enable Venus
on non-CrOS SC7280 devices.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Vikash Garodia <quic_vgarodia@quicinc.com>
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
 drivers/media/platform/qcom/venus/core.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c
index 9cffe975581b..a712dd4f02a5 100644
--- a/drivers/media/platform/qcom/venus/core.c
+++ b/drivers/media/platform/qcom/venus/core.c
@@ -881,6 +881,10 @@ static const struct venus_resources sc7280_res = {
 	.vmem_size = 0,
 	.vmem_addr = 0,
 	.dma_mask = 0xe0000000 - 1,
+	.cp_start = 0,
+	.cp_size = 0x25800000,
+	.cp_nonpixel_start = 0x1000000,
+	.cp_nonpixel_size = 0x24800000,
 	.fwname = "qcom/vpu-2.0/venus.mbn",
 };
 

-- 
2.43.0


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

* [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common
  2023-12-01  9:33 [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Luca Weiss
  2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
@ 2023-12-01  9:33 ` Luca Weiss
  2023-12-12  7:59   ` Vikash Garodia
  2024-01-27 22:29   ` Bjorn Andersson
  2023-12-01  9:33 ` [PATCH v3 3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node Luca Weiss
  2024-01-27 22:34 ` (subset) [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Bjorn Andersson
  3 siblings, 2 replies; 9+ messages in thread
From: Luca Weiss @ 2023-12-01  9:33 UTC (permalink / raw)
  To: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Mauro Carvalho Chehab, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree, Luca Weiss

If the video-firmware node is present, the venus driver assumes we're on
a system that doesn't use TZ for starting venus, like on ChromeOS
devices.

Move the video-firmware node to chrome-common.dtsi so we can use venus
on a non-ChromeOS devices. We also need to move the secure SID 0x2184
for iommu since (on some boards) we cannot touch that.

At the same time also disable the venus node by default in the dtsi,
like it's done on other SoCs.

Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
 arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi | 11 +++++++++++
 arch/arm64/boot/dts/qcom/sc7280.dtsi               |  9 +++------
 2 files changed, 14 insertions(+), 6 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
index 5d462ae14ba1..459ff877df54 100644
--- a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
@@ -104,6 +104,17 @@ &scm {
 	dma-coherent;
 };
 
+&venus {
+	iommus = <&apps_smmu 0x2180 0x20>,
+		 <&apps_smmu 0x2184 0x20>;
+
+	status = "okay";
+
+	video-firmware {
+		iommus = <&apps_smmu 0x21a2 0x0>;
+	};
+};
+
 &watchdog {
 	status = "okay";
 };
diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi b/arch/arm64/boot/dts/qcom/sc7280.dtsi
index 326897af117a..0ff9a2484096 100644
--- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
@@ -3836,10 +3836,11 @@ venus: video-codec@aa00000 {
 					<&mmss_noc MASTER_VIDEO_P0 0 &mc_virt SLAVE_EBI1 0>;
 			interconnect-names = "cpu-cfg", "video-mem";
 
-			iommus = <&apps_smmu 0x2180 0x20>,
-				 <&apps_smmu 0x2184 0x20>;
+			iommus = <&apps_smmu 0x2180 0x20>;
 			memory-region = <&video_mem>;
 
+			status = "disabled";
+
 			video-decoder {
 				compatible = "venus-decoder";
 			};
@@ -3848,10 +3849,6 @@ video-encoder {
 				compatible = "venus-encoder";
 			};
 
-			video-firmware {
-				iommus = <&apps_smmu 0x21a2 0x0>;
-			};
-
 			venus_opp_table: opp-table {
 				compatible = "operating-points-v2";
 

-- 
2.43.0


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

* [PATCH v3 3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node
  2023-12-01  9:33 [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Luca Weiss
  2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
  2023-12-01  9:33 ` [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common Luca Weiss
@ 2023-12-01  9:33 ` Luca Weiss
  2024-01-27 22:34 ` (subset) [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Bjorn Andersson
  3 siblings, 0 replies; 9+ messages in thread
From: Luca Weiss @ 2023-12-01  9:33 UTC (permalink / raw)
  To: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Mauro Carvalho Chehab, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree, Luca Weiss

Enable the venus node so that the video encoder/decoder will start
working.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Vikash Garodia <quic_vgarodia@quicinc.com>
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
 arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts b/arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts
index 762c5db29520..cc092735ce17 100644
--- a/arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts
+++ b/arch/arm64/boot/dts/qcom/qcm6490-fairphone-fp5.dts
@@ -688,3 +688,8 @@ &usb_1_qmpphy {
 
 	status = "okay";
 };
+
+&venus {
+	firmware-name = "qcom/qcm6490/fairphone5/venus.mbn";
+	status = "okay";
+};

-- 
2.43.0


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

* Re: [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280
  2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
@ 2023-12-11  8:12   ` Luca Weiss
  2023-12-17 17:46   ` Bjorn Andersson
  1 sibling, 0 replies; 9+ messages in thread
From: Luca Weiss @ 2023-12-11  8:12 UTC (permalink / raw)
  To: Luca Weiss, Stanimir Varbanov, Vikash Garodia,
	Bryan O'Donoghue, Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Mauro Carvalho Chehab, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Hans Verkuil
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree

On Fri Dec 1, 2023 at 10:33 AM CET, Luca Weiss wrote:
> Not all SC7280 devices ship with ChromeOS firmware. Other devices need
> PAS for image authentication. That requires the predefined virtual
> address ranges to be passed via scm calls. Define them to enable Venus
> on non-CrOS SC7280 devices.
>
> Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> Reviewed-by: Vikash Garodia <quic_vgarodia@quicinc.com>
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
> ---
>  drivers/media/platform/qcom/venus/core.c | 4 ++++
>  1 file changed, 4 insertions(+)

Hi Hans,

Is there anything missing for this to be applied or could you pick this
up for v6.8?

Regards
Luca

>
> diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c
> index 9cffe975581b..a712dd4f02a5 100644
> --- a/drivers/media/platform/qcom/venus/core.c
> +++ b/drivers/media/platform/qcom/venus/core.c
> @@ -881,6 +881,10 @@ static const struct venus_resources sc7280_res = {
>  	.vmem_size = 0,
>  	.vmem_addr = 0,
>  	.dma_mask = 0xe0000000 - 1,
> +	.cp_start = 0,
> +	.cp_size = 0x25800000,
> +	.cp_nonpixel_start = 0x1000000,
> +	.cp_nonpixel_size = 0x24800000,
>  	.fwname = "qcom/vpu-2.0/venus.mbn",
>  };
>  


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

* Re: [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common
  2023-12-01  9:33 ` [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common Luca Weiss
@ 2023-12-12  7:59   ` Vikash Garodia
  2024-01-27 22:29   ` Bjorn Andersson
  1 sibling, 0 replies; 9+ messages in thread
From: Vikash Garodia @ 2023-12-12  7:59 UTC (permalink / raw)
  To: Luca Weiss, Stanimir Varbanov, Bryan O'Donoghue, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, Mauro Carvalho Chehab,
	cros-qcom-dts-watchers, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree

On 12/1/2023 3:03 PM, Luca Weiss wrote:
> If the video-firmware node is present, the venus driver assumes we're on
> a system that doesn't use TZ for starting venus, like on ChromeOS
> devices.
> 
> Move the video-firmware node to chrome-common.dtsi so we can use venus
> on a non-ChromeOS devices. We also need to move the secure SID 0x2184
> for iommu since (on some boards) we cannot touch that.
> 
> At the same time also disable the venus node by default in the dtsi,
> like it's done on other SoCs.
> 
> Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>

Reviewed-by: Vikash Garodia <quic_vgarodia@quicinc.com>

Regards,
Vikash
> ---
>  arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi | 11 +++++++++++
>  arch/arm64/boot/dts/qcom/sc7280.dtsi               |  9 +++------
>  2 files changed, 14 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> index 5d462ae14ba1..459ff877df54 100644
> --- a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> @@ -104,6 +104,17 @@ &scm {
>  	dma-coherent;
>  };
>  
> +&venus {
> +	iommus = <&apps_smmu 0x2180 0x20>,
> +		 <&apps_smmu 0x2184 0x20>;
> +
> +	status = "okay";
> +
> +	video-firmware {
> +		iommus = <&apps_smmu 0x21a2 0x0>;
> +	};
> +};
> +
>  &watchdog {
>  	status = "okay";
>  };
> diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi b/arch/arm64/boot/dts/qcom/sc7280.dtsi
> index 326897af117a..0ff9a2484096 100644
> --- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
> @@ -3836,10 +3836,11 @@ venus: video-codec@aa00000 {
>  					<&mmss_noc MASTER_VIDEO_P0 0 &mc_virt SLAVE_EBI1 0>;
>  			interconnect-names = "cpu-cfg", "video-mem";
>  
> -			iommus = <&apps_smmu 0x2180 0x20>,
> -				 <&apps_smmu 0x2184 0x20>;
> +			iommus = <&apps_smmu 0x2180 0x20>;
>  			memory-region = <&video_mem>;
>  
> +			status = "disabled";
> +
>  			video-decoder {
>  				compatible = "venus-decoder";
>  			};
> @@ -3848,10 +3849,6 @@ video-encoder {
>  				compatible = "venus-encoder";
>  			};
>  
> -			video-firmware {
> -				iommus = <&apps_smmu 0x21a2 0x0>;
> -			};
> -
>  			venus_opp_table: opp-table {
>  				compatible = "operating-points-v2";
>  
> 

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

* Re: [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280
  2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
  2023-12-11  8:12   ` Luca Weiss
@ 2023-12-17 17:46   ` Bjorn Andersson
  1 sibling, 0 replies; 9+ messages in thread
From: Bjorn Andersson @ 2023-12-17 17:46 UTC (permalink / raw)
  To: Luca Weiss, Mauro Carvalho Chehab
  Cc: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Konrad Dybcio, cros-qcom-dts-watchers, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, ~postmarketos/upstreaming,
	phone-devel, linux-media, linux-arm-msm, linux-kernel,
	devicetree

On Fri, Dec 01, 2023 at 10:33:18AM +0100, Luca Weiss wrote:
> Not all SC7280 devices ship with ChromeOS firmware. Other devices need
> PAS for image authentication. That requires the predefined virtual
> address ranges to be passed via scm calls. Define them to enable Venus
> on non-CrOS SC7280 devices.
> 
> Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> Reviewed-by: Vikash Garodia <quic_vgarodia@quicinc.com>
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>

Mauro, this series looks ready to be picked up. Can you please merge
this driver patch, so I can pick the two dts changes?

Thanks,
Bjorn

> ---
>  drivers/media/platform/qcom/venus/core.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c
> index 9cffe975581b..a712dd4f02a5 100644
> --- a/drivers/media/platform/qcom/venus/core.c
> +++ b/drivers/media/platform/qcom/venus/core.c
> @@ -881,6 +881,10 @@ static const struct venus_resources sc7280_res = {
>  	.vmem_size = 0,
>  	.vmem_addr = 0,
>  	.dma_mask = 0xe0000000 - 1,
> +	.cp_start = 0,
> +	.cp_size = 0x25800000,
> +	.cp_nonpixel_start = 0x1000000,
> +	.cp_nonpixel_size = 0x24800000,
>  	.fwname = "qcom/vpu-2.0/venus.mbn",
>  };
>  
> 
> -- 
> 2.43.0
> 

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

* Re: [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common
  2023-12-01  9:33 ` [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common Luca Weiss
  2023-12-12  7:59   ` Vikash Garodia
@ 2024-01-27 22:29   ` Bjorn Andersson
  1 sibling, 0 replies; 9+ messages in thread
From: Bjorn Andersson @ 2024-01-27 22:29 UTC (permalink / raw)
  To: Luca Weiss
  Cc: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Konrad Dybcio, Mauro Carvalho Chehab,
	cros-qcom-dts-watchers, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, ~postmarketos/upstreaming, phone-devel,
	linux-media, linux-arm-msm, linux-kernel, devicetree

On Fri, Dec 01, 2023 at 10:33:19AM +0100, Luca Weiss wrote:
> If the video-firmware node is present, the venus driver assumes we're on
> a system that doesn't use TZ for starting venus, like on ChromeOS
> devices.
> 
> Move the video-firmware node to chrome-common.dtsi so we can use venus
> on a non-ChromeOS devices. We also need to move the secure SID 0x2184
> for iommu since (on some boards) we cannot touch that.
> 
> At the same time also disable the venus node by default in the dtsi,
> like it's done on other SoCs.
> 
> Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
> ---
>  arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi | 11 +++++++++++
>  arch/arm64/boot/dts/qcom/sc7280.dtsi               |  9 +++------
>  2 files changed, 14 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> index 5d462ae14ba1..459ff877df54 100644
> --- a/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sc7280-chrome-common.dtsi
> @@ -104,6 +104,17 @@ &scm {
>  	dma-coherent;
>  };
>  
> +&venus {
> +	iommus = <&apps_smmu 0x2180 0x20>,
> +		 <&apps_smmu 0x2184 0x20>;
> +
> +	status = "okay";
> +
> +	video-firmware {
> +		iommus = <&apps_smmu 0x21a2 0x0>;
> +	};
> +};
> +
>  &watchdog {
>  	status = "okay";
>  };
> diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi b/arch/arm64/boot/dts/qcom/sc7280.dtsi
> index 326897af117a..0ff9a2484096 100644
> --- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
> @@ -3836,10 +3836,11 @@ venus: video-codec@aa00000 {
>  					<&mmss_noc MASTER_VIDEO_P0 0 &mc_virt SLAVE_EBI1 0>;
>  			interconnect-names = "cpu-cfg", "video-mem";
>  
> -			iommus = <&apps_smmu 0x2180 0x20>,
> -				 <&apps_smmu 0x2184 0x20>;
> +			iommus = <&apps_smmu 0x2180 0x20>;

qcom,sc7280-venus expects 2 items here. Please follow up with a patch to
the binding, if you haven't send one already.

Thanks,
Bjorn

>  			memory-region = <&video_mem>;
>  
> +			status = "disabled";
> +
>  			video-decoder {
>  				compatible = "venus-decoder";
>  			};
> @@ -3848,10 +3849,6 @@ video-encoder {
>  				compatible = "venus-encoder";
>  			};
>  
> -			video-firmware {
> -				iommus = <&apps_smmu 0x21a2 0x0>;
> -			};
> -
>  			venus_opp_table: opp-table {
>  				compatible = "operating-points-v2";
>  
> 
> -- 
> 2.43.0
> 

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

* Re: (subset) [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support
  2023-12-01  9:33 [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Luca Weiss
                   ` (2 preceding siblings ...)
  2023-12-01  9:33 ` [PATCH v3 3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node Luca Weiss
@ 2024-01-27 22:34 ` Bjorn Andersson
  3 siblings, 0 replies; 9+ messages in thread
From: Bjorn Andersson @ 2024-01-27 22:34 UTC (permalink / raw)
  To: Stanimir Varbanov, Vikash Garodia, Bryan O'Donoghue,
	Andy Gross, Konrad Dybcio, Mauro Carvalho Chehab,
	cros-qcom-dts-watchers, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Luca Weiss
  Cc: ~postmarketos/upstreaming, phone-devel, linux-media,
	linux-arm-msm, linux-kernel, devicetree


On Fri, 01 Dec 2023 10:33:17 +0100, Luca Weiss wrote:
> Devices with Qualcomm firmware (compared to ChromeOS firmware) need some
> changes in the venus driver and dts layout so that venus can initialize.
> 
> Do these changes, similar to sc7180.
> 
> 

Applied, thanks!

[2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common
      commit: 82066cdb17608abc95192632fd5c702be8e57ab5
[3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node
      commit: 2aa72de2fc9230c54048e3555d04e945ec4f8891

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

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

end of thread, other threads:[~2024-01-27 22:34 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-01  9:33 [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Luca Weiss
2023-12-01  9:33 ` [PATCH v3 1/3] media: venus: core: Set up secure memory ranges for SC7280 Luca Weiss
2023-12-11  8:12   ` Luca Weiss
2023-12-17 17:46   ` Bjorn Andersson
2023-12-01  9:33 ` [PATCH v3 2/3] arm64: dts: qcom: sc7280: Move video-firmware to chrome-common Luca Weiss
2023-12-12  7:59   ` Vikash Garodia
2024-01-27 22:29   ` Bjorn Andersson
2023-12-01  9:33 ` [PATCH v3 3/3] arm64: dts: qcom: qcm6490-fairphone-fp5: Enable venus node Luca Weiss
2024-01-27 22:34 ` (subset) [PATCH v3 0/3] Enable venus on Fairphone 5 / non-ChromeOS sc7280 venus support Bjorn Andersson

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).