summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2016-02-24 18:49:25 -0600
committerAaron Durbin <adurbin@chromium.org>2016-02-26 02:14:56 +0100
commita7141c518a94b42923712de0d83a3e45fe1ee3ca (patch)
tree9c98b354b310c00754475dc1b4e288bcbfd9c369 /src/lib
parente0b3c7bef1ab5ed6721b7ea6411862ae6e177ef6 (diff)
downloadcoreboot-a7141c518a94b42923712de0d83a3e45fe1ee3ca.tar.xz
lib/memrange: avoid shadow object declarations
Fix an error where a variable named 'free' was shadowing the function 'free'. src/lib/memrange.c:293:73: error: declaration of 'free' shadows a global declaration [-Werror=shadow] Change-Id: Ie57194b392f8f00ed4fd5c76dab27299b00ae293 Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://review.coreboot.org/13788 Tested-by: build bot (Jenkins) Reviewed-by: Furquan Shaikh <furquan@google.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/memrange.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/memrange.c b/src/lib/memrange.c
index cc75e01c26..489b56212a 100644
--- a/src/lib/memrange.c
+++ b/src/lib/memrange.c
@@ -290,7 +290,7 @@ void memranges_add_resources(struct memranges *ranges,
memranges_add_resources_filter(ranges, mask, match, tag, NULL);
}
-void memranges_init_empty(struct memranges *ranges, struct range_entry *free,
+void memranges_init_empty(struct memranges *ranges, struct range_entry *to_free,
size_t num_free)
{
size_t i;
@@ -299,7 +299,7 @@ void memranges_init_empty(struct memranges *ranges, struct range_entry *free,
ranges->free_list = NULL;
for (i = 0; i < num_free; i++)
- range_entry_link(&ranges->free_list, &free[i]);
+ range_entry_link(&ranges->free_list, &to_free[i]);
}
void memranges_init(struct memranges *ranges,