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: ååï Re: Re: store mac address


On Fri, 2007-04-20 at 15:04 +0800, è ç wrote:
> > > I want to use the redboot command set_npe_mac to
> > set a
> > > new mac address,then what do I need to do?
> > 
> > set_npe_mac is used when there is an eeprom.
> > If you are storing the mac in flash, use fconfig to
> > set the mac.
> > 
> > --Mark
> > 
> The fconfig cmd doesn't have the option to set npe's
> mac address.
> Perhaps it is because when I configure the redboot use
> the ixdp425 for my template.And at grg board, the cmd
> fconfig has this option.
> 
> Since both two boards share the same file fconfig.c.
> Maybe I can config some packages or options to store
> the mac in flash, just like grg did it? How can I do
> it?
> 
> If it does, the mac will stored in redboot config
> area.But what is address it stored exactly?
> 

In devs/eth/arm/grg/npe/<version>/include/*.inl, you will see something
like:

#if defined(CYGPKG_REDBOOT) && defined(CYGPKG_REDBOOT_FLASH) && \
    defined(CYGSEM_REDBOOT_FLASH_CONFIG) &&
defined(CYGPKG_REDBOOT_NETWORKING)

#define CYGSEM_NPE_REDBOOT_HOLDS_ESA 1
#define CYGDAT_ETH0_DEFAULT_ESA {0x00, 0x03, 0x47, 0xdf, 0x32, 0xa8}
#define CYGDAT_ETH1_DEFAULT_ESA {0x00, 0x03, 0x47, 0xdf, 0x32, 0xaa}
#endif

It is the defining of CYGSEM_NPE_REDBOOT_HOLDS_ESA which causes RedBoot
to create an fconfig option to hold the mac address.

--Mark



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