summaryrefslogtreecommitdiff
path: root/common/env_mmc.c
diff options
context:
space:
mode:
authorFabio Estevam <fabio.estevam@freescale.com>2013-01-08 05:36:11 +0000
committerTom Rini <trini@ti.com>2013-02-04 09:07:21 -0500
commitb56540801f980051da1474523ea0f6dfe1b8a6bd (patch)
tree5c987d0ee002738504c9004a7e68abf1abd3cd9f /common/env_mmc.c
parent0f3073433ceb258fde00f82556d43dba6633083a (diff)
downloadu-boot-b56540801f980051da1474523ea0f6dfe1b8a6bd.tar.gz
common: env_mmc: Use __weak annotation to simplify code
Using the __weak annotation can make the code cleaner. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Marek Vasut <marex@denx.de>
Diffstat (limited to 'common/env_mmc.c')
-rw-r--r--common/env_mmc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/common/env_mmc.c b/common/env_mmc.c
index ce21671210..02bd5aed10 100644
--- a/common/env_mmc.c
+++ b/common/env_mmc.c
@@ -46,13 +46,11 @@ DECLARE_GLOBAL_DATA_PTR;
#define CONFIG_ENV_OFFSET 0
#endif
-static int __mmc_get_env_addr(struct mmc *mmc, u32 *env_addr)
+__weak int mmc_get_env_addr(struct mmc *mmc, u32 *env_addr)
{
*env_addr = CONFIG_ENV_OFFSET;
return 0;
}
-int mmc_get_env_addr(struct mmc *mmc, u32 *env_addr)
- __attribute__((weak, alias("__mmc_get_env_addr")));
int env_init(void)
{