From 148c895a232662b79a5b7c16a6af5af4e712fad4 Mon Sep 17 00:00:00 2001 From: Sheetal Tigadoli Date: Wed, 30 Apr 2025 17:35:33 +0000 Subject: [PATCH] dt-bindings:nvpps:Document property to set initial operating mode Add documentation for the new 'nvpps-event-mode-init' property in the NVIDIA nvpps driver devicetree bindings. This optional property allows users to specify whether the driver should start in GPIO mode (1) or TIMER mode (2). If not specified then default mode is chosen based on if the nvpps-gpios property is defined or not. bug 5253938 Change-Id: I624e50458383a5a61efdb4d5dd790b4a1dc7bb7e Signed-off-by: Sheetal Tigadoli Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3352703 (cherry picked from commit 3e3c946b6b0122b5cb9afe4f3150301c7f64b3a0) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3361725 Reviewed-by: Sumeet Gupta GVS: buildbot_gerritrpt --- Documentation/devicetree/bindings/nvpps/nvpps.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Documentation/devicetree/bindings/nvpps/nvpps.txt b/Documentation/devicetree/bindings/nvpps/nvpps.txt index 805766d7..73864045 100644 --- a/Documentation/devicetree/bindings/nvpps/nvpps.txt +++ b/Documentation/devicetree/bindings/nvpps/nvpps.txt @@ -47,6 +47,11 @@ Optional properties: Valid range is from 100ms to 1000ms. This property determines how often the driver collects timestamp data. If this property is not specified, the driver will collect timestamps every 1000ms(1s) by default. +- nvpps-event-mode-init: Optional property that specifies the initial operating mode of the NvPPS driver. + Valid values are 1 (GPIO mode) and 2 (TIMER mode). If this property is not + specified, the default mode is determined based on the presence of the + nvpps-gpios property - GPIO mode becomes the default when nvpps-gpios is + specified, otherwise TIMER mode is used as the default. Example: Timer mode on Orin. @@ -100,6 +105,7 @@ nvpps { nvpps-gpios = <&gpio_aon TEGRA234_AON_GPIO(BB, 0) GPIO_ACTIVE_HIGH>; timestamps = <&hte_aon TEGRA234_AON_GPIO(BB, 0)>; timestamp-names = "nvpps_gpio"; + nvpps-event-mode-init = <1>; /* 1 for GPIO mode, 2 for TIMER mode */ }; @@ -117,4 +123,5 @@ nvpps { ptp_tsc_lock_threshold = /bits/ 16 <0x26C>; ptp_tsc_sync_dis; ts-capture-interval = <1000>; + nvpps-event-mode-init = <2>; /* 1 for GPIO mode, 2 for TIMER mode */ };