Hello All,
My work is to develop EPICS drivers for some
CPCI devices, which will communicate with CPU by interrupt.
I have a question about the difference between
VxWorks function intConnect() and pciIntConnect(). Now I use VME and PMC
devices for learning, my CPU board is MVME5100, the CPU is MPC750, the system
interrupt controller is Hawk MPIC, and the VxWorks is 5.5.1.
VxWorks manual said intConnect() connects a
specified C routine to a specified interrupt
vector and pciIntConnect() connects an interrupt handler to a shared
PCI interrupt vector, which means that intConnect() only connect one ISR to
one interrupt vector while pciIntConnect() can connect multiple ISRs
to the same interrupt vector. I can not find the definition of these two
functions, but in my VxWorks BSP, some code fragment is as
follows:
In sysMpicInit():
excIntConnect
((VOIDFUNCPTR *) _EXC_OFF_INTR, sysMpicIntHandler);
_func_intConnectRtn = sysMpicIntConnect;
In sysMpicIntConnect():
newHandler->vec = routine;
newHandler->arg = parameter;
newHandler->next = NULL;
if
(sysIntTbl[(int) vector] == NULL)
sysIntTbl [(int ) vector] = newHandler; /* single int. handler case
*/
else
{ currHandler = sysIntTbl[(int)
vector]; /* multiple int. handler case
*/ while (currHandler->next !=
NULL)
{
currHandler =
currHandler->next;
} currHandler->next =
newHandler; }
Some documents said that intConnect() calls
_func_intConnectRtn(), so it seem that sysMpicIntConnect() also manage a
link list for multiple ISRs that shared the same interrupt vector, i.e.
intConnect() can also connect multiple ISRs to one interrupt vector. So, I
can not understand what is the difference between intConnect() and
pciIncConnect().
Thanks,
Lin Wang
|