-
Notifications
You must be signed in to change notification settings - Fork 146
Add support for Qualcomm TSCSS hardware #656
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
imrashai
wants to merge
4
commits into
qualcomm-linux:qcom-6.18.y
Choose a base branch
from
imrashai:lemans-tsc-support
base: qcom-6.18.y
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+993
−0
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
994ed4e
PENDING: dt-bindings: ptp: Add support for Qualcomm TSCSS module
imrashai dfcce5b
PENDING: ptp: Add support for Qualcomm TSCSS hardware
imrashai 7086bb1
PENDING: arm64: configs: Enable Qualcomm TSCSS driver support
imrashai 6f2e58c
PENDING: arm64: dts: qcom: lemans: Add support to enable TSC node
imrashai File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,104 @@ | ||
| # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) | ||
| %YAML 1.2 | ||
| --- | ||
| $id: http://devicetree.org/schemas/ptp/qcom,tsc.yaml# | ||
| $schema: http://devicetree.org/meta-schemas/core.yaml# | ||
|
|
||
| title: Qualcomm Timestamp Counter Subsystem (TSCSS) | ||
|
|
||
| maintainers: | ||
| - Imran Shaik <imran.shaik@oss.qualcomm.com> | ||
| - Taniya Das <taniya.das@oss.qualcomm.com> | ||
|
|
||
| description: | ||
| Qualcomm TSCSS is a time synchronization subsystem composed of two main | ||
| blocks - the Time Stamp Counter (TSC) and the Event Timestamp Unit (ETU). | ||
|
|
||
| The TSC block is a timestamp generator that maintains a running counter used | ||
| for system timekeeping. The ETU block captures timestamps for external events | ||
| using one of the available timestamp sources. | ||
|
|
||
| properties: | ||
| compatible: | ||
| enum: | ||
| - qcom,tsc | ||
|
|
||
| reg: | ||
| maxItems: 2 | ||
|
|
||
| reg-names: | ||
| items: | ||
| - const: tsc | ||
| - const: etu | ||
|
|
||
| clocks: | ||
| items: | ||
| - description: TSC AHB clock | ||
| - description: TSC cntr clock | ||
| - description: TSC ETU clock | ||
|
|
||
| clock-names: | ||
| items: | ||
| - const: cfg_ahb | ||
| - const: cntr | ||
| - const: etu | ||
|
|
||
| interrupts: | ||
| maxItems: 1 | ||
|
|
||
| interrupt-names: | ||
| items: | ||
| - const: etu_summary_irq | ||
|
|
||
| qcom,tsc-nsec-update: | ||
| description: | ||
| Indicates the TSC counters have values in nanoseconds, rather than | ||
| in secs and nanoseconds. | ||
| type: boolean | ||
|
|
||
| qcom,etu-slice: | ||
| $ref: /schemas/types.yaml#/definitions/uint32-array | ||
| description: | ||
| Array of ETU slice numbers corresponding to the ETU sel. | ||
| In case this property is not defined the sel number will be | ||
| considered as the slice number for ETU offset calculation. | ||
|
|
||
| qcom,etu-event-sel: | ||
| $ref: /schemas/types.yaml#/definitions/uint32-array | ||
| description: | ||
| Array of ETU event sel numbers for the corresponding ETU slice | ||
| numbers. | ||
|
|
||
| qcom,etu-event-names: | ||
| $ref: /schemas/types.yaml#/definitions/string-array | ||
| description: | ||
| ETU event sel names for the corresponding event sel numbers. | ||
|
|
||
| required: | ||
| - compatible | ||
| - reg | ||
| - clocks | ||
| - clock-names | ||
| - interrupts | ||
| - interrupt-names | ||
|
|
||
| additionalProperties: false | ||
|
|
||
| examples: | ||
| - | | ||
| #include <dt-bindings/interrupt-controller/arm-gic.h> | ||
| tsc: tsc@1c80000 { | ||
| compatible = "qcom,tsc"; | ||
| reg = <0x01c80000 0x2000>, | ||
| <0x01ca0000 0x20000>; | ||
| reg-names = "tsc", "etu"; | ||
| clocks = <&tscss_ahb_clock>, <&tscss_cntr_clock>, | ||
| <&tscss_cntr_clock>; | ||
| clock-names = "cfg_ahb", "cntr", "etu"; | ||
| interrupts = <GIC_SPI 766 IRQ_TYPE_EDGE_RISING>; | ||
| interrupt-names = "etu_summary_irq"; | ||
| qcom,etu-slice = <10 11>; | ||
| qcom,etu-event-sel = <10 11>; | ||
| qcom,etu-event-names = "gps_pps", "tod_pps"; | ||
| qcom,tsc-nsec-update; | ||
| }; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5660,6 +5660,14 @@ | |
| bias-disable; | ||
| }; | ||
|
|
||
| /* CCI async input GPIOs */ | ||
| cci_async_default: cci-async-state { | ||
| pins = "gpio68", "gpio69"; | ||
| function = "cci_async"; | ||
| drive-strength = <2>; | ||
| bias-disable; | ||
| }; | ||
|
|
||
| cci0_0_default: cci0-0-default-state { | ||
| pins = "gpio60", "gpio61"; | ||
| function = "cci_i2c"; | ||
|
|
@@ -9237,4 +9245,32 @@ | |
|
|
||
| status = "disabled"; | ||
| }; | ||
|
|
||
| tsc@1c80000 { | ||
| compatible = "qcom,tsc"; | ||
| reg = <0x0 0x01c80000 0x0 0x2000>, | ||
| <0x0 0x01c90000 0x0 0x10000>; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. reg-names ?
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Updated now. |
||
| reg-names = "tsc", "etu"; | ||
|
|
||
| clocks = <&gcc GCC_TSCSS_AHB_CLK>, | ||
| <&gcc GCC_TSCSS_GLOBAL_CNTR_CLK>, | ||
| <&gcc GCC_TSCSS_ETU_CLK>; | ||
| clock-names = "cfg_ahb", "cntr", "etu"; | ||
|
|
||
| assigned-clocks = <&gcc GCC_TSCSS_GLOBAL_CNTR_CLK>, | ||
| <&gcc GCC_TSCSS_ETU_CLK>; | ||
| assigned-clock-rates = <15625000>, <15625000>; | ||
|
|
||
| qcom,tsc-nsec-update; | ||
|
|
||
| interrupts = <GIC_SPI 766 IRQ_TYPE_EDGE_RISING>; | ||
| interrupt-names = "etu_summary_irq"; | ||
|
|
||
| qcom,etu-slice = <10 11>; | ||
| qcom,etu-event-sel = <10 11>; | ||
| qcom,etu-event-names = "gps_pps", "tod_pps"; | ||
|
|
||
| pinctrl-names = "default"; | ||
| pinctrl-0 = <&cci_async_default>; | ||
| }; | ||
| }; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't interrupt-names also be required.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added interrupts also to the required list.