Skip Navigation Links | |
Exit Print View | |
man pages section 9: DDI and DKI Kernel Functions Oracle Solaris 11.1 Information Library |
csx_AccessConfigurationRegister(9F)
csx_Parse_CISTPL_BYTEORDER(9F)
csx_Parse_CISTPL_CFTABLE_ENTRY(9F)
csx_Parse_CISTPL_DEVICEGEO(9F)
csx_Parse_CISTPL_DEVICEGEO_A(9F)
csx_Parse_CISTPL_DEVICE_OA(9F)
csx_Parse_CISTPL_DEVICE_OC(9F)
csx_Parse_CISTPL_LINKTARGET(9F)
csx_Parse_CISTPL_LONGLINK_A(9F)
csx_Parse_CISTPL_LONGLINK_C(9F)
csx_Parse_CISTPL_LONGLINK_MFC(9F)
ddi_get_soft_iblock_cookie(9F)
ddi_intr_get_supported_types(9F)
ddi_prop_lookup_byte_array(9F)
ddi_prop_lookup_int64_array(9F)
ddi_prop_lookup_string_array(9F)
ddi_prop_update_byte_array(9F)
ddi_prop_update_int64_array(9F)
ddi_prop_update_string_array(9F)
ldi_prop_lookup_byte_array(9F)
ldi_prop_lookup_int64_array(9F)
ldi_prop_lookup_string_array(9F)
mac_prop_info_set_default_link_flowctrl(9F)
mac_prop_info_set_default_str(9F)
mac_prop_info_set_default_uint8(9F)
mac_prop_info_set_range_uint32(9F)
net_event_notify_unregister(9F)
net_instance_notify_register(9F)
net_instance_notify_unregister(9F)
net_instance_protocol_unregister(9F)
net_protocol_notify_register(9F)
nvlist_lookup_boolean_array(9F)
nvlist_lookup_boolean_value(9F)
nvlist_lookup_nvlist_array(9F)
nvlist_lookup_string_array(9F)
nvlist_lookup_uint16_array(9F)
nvlist_lookup_uint32_array(9F)
nvlist_lookup_uint64_array(9F)
nvpair_value_boolean_array(9F)
pci_plist_lookup_int16_array(9F)
pci_plist_lookup_int32_array(9F)
pci_plist_lookup_int64_array(9F)
pci_plist_lookup_int8_array(9F)
pci_plist_lookup_string_array(9F)
pci_plist_lookup_uint16_array(9F)
pci_plist_lookup_uint32_array(9F)
pci_plist_lookup_uint64_array(9F)
pci_plist_lookup_uint8_array(9F)
scsi_get_device_type_scsi_options(9F)
scsi_get_device_type_string(9F)
scsi_sense_cmdspecific_uint64(9F)
usb_get_current_frame_number(9F)
usb_get_max_pkts_per_isoc_request(9F)
usb_pipe_get_max_bulk_transfer_size(9F)
usb_pipe_stop_intr_polling(9F)
usb_pipe_stop_isoc_polling(9F)
- return number of interrupts supported or available for a given interrupt type
#include <sys/types.h> #include <sys/conf.h> #include <sys/ddi.h> #include <sys/sunddi.h> int ddi_intr_get_nintrs(dev_info_t *dip, int type, int *nintrsp);
int ddi_intr_get_navail(dev_info_t *dip, int type, int *navailp);
Solaris DDI specific (Solaris DDI).
ddi_intr_get_nintrs()
Pointer to dev_info structure
Interrupt type
Pointer to number of interrupts of the given type that are supported by the system
ddi_intr_get_navail()
Pointer to dev_info structure
Interrupt type
Pointer to number of interrupts of the given type that are currently available from the system
The ddi_intr_get_nintrs() function returns the number of interrupts of the given type supported by a particular hardware device. On a successful return, the number of supported interrupts is returned as an integer pointed to by the nintrsp argument.
If the hardware device is not found to support any interrupts of the given type, the DDI_INTR_NOTFOUND failure is returned rather than a zero in nintrsp.
The ddi_intr_get_navail() function returns the number of interrupts of a given type that is available to a particular hardware device. On a successful return, the number of available interrupts is returned as an integer pointed to by navailp.
The hardware device may support more than one interrupt and can request that all interrupts be allocated. The host software can then use policy-based decisions to determine how many interrupts are made available to the device. Based on the determination, a value is returned that should be used to allocate interrupts with the ddi_int_alloc() function.
The ddi_intr_get_supported_types(9F) function returns a list of valid supported types for the given hardware device. It must be called prior to calling either the ddi_intr_get_nintrs() or ddi_intr_get_navail().
The ddi_intr_get_nintrs() and ddi_intr_get_navail() functions return:
On success.
On encountering invalid input parameters.
On not finding any interrupts for the given interrupt type.
On any implementation specific failure.
The ddi_intr_get_nintrs() and ddi_intr_get_navail() functions can be called from either user or kernel non-interrupt context.
See attributes(5) for descriptions of the following attributes:
|
attributes(5), ddi_intr_alloc(9F), ddi_intr_enable(9F), ddi_intr_get_supported_types(9F)
The ddi_intr_get_nintrs() and ddi_intr_get_navail() functions can be called at any time, even if the driver has added an interrupt handler for a given interrupt specification.
On x86 platforms, the number of interrupts returned by the ddi_intr_get_navail() function might need to be further reduced by the number of interrupts available for each interrupt priority on the system. In that case, drivers should use different priorities for some of the interrupts.
Consumers of these interfaces should verify that the return value is not equal to DDI_SUCCESS. Incomplete checking for failure codes could result in inconsistent behavior among platforms.