I have a driver which supports the cPCI board. It has shared memory
contains buffers, queues, etc. Sometimes the firmware on
this board is hanging without any symptoms. So we decided to unpower it
our hotswap controller and then power it back, initialize the
PCI configuration and then start using it again. (I don’t know why but
sometimes “reset” does not work. Looks like the firmware dies completely
and does not handle anything).
Driver has two threads: one is handling the “client requests” by
library, and second handles events from interrupt handler[s]. (I’m not
INTR event because the driver supports many boards and i’m using event
specify which board).
But i have some strange situation here. When i powered back the board i
that “interrupt handling” thread (not handler itself=) ) can’t get
it gets “No such channel” error code (errno), and values of channel id
correct. Sometimes “communication/dispatch” thread starts handle same
as it got last time (forever) - this looks almost same if dispatch
does not detect “wrong channel number”. ( just for experts: i’m using
resmgr_block function and check for NULL, but it’s not).
May be i have a bug in interrupt handler - i check if the interrupt
was mine (IN THAT SHARED MEMORY), and if it was mine - i clear it). So,
may be this “clearing” is my problem. It device is unplugged (or
this physical memory is not available for cpu and interrupt handler does
check any boundaries and THE QUESTION: "is it possible when interrupt
clears the interrupt in shared memory and the memory is not
available to make such damage? If yes, why it breaks only my “channel
info” - not other processes =))) . How QNX/NTO handles dynamic physical
Thanks for every comments.