DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

udi_intr_handler_ops_t(3udi)


Interrupt handler ops vector

SYNOPSIS

#include <udi.h>

typedef const struct {

	udi_channel_event_ind_op_t *channel_event_ind_op;

	udi_intr_event_ind_op_t *intr_event_ind_op;

} udi_intr_handler_ops_t;
 
/* Interrupt Handler Ops Vector Number */
 
#define  UDI_BUS_INTR_HANDLER_OPS_NUM				3
 

DESCRIPTION A driver which wishes to register for handling interrupts (as opposed to "dispatching" interrupts declares the udi_intr_handler_ops_t structure to define its entry point for receiving interrupt events.

REFERENCES udi_init_info, udi_ops_init_t, udi_intr_dispatcher_ops_t

EXAMPLE The driver's initialization structure definitions might include the following:

#define MY_INTR_HANDLER_OPS 2 /* My interrupt handler ops */

#define MY_BUS_META 1 /* Meta index for the Bus Bridge Metalanguage */

static udi_intr_handler_ops_t

	ddd_intr_handler_ops = {

		ddd_intr_handler_channel_event_ind,

		ddd_intr_event_ind

	};

...

static udi_ops_init_t ddd_ops_init_list[] = {

	{	MY_INTR_HANDLER_OPS,

		MY_BUS_META,

		UDI_BUS_INTR_HANDLER_OPS_NUM,

		0, /* chan_context_size */

		(udi_ops_vector_t *)&ddd_intr_handler_ops },

	{ 0 }

};
 

UDI Physical I/O Specification Contents