PMC-Sierra PM5358 S/UNI 4x622 Power Screwdriver User Manual


 
PM5358 S/UNI-4x622 Driver Manual
Software Architecture
Proprietary and Confidential to PMC-Sierra, Inc. 17
Document ID: PMC-2010419, Issue 1
Maximum number of devices
The DDB(s)
The Device Data-Block (DDB) is contained in the MDB, and initialized by the driver module for
each S/UNI-4x622 device that is registered. There is one DDB per device and there is a limit on
the number of DDBs, and that limit is set by the USER when the module is initialized. The DDB
is used to store context information about one device, such as:
Device state
Control information
Initialization parameters
Callback function pointers
Interrupt-Service Routine
The S/UNI-4x622 driver provides an ISR called suni4x622ISR that checks if there is any valid
interrupt condition present for the device. This function can be used by a system-specific
interrupt-handler function to service interrupts raised by the device.
The low-level interrupt-handler function that traps the hardware interrupt and calls
suni4x622ISR is system and RTOS dependent. Therefore, it is outside the scope of the driver.
Example implementations of an interrupt handler and functions that install and remove it are
provided as a reference in section 5.2. You can customize these example implementations to suit
your specific needs.
See section 2.5 for a detailed explanation of the ISR and interrupt-servicing model.
Deferred-Processing Routine
The S/UNI-4x622 driver provides a DPR called suni4x622DPR that processes any interrupt
condition gathered by the ISR for that device. Typically, a system specific function, which runs as
a separate task within the RTOS, will call
suni4x622DPR.
Example implementations of a DPR task and functions that install and remove it are provided as a
reference in section 5.2. You can customize these example implementations to suit your specific
needs.
See section 2.5 for a detailed explanation of the DPR and interrupt-servicing model.
Alarms, Status and Counts
The alarm, status and counts section is responsible for monitoring alarms, tracking devices status
information and retrieving counts for each device registered with (added to) the driver.