🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: linux.kernel.netdev
5 messages
5 total messages Started by Imran Shaik Tue, 13 Oct 2026 11:49
Re: [PATCH 1/6] dt-bindings: ptp: Document the TSCSS on Qualcomm Lemans and Monaco SoCs
#2756
Author: Imran Shaik
Date: Tue, 13 Oct 2026 11:49
142 lines
15643 bytes

On 01-09-2026 12:10 pm, Krzysztof Kozlowski wrote:
> On 01/09/2026 08:31, Imran Shaik wrote:
>>>
>>>> +  clocks:
>>>> +    minItems: 2
>>>> +    items:
>>>> +      - description: TSC AHB configuration clock.
>>>> +      - description: TSC global counter clock.
>>>> +      - description: TSC ETU clock.
>>>> +
>>>> +  clock-names:
>>>> +    minItems: 2
>>>
>>> Why is this flexible?
>>>
>>
>> Actually, the TSC block can standalone work without the ETU support as
>> well. This ETU clock is require only when we add the ETU slice sub
>> nodes. Hence, keeping the minItems to 2, excluding the ETU clock.
> 
> Hardware either has them or not. Whether they are necessary to
> prepared/enabled is independent thing and job for the driver.
> 

Sure, will drop that flexible logic.

> 
>>
>>>> +    items:
>>>> +      - const: ahb
>>>> +      - const: cntr
>>>> +      - const: etu
>>>> +
>>>> +  interrupts:
>>>> +    description: Summary interrupt raised based on external event for any of the ETU slices.
>>>
>>> Please follow Linux coding style.
>>>
>>
>> Sure, will update.
>>
>>>> +    maxItems: 1
>>>> +
>>>> +  interrupt-names:
>>>> +    items:
>>>> +      - const: etu_summary
>>>> +
>>>> +  assigned-clocks: true
>>>> +  assigned-clock-rates: true
>>>
>>> Drop. From where did you take it?
>>>
>>
>> Actually, we need these properties to be present in the DTS to take care
>> of the clock rate requirements.
>>
>> Please suggest on how to handle such requirements.
> 
> Why does this binding has to be different than ALL other bindings in the
> kernel? I am not talking about DTS now.
> 

Sure, will check and drop.

>>
>>>> +
>>>> +  "#address-cells":
>>>> +    const: 2
>>>> +
>>>> +  "#size-cells":
>>>> +    const: 2
>>>> +
>>>> +  ranges: true
>>>> +
>>>> +patternProperties:
>>>> +  "^etu-slice@[0-9a-f]+$":
>>>> +    type: object
>>>> +    description: ETU slice configuration
>>>> +    properties:
>>>> +      reg:
>>>> +        maxItems: 1
>>>> +
>>>> +      pinctrl-0: true
>>>> +
>>>> +      pinctrl-names:
>>>> +        items:
>>>> +          - const: default
>>>
>>> Heh? Which code do you copy?
>>>
>>
>> Each ETU slice has its own external event pin config, so kept pinctrl-0
>> and pinctrl-names on the slice subnode. Please suggest if you prefer
>> otherwise.
> 
> No, from where did you get this code? Why are you sending bindings which
> are different then all other bindings?
> 

I was referring to the example in [1] when adding the pinctrl properties
under the etu-slice sub node.

[1] - 
Documentation/devicetree/bindings/media/samsung,exynos4212-fimc-is.yaml

On checking further, I found that our etu-slice sub node deviates from
that example, since we don't have a compatible string for the sub node.

Please let me know if we should move the pinctrl properties under the
tscss node with per-slice names, or instead keep them under the
etu-slice sub node and add a compatible there.

> 
>>
>>>> +
>>>> +      qcom,etu-event-sel:
>>>> +        description: Event selection value for this slice.
>>>> +        $ref: /schemas/types.yaml#/definitions/uint32
>>>> +
>>>> +      qcom,etu-slice:
>>>> +        description: ETU slice identifier.
>>>
>>> You do not get identifiers. Please read writing bindings.
>>>
>>
>> In general, any ETU slice can function with any ETU event sel, and this
>> might not be 1-1 always. Also, these ETU slices can be configured by the
>> vendors based on the requirements of the GPIOs on the board. Hence, this
>> etu-slice identifier will provide the flexibility to configure
>> accordingly.
> 
> 'reg' defines which ETU slice is this, no?
> 

Yes, will drop qcom,etu-slice property.

> 
> Best regards,
> Krzysztof
Re: [PATCH 1/6] dt-bindings: ptp: Document the TSCSS on Qualcomm Lemans and Monaco SoCs
#6757
Author: Krzysztof Kozlowski
Date: Fri, 23 Oct 2026 09:39
62 lines
13369 bytes
On 13/10/2026 13:49, Imran Shaik wrote:
>>>>> +
>>>>> +patternProperties:
>>>>> +  "^etu-slice@[0-9a-f]+$":
>>>>> +    type: object
>>>>> +    description: ETU slice configuration
>>>>> +    properties:
>>>>> +      reg:
>>>>> +        maxItems: 1
>>>>> +
>>>>> +      pinctrl-0: true
>>>>> +
>>>>> +      pinctrl-names:
>>>>> +        items:
>>>>> +          - const: default
>>>>
>>>> Heh? Which code do you copy?
>>>>
>>>
>>> Each ETU slice has its own external event pin config, so kept pinctrl-0
>>> and pinctrl-names on the slice subnode. Please suggest if you prefer
>>> otherwise.

Just drop both pinctrl properties, because you should not need them. You
define them only if they are different than default.

>>
>> No, from where did you get this code? Why are you sending bindings which
>> are different then all other bindings?
>>
> 
> I was referring to the example in [1] when adding the pinctrl properties
> under the etu-slice sub node.
> 
> [1] - 
> Documentation/devicetree/bindings/media/samsung,exynos4212-fimc-is.yaml

That's like 13 years old device binding, so unfortunately likely
antipattern.



> 
> On checking further, I found that our etu-slice sub node deviates from
> that example, since we don't have a compatible string for the sub node.
> 
> Please let me know if we should move the pinctrl properties under the
> tscss node with per-slice names, or instead keep them under the
> etu-slice sub node and add a compatible there.

etu-slice does not feel like device at all unfortunately. I see only
address space, so one resource, which might be enough but lack of
description for the subnode is not helping. I have doubts that separate
subnodes should be there in the first place, but if they stay, describe
the child node fully - what sort of device it is. Just because there is
independent timestamping counter does not make it separate device, just
like independent interrupt in GIC is not itself an independent device.


Best regards,
Krzysztof
Re: [PATCH 1/6] dt-bindings: ptp: Document the TSCSS on Qualcomm Lemans and Monaco SoCs
#7494
Author: Imran Shaik
Date: Mon, 26 Oct 2026 12:55
102 lines
18803 bytes

On 23-10-2026 03:09 pm, Krzysztof Kozlowski wrote:
> On 13/10/2026 13:49, Imran Shaik wrote:
>>>>>> +
>>>>>> +patternProperties:
>>>>>> +  "^etu-slice@[0-9a-f]+$":
>>>>>> +    type: object
>>>>>> +    description: ETU slice configuration
>>>>>> +    properties:
>>>>>> +      reg:
>>>>>> +        maxItems: 1
>>>>>> +
>>>>>> +      pinctrl-0: true
>>>>>> +
>>>>>> +      pinctrl-names:
>>>>>> +        items:
>>>>>> +          - const: default
>>>>>
>>>>> Heh? Which code do you copy?
>>>>>
>>>>
>>>> Each ETU slice has its own external event pin config, so kept pinctrl-0
>>>> and pinctrl-names on the slice subnode. Please suggest if you prefer
>>>> otherwise.
> 
> Just drop both pinctrl properties, because you should not need them. You
> define them only if they are different than default.
> 

Thanks for the feedback, will drop this in next series.

>>>
>>> No, from where did you get this code? Why are you sending bindings which
>>> are different then all other bindings?
>>>
>>
>> I was referring to the example in [1] when adding the pinctrl properties
>> under the etu-slice sub node.
>>
>> [1] -
>> Documentation/devicetree/bindings/media/samsung,exynos4212-fimc-is.yaml
> 
> That's like 13 years old device binding, so unfortunately likely
> antipattern.
> 
> 
> 
>>
>> On checking further, I found that our etu-slice sub node deviates from
>> that example, since we don't have a compatible string for the sub node.
>>
>> Please let me know if we should move the pinctrl properties under the
>> tscss node with per-slice names, or instead keep them under the
>> etu-slice sub node and add a compatible there.
> 
> etu-slice does not feel like device at all unfortunately. I see only
> address space, so one resource, which might be enough but lack of
> description for the subnode is not helping. I have doubts that separate
> subnodes should be there in the first place, but if they stay, describe
> the child node fully - what sort of device it is. Just because there is
> independent timestamping counter does not make it separate device, just
> like independent interrupt in GIC is not itself an independent device.
> 

The ETU is an independent hardware block within TSCSS that captures/
snapshots the TSC timestamp in response to an external hardware
event trigger, for each slice individually. Hence the subnodes approach
was followed and will capture these details in the description as well.

If we drop the subnodes and add everything into the parent TSCSS node
instead, then all the arrays here must stay index aligned as per slice
mapping. Example DTS node looks like this (QDU1000, 3 slices):

ptp@1da0000 {
	compatible = "qcom,qdu1000-tscss";
	reg = <0x0 0x01da0000 0x0 0x2000>,
	      <0x0 0x01db0000 0x0 0x10000>;
	reg-names = "tsc", "etu";
	
	...

	interrupts = <GIC_SPI 329 IRQ_TYPE_EDGE_RISING>,
		     <GIC_SPI 333 IRQ_TYPE_EDGE_RISING>,
		     <GIC_SPI 334 IRQ_TYPE_EDGE_RISING>;
	interrupt-names = "slice1", "slice5", "slice6";
	
	pinctrl-0 = <&tod_pps>;
	pinctrl-1 = <&gps_pps>;
	pinctrl-2 = <&hardsync_pps>;
	pinctrl-names = "slice1", "slice5", "slice6";
	
	qcom,etu-slice = <1 5 6>;
	qcom,etu-event-sel = <1 3 2>;
};

Please help suggest which approach to follow here. Accordingly, I will
update the bindings in next series.

Thanks,
Imran
Re: [PATCH 1/6] dt-bindings: ptp: Document the TSCSS on Qualcomm Lemans and Monaco SoCs
#7958
Author: Krzysztof Kozlowski
Date: Tue, 27 Oct 2026 15:19
61 lines
13756 bytes
On 26/10/2026 13:55, Imran Shaik wrote:
>>
>>>
>>> On checking further, I found that our etu-slice sub node deviates from
>>> that example, since we don't have a compatible string for the sub node.
>>>
>>> Please let me know if we should move the pinctrl properties under the
>>> tscss node with per-slice names, or instead keep them under the
>>> etu-slice sub node and add a compatible there.
>>
>> etu-slice does not feel like device at all unfortunately. I see only
>> address space, so one resource, which might be enough but lack of
>> description for the subnode is not helping. I have doubts that separate
>> subnodes should be there in the first place, but if they stay, describe
>> the child node fully - what sort of device it is. Just because there is
>> independent timestamping counter does not make it separate device, just
>> like independent interrupt in GIC is not itself an independent device.
>>
> 
> The ETU is an independent hardware block within TSCSS that captures/

How is it independent? I see no resources, except address space. A
channel of some device does not mean it is a separate device.


> snapshots the TSC timestamp in response to an external hardware
> event trigger, for each slice individually. Hence the subnodes approach
> was followed and will capture these details in the description as well.
> 
> If we drop the subnodes and add everything into the parent TSCSS node
> instead, then all the arrays here must stay index aligned as per slice
> mapping. Example DTS node looks like this (QDU1000, 3 slices):
> 
> ptp@1da0000 {
> 	compatible = "qcom,qdu1000-tscss";
> 	reg = <0x0 0x01da0000 0x0 0x2000>,
> 	      <0x0 0x01db0000 0x0 0x10000>;
> 	reg-names = "tsc", "etu";
> 	
> 	...
> 
> 	interrupts = <GIC_SPI 329 IRQ_TYPE_EDGE_RISING>,
> 		     <GIC_SPI 333 IRQ_TYPE_EDGE_RISING>,
> 		     <GIC_SPI 334 IRQ_TYPE_EDGE_RISING>;
> 	interrupt-names = "slice1", "slice5", "slice6";
> 	
> 	pinctrl-0 = <&tod_pps>;
> 	pinctrl-1 = <&gps_pps>;
> 	pinctrl-2 = <&hardsync_pps>;
> 	pinctrl-names = "slice1", "slice5", "slice6";
> 	
> 	qcom,etu-slice = <1 5 6>;
> 	qcom,etu-event-sel = <1 3 2>;

Why this is not continuous? The slices are all fixed in the hardware. I
don't get why do you list some of them.


Best regards,
Krzysztof
Re: [PATCH 1/6] dt-bindings: ptp: Document the TSCSS on Qualcomm Lemans and Monaco SoCs
#8124
Author: Imran Shaik
Date: Wed, 28 Oct 2026 04:54
78 lines
18600 bytes

On 27-10-2026 08:49 pm, Krzysztof Kozlowski wrote:
> On 26/10/2026 13:55, Imran Shaik wrote:
>>>
>>>>
>>>> On checking further, I found that our etu-slice sub node deviates from
>>>> that example, since we don't have a compatible string for the sub node.
>>>>
>>>> Please let me know if we should move the pinctrl properties under the
>>>> tscss node with per-slice names, or instead keep them under the
>>>> etu-slice sub node and add a compatible there.
>>>
>>> etu-slice does not feel like device at all unfortunately. I see only
>>> address space, so one resource, which might be enough but lack of
>>> description for the subnode is not helping. I have doubts that separate
>>> subnodes should be there in the first place, but if they stay, describe
>>> the child node fully - what sort of device it is. Just because there is
>>> independent timestamping counter does not make it separate device, just
>>> like independent interrupt in GIC is not itself an independent device.
>>>
>>
>> The ETU is an independent hardware block within TSCSS that captures/
> 
> How is it independent? I see no resources, except address space. A
> channel of some device does not mean it is a separate device.
> 

Sure, got it.

> 
>> snapshots the TSC timestamp in response to an external hardware
>> event trigger, for each slice individually. Hence the subnodes approach
>> was followed and will capture these details in the description as well.
>>
>> If we drop the subnodes and add everything into the parent TSCSS node
>> instead, then all the arrays here must stay index aligned as per slice
>> mapping. Example DTS node looks like this (QDU1000, 3 slices):
>>
>> ptp@1da0000 {
>> 	compatible = "qcom,qdu1000-tscss";
>> 	reg = <0x0 0x01da0000 0x0 0x2000>,
>> 	      <0x0 0x01db0000 0x0 0x10000>;
>> 	reg-names = "tsc", "etu";
>> 	
>> 	...
>>
>> 	interrupts = <GIC_SPI 329 IRQ_TYPE_EDGE_RISING>,
>> 		     <GIC_SPI 333 IRQ_TYPE_EDGE_RISING>,
>> 		     <GIC_SPI 334 IRQ_TYPE_EDGE_RISING>;
>> 	interrupt-names = "slice1", "slice5", "slice6";
>> 	
>> 	pinctrl-0 = <&tod_pps>;
>> 	pinctrl-1 = <&gps_pps>;
>> 	pinctrl-2 = <&hardsync_pps>;
>> 	pinctrl-names = "slice1", "slice5", "slice6";
>> 	
>> 	qcom,etu-slice = <1 5 6>;
>> 	qcom,etu-event-sel = <1 3 2>;
> 
> Why this is not continuous? The slices are all fixed in the hardware. I
> don't get why do you list some of them.
> 

The slices are fixed and contiguous in hardware (e.g. QDU1000 has 16 ETU
slices, 0-15), and accordingly will describe the bindings. But based on
vendor/target board requirements, the slice configuration can use all 16
or only a few, and might not be continuous.

If the board requirement is to get the external hardware event sourced
via certain GPIOs based on the availability, then accordingly, the ETU
slice and respective event sel needs to be configured. In the example,
slice 1, 5 and 6 are used to route TOD PPS, GPS PPS and hardsync PPS
pins respectively on QDU1000 SoC, and the remaining slices are not used.

Thanks,
Imran
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads