diff options
Diffstat (limited to 'drivers/rtc/ds3231.c')
-rw-r--r-- | drivers/rtc/ds3231.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/rtc/ds3231.c b/drivers/rtc/ds3231.c index bd32ed2dbf9..6341a1d62b8 100644 --- a/drivers/rtc/ds3231.c +++ b/drivers/rtc/ds3231.c @@ -14,7 +14,7 @@ * copied from ds1337.c */ -#include <common.h> +#include <config.h> #include <command.h> #include <dm.h> #include <log.h> @@ -34,7 +34,6 @@ #define RTC_CTL_REG_ADDR 0x0e #define RTC_STAT_REG_ADDR 0x0f - /* * RTC control register bits */ @@ -54,12 +53,10 @@ #define RTC_STAT_BIT_BB32KHZ 0x40 /* Battery backed 32KHz Output */ #define RTC_STAT_BIT_EN32KHZ 0x8 /* Enable 32KHz Output */ - #if !CONFIG_IS_ENABLED(DM_RTC) static uchar rtc_read (uchar reg); static void rtc_write (uchar reg, uchar val); - /* * Get the current time from the RTC */ @@ -107,7 +104,6 @@ int rtc_get (struct rtc_time *tmp) return rel; } - /* * Set the RTC */ @@ -133,7 +129,6 @@ int rtc_set (struct rtc_time *tmp) return 0; } - /* * Reset the RTC. We also enable the oscillator output on the * SQW/INTB* pin and program it for 32,768 Hz output. Note that @@ -167,7 +162,6 @@ uchar rtc_read (uchar reg) return (i2c_reg_read (CFG_SYS_I2C_RTC_ADDR, reg)); } - static void rtc_write (uchar reg, uchar val) { i2c_reg_write (CFG_SYS_I2C_RTC_ADDR, reg, val); |