[U-Boot] [PATCH] Rename getenv_r() into getenv_f()

Detlev Zundel dzu at denx.de
Thu Jul 29 13:30:16 CEST 2010


Hi Wolfgang,

> While running from flash, i. e. before relocation, we have only a
> limited C runtime environment without writable data segment. In this
> phase, some configurations (for example with environment in EEPROM)
> must not use the normal getenv(), but a special function.  This
> function had been called getenv_r(), with the idea that the "_r"
> suffix would mean the same as in the _r_eentrant versions of some of
> the C library functions (for example getdate vs. getdate_r, getgrent
> vs. getgrent_r, etc.).
>
> Unfortunately this was a misleading name, as in U-Boot the "_r"
> generally means "running from RAM", i. e. _after_ relocation.
>
> To avoid confusion, rename into getenv_f() [as "running from flash"]

I appreciatethis change as I was mislead also once about the nameing.

> Signed-off-by: Wolfgang Denk <wd at denx.de>

Acked-by: Detlev Zundel <dzu at denx.de>

Cheers
  Detlev

-- 
Q: Does that mean we also shouldn't be using IRQF_SAMPLE_RANDOM on
   interrupt [sources]?
A: Yes. The flag needs to be taken out and shot.
                            -- Matt Mackall <1239116251.14392.133.camel at calx>
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de


More information about the U-Boot mailing list