URL
https://opencores.org/ocsvn/or1k/or1k/trunk
Go to most recent revision |
Details |
Compare with Previous |
View Log
Line No. |
Rev |
Author |
Line |
1 |
1026 |
ivang |
@c
|
2 |
|
|
@c Written by Eric Norum
|
3 |
|
|
@c
|
4 |
|
|
@c COPYRIGHT (c) 1988-2002.
|
5 |
|
|
@c On-Line Applications Research Corporation (OAR).
|
6 |
|
|
@c All rights reserved.
|
7 |
|
|
@c
|
8 |
|
|
@c networktasks.t,v 1.8 2002/01/17 21:47:45 joel Exp
|
9 |
|
|
@c
|
10 |
|
|
|
11 |
|
|
@chapter Network Task Structure and Data Flow
|
12 |
|
|
|
13 |
|
|
A schematic diagram of the tasks and message @b{mbuf} queues in a
|
14 |
|
|
simple RTEMS networking application is shown in the following
|
15 |
|
|
figure:
|
16 |
|
|
|
17 |
|
|
@ifset use-ascii
|
18 |
|
|
@example
|
19 |
|
|
@group
|
20 |
|
|
NO ASCII VERSION OF THE TASKING FIGURE IS AVAILABLE
|
21 |
|
|
@end group
|
22 |
|
|
@end example
|
23 |
|
|
@end ifset
|
24 |
|
|
|
25 |
|
|
@ifset use-tex
|
26 |
|
|
@image{networkflow,5in,6in}
|
27 |
|
|
@end ifset
|
28 |
|
|
|
29 |
|
|
@ifset use-html
|
30 |
|
|
@html
|
31 |
|
|
|
32 |
|
|
ALT="Network Task Structure and Data Flow">
|
33 |
|
|
@end html
|
34 |
|
|
@end ifset
|
35 |
|
|
|
36 |
|
|
|
37 |
|
|
The transmit task for each network interface is normally blocked waiting
|
38 |
|
|
for a packet to arrive in the transmit queue. Once a packet arrives, the
|
39 |
|
|
transmit task may block waiting for an event from the transmit interrupt
|
40 |
|
|
handler. The transmit interrupt handler sends an RTEMS event to the transmit
|
41 |
|
|
task to indicate that transmit hardware resources have become available.
|
42 |
|
|
|
43 |
|
|
The receive task for each network interface is normally blocked waiting
|
44 |
|
|
for an event from the receive interrupt handler. When this event is received
|
45 |
|
|
the receive task reads the packet and forwards it to the network stack
|
46 |
|
|
for subsequent processing by the network task.
|
47 |
|
|
|
48 |
|
|
The network task processes incoming packets and takes care of
|
49 |
|
|
timed operations such as handling TCP timeouts and
|
50 |
|
|
aging and removing routing table entries.
|
51 |
|
|
|
52 |
|
|
The `Network code' contains routines which may run in the context of
|
53 |
|
|
the user application tasks, the interface receive task or the network task.
|
54 |
|
|
A network semaphore ensures that
|
55 |
|
|
the data structures manipulated by the network code remain consistent.
|
© copyright 1999-2025
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.