Sheetal Tigadoli 5de17f758a drivers:nvpps: Add support for configurable inital operating mode
Add support to select initial operating mode (GPIO or TIMER)
through DT property "nvpps-event-mode-init".

This allows users to specify which mode the driver should
start in rather than always defaulting to GPIO mode if gpios
property is specified in DT.

Key changes:
- Add DT property parsing for initial event mode
- Add validation to ensure selected mode is supported
- If this property is not specified, default mode selection
  happens based on if nvpps-gpios property is defined or not
- Add informative debug messages about selected mode
- Add error handling for invalid configurations(eg: init
  mode is GPIO but gpios property is not defined). If
  validation fails, probe returns error instead of
  defaulting to TIMER mode.

bug 5253938

Change-Id: I64c2a6565eeb46d6b07cf266cd4189fba9f0fba3
Signed-off-by: Sheetal Tigadoli <stigadoli@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3352704
(cherry picked from commit 091bb3ff50972e8dc3d7b941d850b4c1457b2a9e)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3361726
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
Reviewed-by: Sumeet Gupta <sumeetg@nvidia.com>
2025-07-24 10:20:35 +00:00
2022-12-07 23:57:14 -08:00
2025-07-24 10:19:10 +00:00
2024-02-24 05:24:07 -08:00
Description
No description provided
34 MiB