Date: Sat, 7 Sep 1996 20:43:54 -0500 (CDT) From: Giritharan Rashiyamany <giri@aic1.accesscom.com> To: freebsd-hackers@freebsd.org Cc: terry@lambert.org Subject: interrupts in software Message-ID: <Pine.LNX.3.90.960907203704.7658A-100000@aic1.accesscom.com>
index | next in thread | raw e-mail
Hi Hackers,
I need to implement an interrupt in software that'll do the following.
It's functionality is similar to ipintr() call which will basically
enqueue packets, and the continue processing until there aren't any more
packets to process. In essence, myintr() should be activated if not active and
subsequent calls to it should not activate a second instance. If myintr()
is not active, then a call to it will activate it.
#define ACTIVE_YES 0
#define ACTIVE_NO 1
int state = ACTIVE+NO;
void
myintr()
{
if(state = ACTIVE_YES)
return;
while (queue_is_not_empty())
{
process();
}
state = ACIVE_NO;
return;
}
something like this. ANy help appreciated
DMC
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.3.90.960907203704.7658A-100000>
