This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to attach higher ethernet stacks to the MAC driver


Hi all,
Â
I have a question regarding the connection between a mac-/phy-driver and a third
party tcp / ip stack. In the mac layer I have functions like
y_eth_isr, y_eth_init, y_eth_send, y_eth_recv, ... and many more.
Â
In y_eth_init I attached an ISR (y_eth_isr) and the default DSR (eth_drv_dsr).
Â
As far as I understood, the data flow is as follows:
1) The MAC (Hardware) receives an ethernet frame and creates an interrupt
2) y_eth_isr is called ( ret = (CYG_ISR_HANDLED | CYG_ISR_CALL_DSR); )
3) The default eth_drv_dsr is called
4) y_eth_deliver is called
5) y_eth_poll is called
6) The default eth_drv_recv is called
7) y_eth_recv in the mac driver is called
Â
This is not what I really could proove but what I investigated by reading the
documentation and source code. Now.. my consideration was that I simply have to
add the call to the receive function of the tcp/ip stack in y_eth_recv. Is this
the right approach?
Â
Another point: how can I reliable test the function of my hardware? I plugged in
my device into an ethernet switch which says that there is a link. Using ipconfig
under Windows just says -not connected-. Using ping is not a solution of course,
because I have no ip address...
Â
And a third question: in the send function of the tcp/ip stack I have to forward
the send buffer to y_eth_send in the mac layer. I simply do this by calling
y_eth0_sc.funs->send(...). Is this the suitable way?
Â
Kind Regards,
Dennis
Â

--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]