[ECOS] multiple eth devices for RedBoot

Gary D. Thomas gary.thomas@mind.be
Wed Mar 19 23:42:00 GMT 2003

On Wed, 2003-03-19 at 15:11, Mark Salter wrote:
> >>>>> Gary D Thomas writes:
> > On Wed, 2003-03-19 at 13:09, Mark Salter wrote:
> >> 
> >> Here's a patch I've been playing around with which adds multiple
> >> ethernet device support to RedBoot. RedBoot doesn't support all
> >> of the devices simultaneouly, but it does allow for boot time
> >> selection among available devices. With flash, you can select
> >> the preferred net device through fconfig. Without flash, the
> >> preferred device is selected with CDL. If the preferred device
> >> is not found (or otherwise fails to initialize), the rest of
> >> the devices are tried in order until one is successfully
> >> initialized. The first one successfully initialized becomes the
> >> RedBoot net device.
> > I like it.  I hope that it doesn't introduce confusion though.
> > What if interface A is on subnet A' and interface B is on subnet
> > B' and RedBoot's default IP (assuming not using BOOTP) is on B'?
> > Maybe the automatic selection only makes sense if you are using
> > BOOTP, because in that mode there should be no subnet problems.
> I think BOOTP makes it easier to switch devices, but I don't think
> its required. If you are statically configured and change devices,
> you should change the static IP, etc at the same time if necessary.
> Definitely needs some documentation, though.

This matches what I was trying to say.

> >> 
> >> What do other folks think about this? I really wish there was a
> >> couldn't think of a better build-time way to determine that there
> >> are multiple devices configured into the system.
> > One way (which would be a little invasive, but might be nice for
> > other purposes as well) would be to add a CDL interface which is
> > implemented by hardware drivers.  Then your "MULTIPLE_DEVS" is
> > just "NUM_DEVS > 1"
> Ahh, CYGHWR_NET_DRIVERS looks promising. All eth drivers implement
> it. The cdl_interface for it is declared in net/common, so it isn't
> visible for RedBoot. Maybe the cdl_interface should be moved to
> io/eth instead?

Maybe so since the io layer is more closely tied with the actual
device drivers.  I don't see any reason why not.

|       Mind: Embedded Linux and eCos Development        |
| Gary Thomas              email:  gary.thomas@mind.be   |
| Mind ( http://mind.be )  tel:    +1 (970) 229-1963     |
| gpg: http://www.chez-thomas.org/gary/gpg_key.asc       |

Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

More information about the Ecos-discuss mailing list