General-purpose I/O (GPIO) controllers

The general-purpose I/O (GPIO) controller driver communicates with the GPIO framework extension (GpioClx) through the GpioClx device-driver interface (DDI). This DDI is defined in the Gpioclx.h header file and is described in this section. As part of this DDI, GpioClx implements several driver support methods, which are called by the GPIO controller driver. This driver implements a set of event callback functions, which are called by GpioClx. GpioClx uses these callbacks to manage interrupt requests from GPIO pins that are configured as interrupt inputs, and to transfer data to or from GPIO pins that are configured as data inputs and outputs.

For conceptual information about writing GPIOClx client drivers, see General-Purpose I/O (GPIO) Driver Design Guide

IOCTLs

Title Description
IOCTL_GPIO_CONTROLLER_SPECIFIC_FUNCTION The IOCTL_GPIO_CONTROLLER_SPECIFIC_FUNCTION I/O control code enables a client of the general-purpose I/O (GPIO) controller to request a controller-specific device-control operation.
IOCTL_GPIO_READ_PINS The IOCTL_GPIO_READ_PINS I/O control code enables a client of the general-purpose I/O (GPIO) controller to read from a set of GPIO pins that are configured as inputs.
IOCTL_GPIO_WRITE_PINS The IOCTL_GPIO_WRITE_PINS I/O control code enables a client of the general-purpose I/O (GPIO) controller to write to a set of GPIO pins that are configured as outputs.

Enumerations

Title Description
_CLIENT_CONTROLLER_QUERY_SET_REQUEST_TYPE The CLIENT_CONTROLLER_QUERY_SET_REQUEST_TYPE enumeration type indicates what type of attribute information the GPIO framework extension (GpioClx) is requesting from the GPIO controller driver.
_GPIO_CONNECT_IO_PINS_MODE The GPIO_CONNECT_IO_PINS_MODE enumeration indicates whether a set of general-purpose I/O (GPIO) pins is configured as inputs or outputs.

Functions

Title Description
GPIO_CLIENT_CLEAR_ACTIVE_INTERRUPTS The CLIENT_ClearActiveInterrupts event callback function clears active interrupts on a set of general-purpose I/O (GPIO) pins that are configured as interrupt inputs.
GPIO_CLIENT_CONNECT_IO_PINS The CLIENT_ConnectIoPins event callback function opens a logical connection to a set of general-purpose I/O (GPIO) pins and configures these pins for data read or write operations.
GPIO_CLIENT_CONTROLLER_SPECIFIC_FUNCTION The CLIENT_ControllerSpecificFunction event callback function performs an operation that is specific to a particular general-purpose I/O (GPIO) controller.
GPIO_CLIENT_DISABLE_INTERRUPT The CLIENT_DisableInterrupt event callback function disables interrupts on a general-purpose I/O (GPIO) pin that is configured as an interrupt input.
GPIO_CLIENT_DISCONNECT_IO_PINS The CLIENT_DisconnectIoPins event callback function closes a logical connection to a set of general-purpose I/O (GPIO) pins that are configured for data read or write operations.
GPIO_CLIENT_ENABLE_INTERRUPT The CLIENT_EnableInterrupt event callback function enables interrupts on a general-purpose I/O (GPIO) pin that is configured as an interrupt input.
GPIO_CLIENT_MASK_INTERRUPTS The CLIENT_MaskInterrupts event callback function masks interrupts on a set of general-purpose I/O (GPIO) pins that are configured as interrupt inputs.
GPIO_CLIENT_PRE_PROCESS_CONTROLLER_INTERRUPT The CLIENT_PreProcessControllerInterrupt event callback function performs any pre-processing of a general-purpose I/O (GPIO) interrupt that must be done immediately if the ISR is scheduled to run at a later time.
GPIO_CLIENT_PREPARE_CONTROLLER The CLIENT_PrepareController event callback function performs any operations that are needed to make the general-purpose I/O (GPIO) controller ready to be accessed by the GPIO controller driver.
GPIO_CLIENT_QUERY_ACTIVE_INTERRUPTS The CLIENT_QueryActiveInterrupts event callback function queries the state of a set of general-purpose I/O (GPIO) pins that are configured as interrupt inputs.
GPIO_CLIENT_QUERY_CONTROLLER_BASIC_INFORMATION The CLIENT_QueryControllerBasicInformation event callback function retrieves the hardware attributes of the general-purpose I/O (GPIO) controller.
GPIO_CLIENT_QUERY_ENABLED_INTERRUPTS The CLIENT_QueryEnabledInterrupts event callback function queries the state of a set of general-purpose I/O (GPIO) pins to determine which pins are both configured as interrupt inputs and enabled for interrupts.
GPIO_CLIENT_QUERY_SET_CONTROLLER_INFORMATION The CLIENT_QuerySetControllerInformation event callback function queries the general-purpose I/O (GPIO) controller driver for the specified set of attributes of the GPIO controller.
GPIO_CLIENT_READ_PINS The CLIENT_ReadGpioPins event callback function reads a set of general-purpose I/O (GPIO) pins that are configured as data inputs.
GPIO_CLIENT_READ_PINS_MASK The CLIENT_ReadGpioPinsUsingMask event callback function reads a bank of general-purpose I/O (GPIO) pins.
GPIO_CLIENT_RECONFIGURE_INTERRUPT The CLIENT_ReconfigureInterrupt event callback function reconfigures a general-purpose I/O (GPIO) pin that is used as an interrupt input.
GPIO_CLIENT_RELEASE_CONTROLLER The CLIENT_ReleaseController event callback function performs operations that are needed when the general-purpose I/O (GPIO) controller device is no longer accessible.
GPIO_CLIENT_RESTORE_BANK_HARDWARE_CONTEXT The CLIENT_RestoreBankHardwareContext event callback function restores the hardware context of a bank of general-purpose I/O (GPIO) pins.
GPIO_CLIENT_SAVE_BANK_HARDWARE_CONTEXT The CLIENT_SaveBankHardwareContext event callback function saves the hardware context of a bank of general-purpose I/O (GPIO) pins.
GPIO_CLIENT_START_CONTROLLER The CLIENT_StartController event callback function performs operations that are needed when the general-purpose I/O (GPIO) controller device enters the D0 power state.
GPIO_CLIENT_STOP_CONTROLLER The CLIENT_StopController event callback function performs operations that are needed to prepare the general-purpose I/O (GPIO) controller device to exit the D0 power state.
GPIO_CLIENT_UNMASK_INTERRUPT The CLIENT_UnmaskInterrupt event callback function unmasks the interrupt on a general-purpose I/O (GPIO) pin that is configured as an interrupt input.
GPIO_CLIENT_WRITE_PINS The CLIENT_WriteGpioPins event callback function writes to a set of general-purpose I/O (GPIO) pins that are configured as data outputs.
GPIO_CLIENT_WRITE_PINS_MASK The CLIENT_WriteGpioPinsUsingMask event callback function writes to a set of general-purpose I/O (GPIO) pins that are configured as data outputs.
GPIO_CLX_AcquireInterruptLock The GPIO_CLX_AcquireInterruptLock method acquires an interrupt lock on a bank of pins in the general-purpose I/O (GPIO) controller.
GPIO_CLX_ProcessAddDevicePostDeviceCreate The GPIO_CLX_ProcessAddDevicePostDeviceCreate method passes a framework device object to the GPIO framework extension (GpioClx).
GPIO_CLX_ProcessAddDevicePreDeviceCreate The GPIO_CLX_ProcessAddDevicePreDeviceCreate method loads initialization information into two structures that are passed as input parameters to the WdfDeviceCreate method.
GPIO_CLX_RegisterClient The GPIO_CLX_RegisterClient method registers a general-purpose I/O (GPIO) controller driver as a client of the GPIO framework extension (GpioClx).
GPIO_CLX_ReleaseInterruptLock The GPIO_CLX_ReleaseInterruptLock method releases an interrupt lock on the specified bank.
GPIO_CLX_UnregisterClient The GPIO_CLX_UnregisterClient method removes a general-purpose I/O (GPIO) controller driver's registration with the GPIO framework extension (GpioClx).

Structures

Title Description
_CLIENT_CONTROLLER_BASIC_INFORMATION The CLIENT_CONTROLLER_BASIC_INFORMATION structure contains general-purpose I/O (GPIO) controller hardware attributes and configuration information.
_CLIENT_CONTROLLER_QUERY_SET_INFORMATION_INPUT The CLIENT_CONTROLLER_QUERY_SET_INFORMATION_INPUT structure contains a request for the hardware attributes of the general-purpose I/O (GPIO) controller.
_CLIENT_CONTROLLER_QUERY_SET_INFORMATION_OUTPUT The CLIENT_CONTROLLER_QUERY_SET_INFORMATION_OUTPUT structure contains a set of general-purpose I/O (GPIO) controller attributes that were requested by the GPIO framework extension (GpioClx).
_CLIENT_QUERY_BANK_POWER_INFORMATION_OUTPUT The CLIENT_QUERY_BANK_POWER_INFORMATION_OUTPUT structure contains information about the power-management capabilities of a bank of general-purpose I/O (GPIO) pins.
_CONTROLLER_ATTRIBUTE_FLAGS The CONTROLLER_ATTRIBUTE_FLAGS structure describes the hardware attributes of the general-purpose I/O (GPIO) controller device.
_GPIO_CLEAR_ACTIVE_INTERRUPTS_PARAMETERS The GPIO_CLEAR_ACTIVE_INTERRUPTS_PARAMETERS structure describes a set of general-purpose I/O (GPIO) interrupt pins to clear.
_GPIO_CLIENT_CONTROLLER_SPECIFIC_FUNCTION_PARAMETERS The GPIO_CLIENT_CONTROLLER_SPECIFIC_FUNCTION_PARAMETERS structure describes the input and output buffers for a controller-specific operation.
_GPIO_CLIENT_REGISTRATION_PACKET The GPIO_CLIENT_REGISTRATION_PACKET structure contains registration information that the general-purpose I/O (GPIO) controller driver passes to the GPIO framework extension (GpioClx).
_GPIO_CONNECT_IO_PINS_PARAMETERS The GPIO_CONNECT_IO_PINS_PARAMETERS structure describes a logical connection to a set of general-purpose I/O (GPIO) pins and specifies whether to configure these pins as data inputs or outputs.
_GPIO_DISABLE_INTERRUPT_PARAMETERS The GPIO_DISABLE_INTERRUPT_PARAMETERS structure describes a general-purpose I/O (GPIO) interrupt pin to disable.
_GPIO_DISCONNECT_IO_PINS_PARAMETERS The GPIO_DISCONNECT_IO_PINS_PARAMETERS structure describes a set of general-purpose I/O (GPIO) pins that are to be disconnected.
_GPIO_ENABLE_INTERRUPT_PARAMETERS The GPIO_ENABLE_INTERRUPT_PARAMETERS structure specifies a general-purpose I/O (GPIO) pin and describes the interrupt attributes of this pin.
_GPIO_MASK_INTERRUPT_PARAMETERS The GPIO_MASK_INTERRUPT_PARAMETERS structure describes a set of general-purpose I/O (GPIO) interrupt pins to mask.
_GPIO_QUERY_ACTIVE_INTERRUPTS_PARAMETERS The GPIO_QUERY_ACTIVE_INTERRUPTS_PARAMETERS structure describes a set of general-purpose I/O (GPIO) interrupt pins to query for their enabled and active states.
_GPIO_QUERY_ENABLED_INTERRUPTS_PARAMETERS The GPIO_QUERY_ENABLED_INTERRUPTS_PARAMETERS structure indicates which interrupt pins in a bank of general-purpose I/O (GPIO) pins are enabled.
_GPIO_READ_PINS_MASK_PARAMETERS The GPIO_READ_PINS_MASK_PARAMETERS structure describes a read operation on a bank of general-purpose I/O (GPIO) pins.
_GPIO_READ_PINS_PARAMETERS The GPIO_READ_PINS_PARAMETERS structure describes a read operation on a group of general-purpose I/O (GPIO) pins.
_GPIO_RECONFIGURE_INTERRUPTS_PARAMETERS The GPIO_RECONFIGURE_INTERRUPTS_PARAMETERS structure describes the general-purpose I/O (GPIO) interrupt pin to reconfigure.
_GPIO_SAVE_RESTORE_BANK_HARDWARE_CONTEXT_PARAMETERS The GPIO_SAVE_RESTORE_BANK_HARDWARE_CONTEXT_PARAMETERS structure describes a bank of general-purpose I/O (GPIO) pins whose hardware state is to be saved or restored.
_GPIO_WRITE_PINS_MASK_PARAMETERS The GPIO_WRITE_PINS_MASK_PARAMETERS structure describes a write operation on a bank of general-purpose I/O (GPIO) pins.
_GPIO_WRITE_PINS_PARAMETERS The GPIO_WRITE_PINS_PARAMETERS structure describes a write operation on a group of general-purpose I/O (GPIO) pins.