diff options
author | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2021-06-14 18:47:09 +0200 |
---|---|---|
committer | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2021-07-12 20:30:48 +0200 |
commit | cbe3ab986bdd5301dd4cbfd50e316a063d17d7b8 (patch) | |
tree | 9b8cc667d2781c8bfcd6790be2b997a4a6f05da5 /lib/date.c | |
parent | 13c11c665320beff22ea94674da42719b6281501 (diff) | |
download | u-boot-cbe3ab986bdd5301dd4cbfd50e316a063d17d7b8.zip u-boot-cbe3ab986bdd5301dd4cbfd50e316a063d17d7b8.tar.gz u-boot-cbe3ab986bdd5301dd4cbfd50e316a063d17d7b8.tar.bz2 |
lib: remove superfluous #ifdefs from date.c
We should avoid #ifdef in C modules. Unused functions are eliminated by the
linker.
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'lib/date.c')
-rw-r--r-- | lib/date.c | 6 |
1 files changed, 0 insertions, 6 deletions
@@ -10,8 +10,6 @@ #include <rtc.h> #include <linux/time.h> -#if defined(CONFIG_LIB_DATE) || defined(CONFIG_TIMESTAMP) - #define FEBRUARY 2 #define STARTOFTIME 1970 #define SECDAY 86400L @@ -97,9 +95,6 @@ unsigned long rtc_mktime(const struct rtc_time *tm) return (hours * 60 + tm->tm_min) * 60 + tm->tm_sec; } -#endif /* CONFIG_LIB_DATE || CONFIG_TIMESTAMP */ - -#ifdef CONFIG_LIB_DATE /* for compatibility with linux code */ time64_t mktime64(const unsigned int year, const unsigned int mon, const unsigned int day, const unsigned int hour, @@ -116,4 +111,3 @@ time64_t mktime64(const unsigned int year, const unsigned int mon, return (time64_t)rtc_mktime((const struct rtc_time *)&time); } -#endif |