[U-Boot-Users] RE: Ethernet loopback command

Thomas Schäfer thomas.schaefer at kontron.com
Wed Mar 9 18:55:56 CET 2005


 

> In message 
> <D9F0B2AD4531B0449D51C1F09199D484081F2A at mail.kom-saarbruecken.
> com> you wrote:
> >
> > I actually planned to introduce a FE loopback test in the POST 
> > framework. But the functions provided seemed to be 
> necessary, because 
> > generation and receipt of packets is basic for loopback tests.
> 
> See the existing ethernet lopback code (post/ether.c)
> 
> > The PROT_IP part of the NetReceive function examines the 
> complete IP 
> > header which is not necessary here. I introduced that packet type to
> 
> But it doesn't hurt either, or does it?
> 
The code in post/ether.c uses modified low level ethernet init/send/receive functions for 8xx CPU's to send a broadcast ethernet frame. Adopting this for other CPU's requires to modify those functions for each CPU you want to support. The approach in the patch provided tries to implement a more common solution by using the upper network layer in net/net.c. I cannot see how to implement this without either creating a complete IP header that can be handled properly by the PROT_IP part of the NetReceive function or using another protocol type.

> > You would need a station responding to the ping, which would be 
> > difficult during POST. With improved packet generation 
> (large packets, 
> > Mbytes of data), stressing the FE subsystem could be achieved.
> 
> I disagree. Having a remote station to  answer  is  actually  
> a  good idea,  as  you know at least that the packets are 
> standard, i. e. for example that the header fields are in 
> correct byte  orders,  etc.  If you're  looking  for  
> throughout  tests,  you can do this much better using a 
> remote side, too.
> 
> 
> Best regards,
> 
> Wolfgang Denk
> 
> 
Best regards,

Thomas Schäfer




More information about the U-Boot mailing list