From 6a45e384955262882375a2785426dc65aeb636c4 Mon Sep 17 00:00:00 2001 From: Dirk Behme Date: Sun, 3 Jan 2010 08:33:58 +0100 Subject: Make getenv_IPaddr() global There are boards out there that do not have network support in U-Boot (CONFIG_CMD_NET not set), but they do so in Linux. This makes it desirable to be able to port network configuration (like the IP address) to the Linux kernel. We should not make the passing of the IP configuration to Linux dependent on U-Boot features / settings. For this, make getenv_IPaddr() global. This fixes build error u-boot/lib_xxx/board.c:360: undefined reference to `getenv_IPaddr' on various architectures. Signed-off-by: Dirk Behme Acked-by: Ben Warren --- include/common.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/common.h') diff --git a/include/common.h b/include/common.h index 07897f682e..8197508b6d 100644 --- a/include/common.h +++ b/include/common.h @@ -617,6 +617,13 @@ int gunzip(void *, int, unsigned char *, unsigned long *); int zunzip(void *dst, int dstlen, unsigned char *src, unsigned long *lenp, int stoponerr, int offset); +/* lib_generic/net_utils.c */ +#include +static inline IPaddr_t getenv_IPaddr (char *var) +{ + return (string_to_ip(getenv(var))); +} + /* lib_generic/time.c */ void udelay (unsigned long); -- cgit v1.2.1