This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
RedBoot: gateway support
- To: ecos-discuss at sources dot redhat dot com
- Subject: [ECOS] RedBoot: gateway support
- From: Grant Edwards <grante at visi dot com>
- Date: Thu, 29 Mar 2001 13:11:01 -0600
Yesterday I added default gateway support to RedBoot --
including using DHCP to get the netmask. It appears to be
working, but I've got more testing I want to do.
Here's the current situation:
The routing logic (including determining Ethernet addresses)
occurs at the UDP/TCP layer:
* UDP uses the netmask/gatway configuration and then ARP
* TCP uses whatever Ethernet address the SYN packet came from.
The IP code then uses whatever Ethernet address is passed from
the higher layers.
This should work for a vast majority of networks. The only
problem would be a network where outgoing TCP/IP packets are
supposed to go to a _different_ gateway than the one they came
in on. I've never seen a network like that, but it's doable.
If one wants proper gateway support for TCP packets as well,
there are two options:
1) Copy routing logic that's in UDP to TCP.
[It's only about 5 lines of code, so it's no big deal.]
2) Put the routing logic in the IP layer and have the UDP and
TCP layer pass just the IP address to the IP layer rather
than passing IP+Ethernet to the IP layer. [This is a
little more work, but feels like "the right thing to do".]
Questions:
1) Is anybody interested in having gateway support put into
RedBoot?
2) If yes, is the current scheme (TCP uses source Ethernet,
UDP does gateway and ARP) good enough?
3) If not, should gateway/Ethernet address logic be moved into
the IP layer, or should the routing logic be duplicated in
UDP and TCP code?
--
Grant Edwards
grante@visi.com