From: Simon Glass Date: Tue, 11 Nov 2014 00:16:49 +0000 (-0700) Subject: dm: Disable dm_warn() in SPL X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=a94f468fa292c43be7ac9fe35adea5065fbc2a28;p=u-boot.git dm: Disable dm_warn() in SPL Since this function can use up quite a bit of space for its strings, disable it by default in SPL. Use CONFIG_DM_WARN to re-enable it. Signed-off-by: Simon Glass Reviewed-by: Tom Rini --- diff --git a/include/config_defaults.h b/include/config_defaults.h index f1b225d670..4d49315044 100644 --- a/include/config_defaults.h +++ b/include/config_defaults.h @@ -21,6 +21,7 @@ #define CONFIG_PARTITIONS 1 #ifndef CONFIG_SPL_BUILD +#define CONFIG_DM_WARN #define CONFIG_DM_DEVICE_REMOVE #define CONFIG_DM_STDIO #endif diff --git a/include/dm/util.h b/include/dm/util.h index 6ac3a38ef0..0cec17b52a 100644 --- a/include/dm/util.h +++ b/include/dm/util.h @@ -7,7 +7,13 @@ #ifndef __DM_UTIL_H #define __DM_UTIL_H +#ifdef CONFIG_DM_WARN void dm_warn(const char *fmt, ...); +#else +static inline void dm_warn(const char *fmt, ...) +{ +} +#endif #ifdef DEBUG void dm_dbg(const char *fmt, ...);