linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder
@ 2025-08-04 18:01 Brandon Brnich
  2025-08-05  4:56 ` devarsh
  2025-08-05  6:02 ` Krzysztof Kozlowski
  0 siblings, 2 replies; 5+ messages in thread
From: Brandon Brnich @ 2025-08-04 18:01 UTC (permalink / raw)
  To: linux-kernel
  Cc: Nishanth Menon, Vignesh Raghavendra, Tero Kristo, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, linux-arm-kernel, devicetree,
	Devarsh Thakkar, Udit Kumar, Darren Etheridge, Brandon Brnich

This adds node for E5010 JPEG Encoder which is a stateful JPEG Encoder
present in J722s SoC, supporting baseline encoding of semiplanar based
YUV420 and YUV422 raw video formats to JPEG encoding, with resolutions
supported from 64x64 to 8kx8k.

Signed-off-by: Brandon Brnich <b-brnich@ti.com>
---

Changes in v2:
  - remove invalid clock-names attribute

 arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
index 5cfa7bf36641..fb24c14614b4 100644
--- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
+++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
@@ -385,6 +385,16 @@ c7x_1: dsp@7e200000 {
 		ti,sci-proc-ids = <0x31 0xff>;
 		status = "disabled";
 	};
+
+	e5010: e5010@fd20000 {
+		compatible = "img,e5010-jpeg-enc";
+		reg = <0x00 0xfd20000 0x00 0x100>,
+		      <0x00 0xfd20200 0x00 0x200>;
+		reg-names = "core","mmu";
+		clocks = <&k3_clks 201 0>;
+		power-domains = <&k3_pds 201 TI_SCI_PD_EXCLUSIVE>;
+		interrupts = <GIC_SPI 98 IRQ_TYPE_LEVEL_HIGH>;
+	};
 };
 
 &main_bcdma_csi {
-- 
2.34.1



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

* Re: [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder
  2025-08-04 18:01 [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder Brandon Brnich
@ 2025-08-05  4:56 ` devarsh
  2025-08-05  6:02 ` Krzysztof Kozlowski
  1 sibling, 0 replies; 5+ messages in thread
From: devarsh @ 2025-08-05  4:56 UTC (permalink / raw)
  To: Brandon Brnich, linux-kernel
  Cc: Nishanth Menon, Vignesh Raghavendra, Tero Kristo, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, linux-arm-kernel, devicetree,
	Udit Kumar, Darren Etheridge

Hi Brandon,

Thanks for the patch.
On 04/08/25 23:31, Brandon Brnich wrote:
> This adds node for E5010 JPEG Encoder which is a stateful JPEG Encoder
> present in J722s SoC, supporting baseline encoding of semiplanar based
> YUV420 and YUV422 raw video formats to JPEG encoding, with resolutions
> supported from 64x64 to 8kx8k.
> 
> Signed-off-by: Brandon Brnich <b-brnich@ti.com>
> ---
> 
> Changes in v2:
>   - remove invalid clock-names attribute
> 
>  arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> index 5cfa7bf36641..fb24c14614b4 100644
> --- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> +++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> @@ -385,6 +385,16 @@ c7x_1: dsp@7e200000 {
>  		ti,sci-proc-ids = <0x31 0xff>;
>  		status = "disabled";
>  	};
> +
> +	e5010: e5010@fd20000 {
> +		compatible = "img,e5010-jpeg-enc";

This is missing ti specific compatible. As we don't use the IP block
directly but there is a wrapper used to integrate with TI platform, so
it is better to use TI specific compatible too to account for the future
compatibility as discussed here [1]. You can refer AM62A device-tree [2]
for references on this.

[1]:
https://lore.kernel.org/all/50d97c30-4926-0bbf-1209-dfd25043e359@ti.com/
[2] :
https://gitlab.com/linux-kernel/linux-next/-/blob/master/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi?ref_type=heads#L1150

Regards
Devarsh


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

* Re: [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder
  2025-08-04 18:01 [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder Brandon Brnich
  2025-08-05  4:56 ` devarsh
@ 2025-08-05  6:02 ` Krzysztof Kozlowski
  2025-08-05 13:34   ` Brandon Brnich
  1 sibling, 1 reply; 5+ messages in thread
From: Krzysztof Kozlowski @ 2025-08-05  6:02 UTC (permalink / raw)
  To: Brandon Brnich, linux-kernel
  Cc: Nishanth Menon, Vignesh Raghavendra, Tero Kristo, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, linux-arm-kernel, devicetree,
	Devarsh Thakkar, Udit Kumar, Darren Etheridge

On 04/08/2025 20:01, Brandon Brnich wrote:
> This adds node for E5010 JPEG Encoder which is a stateful JPEG Encoder
> present in J722s SoC, supporting baseline encoding of semiplanar based
> YUV420 and YUV422 raw video formats to JPEG encoding, with resolutions
> supported from 64x64 to 8kx8k.
> 
> Signed-off-by: Brandon Brnich <b-brnich@ti.com>
> ---
> 
> Changes in v2:
>   - remove invalid clock-names attribute
> 
>  arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> index 5cfa7bf36641..fb24c14614b4 100644
> --- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> +++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
> @@ -385,6 +385,16 @@ c7x_1: dsp@7e200000 {
>  		ti,sci-proc-ids = <0x31 0xff>;
>  		status = "disabled";
>  	};
> +
> +	e5010: e5010@fd20000 {

Node names should be generic. See also an explanation and list of
examples (not exhaustive) in DT specification:
https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation


> +		compatible = "img,e5010-jpeg-enc";

Wrong compatible. This is TI, not IMG.


Best regards,
Krzysztof


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

* Re: [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder
  2025-08-05  6:02 ` Krzysztof Kozlowski
@ 2025-08-05 13:34   ` Brandon Brnich
  2025-08-05 14:05     ` Brandon Brnich
  0 siblings, 1 reply; 5+ messages in thread
From: Brandon Brnich @ 2025-08-05 13:34 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel
  Cc: Nishanth Menon, Vignesh Raghavendra, Tero Kristo, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, linux-arm-kernel, devicetree,
	Devarsh Thakkar, Udit Kumar, Darren Etheridge

Hi Krzysztof,

Thanks for the review.

On 8/5/2025 1:02 AM, Krzysztof Kozlowski wrote:
> On 04/08/2025 20:01, Brandon Brnich wrote:
>> This adds node for E5010 JPEG Encoder which is a stateful JPEG Encoder
>> present in J722s SoC, supporting baseline encoding of semiplanar based
>> YUV420 and YUV422 raw video formats to JPEG encoding, with resolutions
>> supported from 64x64 to 8kx8k.
>>
>> Signed-off-by: Brandon Brnich <b-brnich@ti.com>
>> ---
>>
>> Changes in v2:
>>    - remove invalid clock-names attribute
>>
>>   arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 10 ++++++++++
>>   1 file changed, 10 insertions(+)
>>
>> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
>> index 5cfa7bf36641..fb24c14614b4 100644
>> --- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
>> +++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
>> @@ -385,6 +385,16 @@ c7x_1: dsp@7e200000 {
>>   		ti,sci-proc-ids = <0x31 0xff>;
>>   		status = "disabled";
>>   	};
>> +
>> +	e5010: e5010@fd20000 {
> 
> Node names should be generic. See also an explanation and list of
> examples (not exhaustive) in DT specification:
> https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation

I got this name from the already present node in the am62a device 
tree[0]. Should I replace both of these with more generic name such as 
jpegenc?

> 
> 
>> +		compatible = "img,e5010-jpeg-enc";
> 
> Wrong compatible. This is TI, not IMG.

Devarsh has pointed out the same, I will update compatible that matches 
TI version in v3.

Best,
Brandon

[0]: 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi#n1149

> 
> 
> Best regards,
> Krzysztof



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

* Re: [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder
  2025-08-05 13:34   ` Brandon Brnich
@ 2025-08-05 14:05     ` Brandon Brnich
  0 siblings, 0 replies; 5+ messages in thread
From: Brandon Brnich @ 2025-08-05 14:05 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-kernel
  Cc: Nishanth Menon, Vignesh Raghavendra, Tero Kristo, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, linux-arm-kernel, devicetree,
	Devarsh Thakkar, Udit Kumar, Darren Etheridge

Hello,

On 8/5/2025 8:34 AM, Brandon Brnich wrote:
> Hi Krzysztof,
> 
> Thanks for the review.
> 
> On 8/5/2025 1:02 AM, Krzysztof Kozlowski wrote:
>> On 04/08/2025 20:01, Brandon Brnich wrote:
>>> This adds node for E5010 JPEG Encoder which is a stateful JPEG Encoder
>>> present in J722s SoC, supporting baseline encoding of semiplanar based
>>> YUV420 and YUV422 raw video formats to JPEG encoding, with resolutions
>>> supported from 64x64 to 8kx8k.
>>>
>>> Signed-off-by: Brandon Brnich <b-brnich@ti.com>
>>> ---
>>>
>>> Changes in v2:
>>>    - remove invalid clock-names attribute
>>>
>>>   arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 10 ++++++++++
>>>   1 file changed, 10 insertions(+)
>>>
>>> diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/ 
>>> boot/dts/ti/k3-j722s-main.dtsi
>>> index 5cfa7bf36641..fb24c14614b4 100644
>>> --- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
>>> +++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi
>>> @@ -385,6 +385,16 @@ c7x_1: dsp@7e200000 {
>>>           ti,sci-proc-ids = <0x31 0xff>;
>>>           status = "disabled";
>>>       };
>>> +
>>> +    e5010: e5010@fd20000 {
>>
>> Node names should be generic. See also an explanation and list of
>> examples (not exhaustive) in DT specification:
>> https://devicetree-specification.readthedocs.io/en/latest/chapter2- 
>> devicetree-basics.html#generic-names-recommendation
> 
> I got this name from the already present node in the am62a device 
> tree[0]. Should I replace both of these with more generic name such as 
> jpegenc?

Please ignore above comment, I was thinking about the label and not the 
node name. I understand node name needs to be jpeg-encoder.

Should label also be more generic? I see a few examples where the label 
is jpegenc or something more generic than the specific part name. But I 
don't see any specific rules in the devicetree specs on labels.


> 
>>
>>
>>> +        compatible = "img,e5010-jpeg-enc";
>>
>> Wrong compatible. This is TI, not IMG.
> 
> Devarsh has pointed out the same, I will update compatible that matches 
> TI version in v3.
> 
> Best,
> Brandon
> 
> [0]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/ 
> tree/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi#n1149
> 
>>
>>
>> Best regards,
>> Krzysztof
> 



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

end of thread, other threads:[~2025-08-05 15:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-04 18:01 [PATCH v2] arm64: dts: ti: k3-j722s-main: Add E5010 JPEG Encoder Brandon Brnich
2025-08-05  4:56 ` devarsh
2025-08-05  6:02 ` Krzysztof Kozlowski
2025-08-05 13:34   ` Brandon Brnich
2025-08-05 14:05     ` Brandon Brnich

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