Skip to content
Snippets Groups Projects
Commit 0219fb61 authored by Simon Glass's avatar Simon Glass Committed by Tom Rini
Browse files

env: common: Drop env_get_addr()


This function is not used anywhere other than env_get_char(). Move the
code into that function.

Reviewed-by: default avatarTom Rini <trini@konsulko.com>
Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
parent bcdfb8d5
No related branches found
No related tags found
No related merge requests found
...@@ -41,17 +41,12 @@ static uchar env_get_char_init(int index) ...@@ -41,17 +41,12 @@ static uchar env_get_char_init(int index)
return default_environment[index]; return default_environment[index];
} }
static const uchar *env_get_addr(int index) static uchar env_get_char_memory(int index)
{ {
if (gd->env_valid) if (gd->env_valid)
return (uchar *)(gd->env_addr + index); return *(uchar *)(gd->env_addr + index);
else else
return &default_environment[index]; return default_environment[index];
}
static uchar env_get_char_memory(int index)
{
return *env_get_addr(index);
} }
uchar env_get_char(int index) uchar env_get_char(int index)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment