1 /*- 2 * Copyright (c) 1990 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * William Jolitz. 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions 10 * are met: 11 * 1. Redistributions of source code must retain the above copyright 12 * notice, this list of conditions and the following disclaimer. 13 * 2. Redistributions in binary form must reproduce the above copyright 14 * notice, this list of conditions and the following disclaimer in the 15 * documentation and/or other materials provided with the distribution. 16 * 3. All advertising materials mentioning features or use of this software 17 * must display the following acknowledgement: 18 * This product includes software developed by the University of 19 * California, Berkeley and its contributors. 20 * 4. Neither the name of the University nor the names of its contributors 21 * may be used to endorse or promote products derived from this software 22 * without specific prior written permission. 23 * 24 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 25 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 27 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 30 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 31 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 32 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 33 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 34 * SUCH DAMAGE. 35 * 36 * from: @(#)rtc.h 7.1 (Berkeley) 5/12/91 37 * $Id: rtc.h,v 1.3 1993/11/07 17:44:34 wollman Exp $ 38 */ 39 40 #ifndef _I386_ISA_RTC_H_ 41 #define _I386_ISA_RTC_H_ 1 42 43 /* 44 * RTC Register locations 45 */ 46 47 #define RTC_SEC 0x00 /* seconds */ 48 #define RTC_SECALRM 0x01 /* seconds alarm */ 49 #define RTC_MIN 0x02 /* minutes */ 50 #define RTC_MINALRM 0x03 /* minutes alarm */ 51 #define RTC_HRS 0x04 /* hours */ 52 #define RTC_HRSALRM 0x05 /* hours alarm */ 53 #define RTC_WDAY 0x06 /* week day */ 54 #define RTC_DAY 0x07 /* day of month */ 55 #define RTC_MONTH 0x08 /* month of year */ 56 #define RTC_YEAR 0x09 /* month of year */ 57 #define RTC_STATUSA 0x0a /* status register A */ 58 #define RTCSA_TUP 0x80 /* time update, don't look now */ 59 60 #define RTC_STATUSB 0x0b /* status register B */ 61 62 #define RTC_INTR 0x0c /* status register C (R) interrupt source */ 63 #define RTCIR_UPDATE 0x10 /* update intr */ 64 #define RTCIR_ALARM 0x20 /* alarm intr */ 65 #define RTCIR_PERIOD 0x40 /* periodic intr */ 66 #define RTCIR_INT 0x80 /* interrupt output signal */ 67 68 #define RTC_STATUSD 0x0d /* status register D (R) Lost Power */ 69 #define RTCSD_PWR 0x80 /* clock lost power */ 70 71 #define RTC_DIAG 0x0e /* status register E - bios diagnostic */ 72 #define RTCDG_BITS "\020\010clock_battery\007ROM_cksum\006config_unit\005memory_size\004fixed_disk\003invalid_time" 73 74 #define RTC_RESET 0x0f /* status register F - reset code byte */ 75 #define RTCRS_RST 0x00 /* normal reset */ 76 #define RTCRS_LOAD 0x04 /* load system */ 77 78 #define RTC_FDISKETTE 0x10 /* diskette drive type in upper/lower nibble */ 79 #define RTCFDT_NONE 0 /* none present */ 80 #define RTCFDT_360K 0x10 /* 360K */ 81 #define RTCFDT_12M 0x20 /* 1.2M */ 82 #define RTCFDT_720K 0x30 /* 720K */ 83 #define RTCFDT_144M 0x40 /* 1.44M */ 84 85 #define RTC_BASELO 0x15 /* low byte of basemem size */ 86 #define RTC_BASEHI 0x16 /* high byte of basemem size */ 87 #define RTC_EXTLO 0x17 /* low byte of extended mem size */ 88 #define RTC_EXTHI 0x18 /* low byte of extended mem size */ 89 90 #define RTC_CENTURY 0x32 /* current century - please increment in Dec99*/ 91 #endif /* _I386_ISA_RTC_H_ */ 92