NVIDIA DriveOS Linux SDK API Reference

7.2.5.0 Early Access Release
NvSIPLGpioInterrupts.hpp
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: LicenseRef-NvidiaProprietary
4  *
5  * NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
6  * property and proprietary rights in and to this material, related
7  * documentation and any modifications thereto. Any use, reproduction,
8  * disclosure or distribution of this material and related documentation
9  * without an express license agreement from NVIDIA CORPORATION or
10  * its affiliates is strictly prohibited.
11  */
12 
13 #ifndef NVSIPLGPIOINTERRUPTS_HPP
14 #define NVSIPLGPIOINTERRUPTS_HPP
15 
16 #include <array>
17 #include <cstdint>
18 #include <optional>
19 
20 #include "NvSIPLCommon.hpp"
21 
30 namespace nvsipl
31 {
32 
44 static constexpr uint8_t MAX_GPIO_EVENT_DRIVER_RESULTS {16U};
45 
52 enum class SIPLGpioInterruptDisposition : std::uint8_t {
57  UNCLAIMED = 1U,
65  CLAIMED,
73  ERROR,
74 };
75 
82 enum class SIPLGpioResponderGMSLDeviceType : std::uint8_t {
84  UNKNOWN,
88  SERIALIZER,
90  SENSOR,
97 };
98 
105 enum class SIPLGpioResponderScope : std::uint8_t {
107  UNKNOWN = 0U,
109  AGGREGATOR,
111  PIPELINE,
112 };
113 
132  uint32_t deviceIndex {UINT32_MAX};
134  uint64_t event {0U};
136  std::optional<uint64_t> data {};
137 };
138 
147  uint32_t groupId {UINT32_MAX};
149  uint32_t gpioIdx {UINT32_MAX};
151  uint32_t pipelineIndex {UINT32_MAX};
155  uint32_t flags {0U};
157  uint8_t respondersConsulted {0U};
159  uint8_t numDriverResults {0U};
161  std::array<SIPLGpioDriverResult, MAX_GPIO_EVENT_DRIVER_RESULTS> driverResults {};
162 };
163 
166 } // namespace nvsipl
167 
168 
169 #endif // NVSIPLGPIOINTERRUPTS_HPP
nvsipl::SIPLGpioDriverResult::deviceType
SIPLGpioResponderGMSLDeviceType deviceType
Holds the GMSL device class that produced the result.
Definition: NvSIPLGpioInterrupts.hpp:124
nvsipl::SIPLGpioDriverResult::data
std::optional< uint64_t > data
Holds optional driver-defined compact data for this result.
Definition: NvSIPLGpioInterrupts.hpp:136
nvsipl::SIPLGpioEventInfo::driverResults
std::array< SIPLGpioDriverResult, MAX_GPIO_EVENT_DRIVER_RESULTS > driverResults
Holds reported ISR responder results for this GPIO event notification.
Definition: NvSIPLGpioInterrupts.hpp:161
nvsipl::SIPLGpioResponderGMSLDeviceType
SIPLGpioResponderGMSLDeviceType
Defines the GMSL device class that produced a GPIO interrupt result.
Definition: NvSIPLGpioInterrupts.hpp:82
nvsipl::SIPLGpioInterruptDisposition::ERROR
@ ERROR
Driver could not safely inspect the interrupt source.
nvsipl::SIPLGpioInterruptDisposition::UNCLAIMED
@ UNCLAIMED
Driver checked this responder's device and determined it is not the interrupt source.
nvsipl::SIPLGpioDriverResult::deviceIndex
uint32_t deviceIndex
Holds responder device index, or UINT32_MAX when not applicable.
Definition: NvSIPLGpioInterrupts.hpp:132
nvsipl::SIPLGpioInterruptDisposition
SIPLGpioInterruptDisposition
Defines the driver response to a GPIO interrupt.
Definition: NvSIPLGpioInterrupts.hpp:52
nvsipl::SIPLGpioDriverResult::scope
SIPLGpioResponderScope scope
Holds whether the result is aggregator-level or pipeline-scoped.
Definition: NvSIPLGpioInterrupts.hpp:126
nvsipl::SIPLGpioEventInfo::flags
uint32_t flags
Holds the aggregated NVSIPL_GPIO_DEVICE_* source flags.
Definition: NvSIPLGpioInterrupts.hpp:155
nvsipl::SIPLGpioEventInfo::pipelineIndex
uint32_t pipelineIndex
Holds the pipeline index that received this notification.
Definition: NvSIPLGpioInterrupts.hpp:151
nvsipl::SIPLGpioResponderScope::UNKNOWN
@ UNKNOWN
Scope is unknown.
nvsipl::SIPLGpioResponderGMSLDeviceType::UNKNOWN
@ UNKNOWN
Device class is unknown.
NvSIPLCommon.hpp
NVIDIA SIPL: Common Data Structures - NvSIPL
nvsipl::SIPLGpioResponderGMSLDeviceType::SERIALIZER
@ SERIALIZER
GPIO source is a serializer.
nvsipl::SIPLGpioEventInfo::respondersConsulted
uint8_t respondersConsulted
Holds the number of ISR responders consulted for this event.
Definition: NvSIPLGpioInterrupts.hpp:157
nvsipl::SIPLGpioResponderScope
SIPLGpioResponderScope
Defines the scope of a GPIO responder result.
Definition: NvSIPLGpioInterrupts.hpp:105
nvsipl::SIPLGpioResponderGMSLDeviceType::MODULE_OTHER
@ MODULE_OTHER
GPIO source is another module-local device.
nvsipl::SIPLGpioEvent
SIPLGpioEvent
CDAC GPIO event codes.
Definition: NvSIPLCommon.hpp:203
nvsipl::MAX_GPIO_EVENT_DRIVER_RESULTS
static constexpr uint8_t MAX_GPIO_EVENT_DRIVER_RESULTS
Indicates the maximum number of GPIO driver results returned for one GPIO event notification.
Definition: NvSIPLGpioInterrupts.hpp:44
nvsipl::SIPLGpioDriverResult
Describes one driver result from GPIO interrupt responder handling.
Definition: NvSIPLGpioInterrupts.hpp:120
nvsipl::SIPLGpioResponderScope::AGGREGATOR
@ AGGREGATOR
Result is produced by a group-level aggregator.
nvsipl::SIPLGpioResponderGMSLDeviceType::DESERIALIZER_POWER
@ DESERIALIZER_POWER
GPIO source is a deserializer power device.
nvsipl::SIPLGpioInterruptDisposition::CLAIMED
@ CLAIMED
Driver confirmed this responder's device is the interrupt source.
nvsipl::SIPLGpioEventInfo::groupId
uint32_t groupId
Holds the GPIO group, normally the GMSL transport I2C bus.
Definition: NvSIPLGpioInterrupts.hpp:147
nvsipl::SIPLGpioInterruptDisposition::CLAIMED_NEEDS_DIAGNOSTIC
@ CLAIMED_NEEDS_DIAGNOSTIC
Driver confirmed this responder's device is the interrupt source and recommends querying the existing...
nvsipl::SIPLGpioEventInfo
Describes GPIO event information carried by a pipeline notification.
Definition: NvSIPLGpioInterrupts.hpp:145
nvsipl::SIPLGpioResponderGMSLDeviceType::DESERIALIZER
@ DESERIALIZER
GPIO source is the deserializer.
nvsipl::SIPLGpioResponderGMSLDeviceType::SENSOR
@ SENSOR
GPIO source is a sensor.
nvsipl::SIPLGpioResponderGMSLDeviceType::MODULE_POWER
@ MODULE_POWER
GPIO source is a module power device.
nvsipl::SIPLGpioEventInfo::numDriverResults
uint8_t numDriverResults
Holds the number of valid reported entries in driverResults.
Definition: NvSIPLGpioInterrupts.hpp:159
nvsipl
Describes the custom interface for IMX623.
Definition: AR0820_CUST1_CustomInterface.hpp:21
nvsipl::NVSIPL_GPIO_EVENT_NOTHING
@ NVSIPL_GPIO_EVENT_NOTHING
There is no pending event.
Definition: NvSIPLCommon.hpp:206
nvsipl::SIPLGpioResponderScope::PIPELINE
@ PIPELINE
Result applies to the pipeline that received the notification.
nvsipl::SIPLGpioEventInfo::gpioIdx
uint32_t gpioIdx
Holds the GPIO index from the platform configuration.
Definition: NvSIPLGpioInterrupts.hpp:149
nvsipl::SIPLGpioDriverResult::disposition
SIPLGpioInterruptDisposition disposition
Holds the driver disposition for this GPIO interrupt source.
Definition: NvSIPLGpioInterrupts.hpp:122