From mboxrd@z Thu Jan 1 00:00:00 1970 From: andrew.lunn@ascom.ch (Andrew Lunn) To: gthomas@redhat.com (Gary Thomas) Cc: grante@visi.com, ecos-discuss@sourceware.cygnus.com, Nick.Barnes@pobox.com Subject: Re: [ECOS] Notes on static configuration of an eCos network inte Date: Mon, 17 Jul 2000 09:28:00 -0000 Message-id: <200007171628.SAA06642@biferten.ma.tech.ascom.ch> References: X-SW-Source: 2000-07/msg00156.html Time to chip my two pence worth in. 1) I think having the ability to statically defined IP addresses inside the binary is a bad idea. Its so easy to get the same binary running on two boards at once. The two boards then have the same IP addresses active on the network. At best one will fail with an panic, at worst all sorts of flaky things happen. Id remove this feature all together. If people want to build static addresses in they can bring the interfaces up themselfs with the addresses. 2) Until recently, build_bootp_record has not been available becasue it was declared static and only compiled if you did want to use bootp to get IP addresses. I pointed this out and i beleave this will be fix in the next release. This made it messy to use so i just cut&pasted it into my own code and then modified it to my own needs. I think this is one area you need to do some more testing. From your tests it looks like you never test bringing up interfaces with application supplied addresses. > * how is what you are using different than the code in "init_all_network..." > when non-BOOTP mode is selected? First re-read the message i posted about this last week. init_all_network interfaces assums you want to do one off... 1) Use bootp 2) Use static ip addresses which are configured by the config tool. It has problems when you want to use the logical third option 3) The application supplies its own addresses. and is impossible if you want to 4) application supplies some addresses and bootp is used for others. In my case i get them from flash, so they are board specific, not binary specific. As i said in my last message, it not so easy to get it right, especially when init_all_network... keeps changing with every release. Thats why i asked for a review off all this when DHCP is added. init_all_network... should be init_all_unintializes_network... Andrew