This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Question about Hardware Device Driver(Eth)
- From: "HuangQiang" <jameshq at liverpool dot ac dot uk>
- To: "eCos" <ecos-discuss at sources dot redhat dot com>
- Date: Mon, 3 Dec 2001 15:03:13 -0000
- Subject: [ECOS] Question about Hardware Device Driver(Eth)
Dear all:
Q1: Is the source in Package/IO/Eth/net/src for logical ethernet layer
function? And the source in Package/dev/Eth/Arm/... for the physical
ethernet driver(low-layer driver)?
Q2: How does TCP/IP stack interact with the ethernet driver? Does the TCP/IP
stack interact with the logical driver (in Package/IO/Eth/net/src) and then
interact with physical driver(Package/dev/Eth/Arm/...)? Is the layer shown
below correct?
User Application
---------------------------------------------
^
|
|
---------------------------------------------
TCP/IP Stack
---------------------------------------------
^
|
|
---------------------------------------------
Logical driver ( is the name right?)
Source in "Package/IO/Eth/net/src"
functions:
[ eth_drv_start(), eth_drv_init(),eth_drv_ioctl()
eth_drv_send(), eth_drv_tx_done(), eth_drv_recv()
eth_drv_dsr(), eth_drv_run_deliveries()
]
---------------------------------------------
^
|
| eth_drv_sc *sc
----------------------------------------------
Physical driver
Source in :"Package/dev/Eth/Arm/..."
----------------------------------------------
Q3: But how does TCP/IP stack interact with the logical layer function? (How
eth_drv_xxx() functions is called in TCP/IP?)
Q4: some function in logical layer is exported to physical layer:
eth_drv_tx_done(), eth_drv_init(), eth_drv_recv(). why these is needed?
Isn't that the physical layer function is called by calling the logical
layer function: eth_drv_xxx()? (maybe I went the wrong way.)
Thanks a lot
Best regards!
james