diff mbox

[U-Boot,16/32] eNET: Add RTC support to eNET

Message ID 1296822959-3927-17-git-send-email-graeme.russ@gmail.com
State Accepted
Commit 218310018a9d24db76cbfd6aa9441d3b7c8b72b7
Delegated to: Graeme Russ
Headers show

Commit Message

Graeme Russ Feb. 4, 2011, 12:35 p.m. UTC
The SC520 has an inbuilt MC146818 - Enable it for the eNET board

Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
---
 drivers/rtc/mc146818.c |    6 ++++++
 include/configs/eNET.h |    2 ++
 2 files changed, 8 insertions(+), 0 deletions(-)

Comments

Graeme Russ Feb. 12, 2011, 4:29 a.m. UTC | #1
On 04/02/11 23:35, Graeme Russ wrote:
> The SC520 has an inbuilt MC146818 - Enable it for the eNET board
> 
> Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
> ---
>  drivers/rtc/mc146818.c |    6 ++++++
>  include/configs/eNET.h |    2 ++
>  2 files changed, 8 insertions(+), 0 deletions(-)
> 

Applied to u-boot-x86

Regards,

Graeme
diff mbox

Patch

diff --git a/drivers/rtc/mc146818.c b/drivers/rtc/mc146818.c
index ac4eb6a..59f6765 100644
--- a/drivers/rtc/mc146818.c
+++ b/drivers/rtc/mc146818.c
@@ -31,6 +31,12 @@ 
 #include <command.h>
 #include <rtc.h>
 
+#ifdef __I386__
+#include <asm/io.h>
+#define in8(p) inb(p)
+#define out8(p, v) outb(v, p)
+#endif
+
 #if defined(CONFIG_CMD_DATE)
 
 static uchar rtc_read  (uchar reg);
diff --git a/include/configs/eNET.h b/include/configs/eNET.h
index 78cab29..082f681 100644
--- a/include/configs/eNET.h
+++ b/include/configs/eNET.h
@@ -33,6 +33,7 @@ 
  * Stuff still to be dealt with -
  */
 #define CONFIG_RTC_MC146818
+#define CONFIG_SYS_ISA_IO_BASE_ADDRESS	0
 
 /*
  * High Level Configuration Options
@@ -91,6 +92,7 @@ 
 #define CONFIG_CMD_BDI		/* bdinfo			*/
 #define CONFIG_CMD_BOOTD	/* bootd			*/
 #define CONFIG_CMD_CONSOLE	/* coninfo			*/
+#define CONFIG_CMD_DATE
 #define CONFIG_CMD_ECHO		/* echo arguments		*/
 #define CONFIG_CMD_FLASH	/* flinfo, erase, protect	*/
 #define CONFIG_CMD_FPGA		/* FPGA configuration Support	*/