[ECOS] possible bug in if_fcc ethernet driver?
Peter Graf
p.graf@itknet.de
Tue Jun 15 13:53:00 GMT 2004
Gary Thomas wrote:
>On Mon, 2004-06-14 at 09:15, agyhoo wrote:
>
>
>>Hi,
>>
>>In the if_fcc ethernet driver, the fcc_eth_init routine
>>returns "false" if there is no LINK detected (ie, network
>>cable is unplugged). However, there is a compile switch
>>around the return false statement (CYGPKG_REDBOOT).
>>Therefore, when I run my eCos application, it hangs when
>>the network cable is unplugged. I think this is because the
>>network alarm thread and the background thread think the
>>device status is available and try to access it.
>>
>>Am I missing something? Can someone tell me why the compile
>>switch is present?
>>
>>
>
>We explicitly want RedBoot to not try and use the network if there
>is no cable in place (it just wastes time). In the case of eCos,
>I doubt that your program "hangs", but rather it is waiting to
>get an ethernet IP address via DHCP (the default behaviour). If
>the network is unplugged, this process will take quite a long time
>(more than 30 seconds), waiting for the network to come available.
>Eventually, the DHCP will timeout and your code will continue,
>but if it needs the network, it will probably have other problems.
>
>
>
It might be a matter of timeout(s) length(s) around phy inialization. I
vaguely remember I had to shorten them, so it recognizes the missing
cable sooner.
All the best
Peter
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
More information about the Ecos-discuss
mailing list