2003-02-11 Mike Siers <mikes@poliac.com>

* rtems/rtems_glue.c: A small patch to the network daemon task
	code.  I just added code to check the return value of
	the rtems_bsdnet_event_receive function.  Only when
	this function returns a SUCCESSFUL status, will the
	event flags be checked.  This is more of a code cleanup issue
	than a bug.  The patch will just ensure the ipintr() and
	arpintr() functions are only called when a event is signaled.
This commit is contained in:
Joel Sherrill
2003-02-11 22:58:08 +00:00
parent d854517744
commit 83e36d6bb7
2 changed files with 20 additions and 5 deletions
+10
View File
@@ -1,3 +1,13 @@
2003-02-11 Mike Siers <mikes@poliac.com>
* rtems/rtems_glue.c: A small patch to the network daemon task
code. I just added code to check the return value of
the rtems_bsdnet_event_receive function. Only when
this function returns a SUCCESSFUL status, will the
event flags be checked. This is more of a code cleanup issue
than a bug. The patch will just ensure the ipintr() and
arpintr() functions are only called when a event is signaled.
2003-02-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* configure.ac: AM_INIT_AUTOMAKE([1.7.2]).
+10 -5
View File
@@ -503,6 +503,7 @@ rtems_bsdnet_schednetisr (int n)
static void
networkDaemon (void *task_argument)
{
rtems_status_code sc;
rtems_event_set events;
rtems_interval now;
int ticksPassed;
@@ -515,14 +516,18 @@ networkDaemon (void *task_argument)
timeout = c->c_time;
else
timeout = RTEMS_NO_TIMEOUT;
rtems_bsdnet_event_receive (NETISR_EVENTS,
sc = rtems_bsdnet_event_receive (NETISR_EVENTS,
RTEMS_EVENT_ANY | RTEMS_WAIT,
timeout,
&events);
if (events & NETISR_IP_EVENT)
ipintr ();
if (events & NETISR_ARP_EVENT)
arpintr ();
if ( sc == RTEMS_SUCCESSFUL ) {
if (events & NETISR_IP_EVENT)
ipintr ();
if (events & NETISR_ARP_EVENT)
arpintr ();
}
rtems_clock_get (RTEMS_CLOCK_GET_TICKS_SINCE_BOOT, &now);
ticksPassed = now - ticksWhenCalloutsLastChecked;
if (ticksPassed != 0) {