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]

Re: ecos with lwip and 2 interfaces


Mandeep Sandhu wrote:
You're right Simon. Enabling the second interface there made things
work (to some extent).

However, I'm facing a new problem now.

Previously I was using only a single interface (the Linux tap0
device). I have implemented a DHCP server which was working fine until
I enabled the SECOND INTERFACE.

Now, my socket writes on the first interface (the tap0 interface) have
started failing! That is, without changing _any_ code! :( The return
value of sendto is coming as '-1' and the error string is set to 'No
error'. Actually this problem starts even if I don't enable support
for eth1 in the lwIP config. Just enabling the second interface under
"Common ethernet support -> Synthetic target ethernet driver" causes
this problem to surface.

Any clues as to what could be going wrong?

Well, this could be a problem because the default netif was set incorrectly. Only one netif can be the default netif. Currently the last initialized ethernet device would be set as default (incorrectly). I have changed that in the new version, also added 'Default netif' for loopif and slipif devices and also expanded configurability of ethernet netifs to 4 devices (previously 2). Now, only the selected netif should be the default netif. Please test with the new version and see if that helps:


http://download.westlicht.ch/lwip-20090923.tar.gz

Simon

--
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]