diff options
author | Stefan Reinauer <reinauer@chromium.org> | 2013-01-14 10:20:15 -0800 |
---|---|---|
committer | Anton Kochkov <anton.kochkov@gmail.com> | 2013-01-15 09:29:30 +0100 |
commit | 09e16dc21597d20f215c822d63f8409271baacca (patch) | |
tree | 41c1fc920c2365c7e0c5d1a5ab531722f58b5e4b | |
parent | 816e9d1f0e1d317e360e26a43dfb6b7d36c2a514 (diff) |
libpayload: Style fixes
Change-Id: Ic3164fbffd8da6bd9d506d80e425ad89efc0f1af
Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Reviewed-on: http://review.coreboot.org/2144
Tested-by: build bot (Jenkins)
Reviewed-by: Dave Frodin <dave.frodin@se-eng.com>
Reviewed-by: Martin Roth <martin.roth@se-eng.com>
Reviewed-by: Anton Kochkov <anton.kochkov@gmail.com>
-rw-r--r-- | payloads/libpayload/libcbfs/cbfs.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/payloads/libpayload/libcbfs/cbfs.c b/payloads/libpayload/libcbfs/cbfs.c index fd4cfb2319..026b73c965 100644 --- a/payloads/libpayload/libcbfs/cbfs.c +++ b/payloads/libpayload/libcbfs/cbfs.c @@ -47,11 +47,13 @@ uint32_t romstart(void); uint32_t romend(void); #include <arch/virtual.h> -static uint32_t host_virt_to_phys(void *addr) { +static uint32_t host_virt_to_phys(void *addr) +{ return virt_to_phys(addr); } -static void *host_phys_to_virt(uint32_t addr) { +static void *host_phys_to_virt(uint32_t addr) +{ return phys_to_virt(addr); } #undef virt_to_phys @@ -78,11 +80,13 @@ uint32_t romend(void) static uint32_t ram_cbfs_offset; -static uint32_t ram_virt_to_phys(void *addr) { +static uint32_t ram_virt_to_phys(void *addr) +{ return (uint32_t)addr - ram_cbfs_offset; } -static void *ram_phys_to_virt(uint32_t addr) { +static void *ram_phys_to_virt(uint32_t addr) +{ return (void*)addr + ram_cbfs_offset; } @@ -94,7 +98,7 @@ void setup_cbfs_from_ram(void* start, uint32_t size) phys_to_virt = ram_phys_to_virt; } -void setup_cbfs_from_flash() +void setup_cbfs_from_flash(void) { virt_to_phys = host_virt_to_phys; phys_to_virt = host_phys_to_virt; |