diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1995-11-14 08:00:00 +0000 |
---|---|---|
committer | <ralf@linux-mips.org> | 1995-11-14 08:00:00 +0000 |
commit | e7c2a72e2680827d6a733931273a93461c0d8d1b (patch) | |
tree | c9abeda78ef7504062bb2e816bcf3e3c9d680112 /include/linux/mc146818rtc.h | |
parent | ec6044459060a8c9ce7f64405c465d141898548c (diff) |
Import of Linux/MIPS 1.3.0
Diffstat (limited to 'include/linux/mc146818rtc.h')
-rw-r--r-- | include/linux/mc146818rtc.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/include/linux/mc146818rtc.h b/include/linux/mc146818rtc.h index 741aa2dc5..5f22761fd 100644 --- a/include/linux/mc146818rtc.h +++ b/include/linux/mc146818rtc.h @@ -12,13 +12,19 @@ #define _MC146818RTC_H #include <asm/io.h> +#ifndef RTC_PORT +#define RTC_PORT(x) (0x70 + (x)) +#define RTC_ADDR(x) (0x80 | (x)) +#define RTC_ALWAYS_BCD 1 +#endif + #define CMOS_READ(addr) ({ \ -outb_p(addr|0x80,0x70); \ -inb_p(0x71); \ +outb_p(RTC_ADDR(addr),RTC_PORT(0)); \ +inb_p(RTC_PORT(1)); \ }) #define CMOS_WRITE(val, addr) ({ \ -outb_p(addr|0x80,0x70); \ -outb_p(val,0x71); \ +outb_p(RTC_ADDR(addr),RTC_PORT(0)); \ +outb_p(val,RTC_PORT(1)); \ }) /********************************************************************** |