From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rodel Miguel Date: Sun, 6 Mar 2005 20:15:05 +0800 Subject: [U-Boot-Users] eth_rx implementation In-Reply-To: <20050306092605.480CBC1510@atlas.denx.de> References: <698a2fda0503060044189b8b1c@mail.gmail.com> <20050306092605.480CBC1510@atlas.denx.de> Message-ID: <698a2fda05030604151688be50@mail.gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Wolfgang, I'm sorry I wasnt clear enough with my query. My implementation of eth_rx is somewhat like the ff: - check if data is available - if not, return 0 - call NetReceive(NetRxPackets[0], len) - return len Questions: 1. If network data is not available, eth_rx returns 0 and does not call NetReceive(), how many times does NetworkLoop retry to send the first data it requested? 2. If data is available, eth_rx calls NetReceive, however, if it is not intended for the initial U-Boot request, how many times does does NetworkLoop retry to send the first data it requested? 3. Do you need to enable a U-Boot configuration flag to support my implementation of eth_rx? I am currently having problems with my eth_send implementation, so there are really no network requests done on the PHY layer yet, however, the eth_rx can receive data, I just noticed that there's not much error handlers on the higher layers. The ARP requests are only done twice, at least in PING command. Thank you very much for your help. Best Regards, Rodel On Sun, 06 Mar 2005 10:26:00 +0100, Wolfgang Denk wrote: > In message <698a2fda0503060044189b8b1c@mail.gmail.com> you wrote: > > > > I am having problems implementing my eth_rx function. I have seen > > And what exactly is your problem? > > > from other implementations that eth_rx will return any packet that has > > been received from the network, however, if there are no data to > > Rigth. > > > retrieve, i.e. NetReceive(NetRxPackets[0], 0), the PING function > > re-sends the ping request in at most two times. > > Yes, but this is a different issue and unrelated to the implemen- > tation of eth_rx. > > > I have implemented a polling eth_rx function. Of course there should > > be no packet type checking on this level, however, is the network loop > > OK. > > > function checking if the packets for a specific network command is > > satisfied, and if not, what does our network loop do? > > I'm not exactly sure what you are asking here. Are there any problems > with your eth_rx code as you claimed above, or did you modify > anything in the NetLoop() function, or what? > > Best regards, > > Wolfgang Denk > > -- > Software Engineering: Embedded and Realtime Systems, Embedded Linux > Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de > A witty saying proves nothing, but saying something pointless gets > people's attention. >