source: svn/trunk/newcon3bcm2_21bu/toolchain/mipsel-linux-uclibc/include/linux/cobalt-nvram.h @ 52

Last change on this file since 52 was 2, checked in by jglee, 11 years ago

first commit

  • Property svn:executable set to *
File size: 4.4 KB
Line 
1/*
2 * cobalt-nvram.h : defines for the various fields in the cobalt NVRAM
3 *
4 * Copyright 2001,2002 Sun Microsystems, Inc.
5 */
6
7#ifndef COBALT_NVRAM_H
8#define COBALT_NVRAM_H
9
10#include <linux/nvram.h>
11
12#define COBT_CMOS_INFO_MAX              0x7f    /* top address allowed */
13#define COBT_CMOS_BIOS_DRIVE_INFO       0x12    /* drive info would go here */
14
15#define COBT_CMOS_CKS_START             NVRAM_OFFSET(0x0e)
16#define COBT_CMOS_CKS_END               NVRAM_OFFSET(0x7f)
17
18/* flag bytes - 16 flags for now, leave room for more */
19#define COBT_CMOS_FLAG_BYTE_0           NVRAM_OFFSET(0x10)
20#define COBT_CMOS_FLAG_BYTE_1           NVRAM_OFFSET(0x11)
21
22/* flags in flag bytes - up to 16 */
23#define COBT_CMOS_FLAG_MIN              0x0001
24#define COBT_CMOS_CONSOLE_FLAG          0x0001 /* console on/off */
25#define COBT_CMOS_DEBUG_FLAG            0x0002 /* ROM debug messages */
26#define COBT_CMOS_AUTO_PROMPT_FLAG      0x0004 /* boot to ROM prompt? */
27#define COBT_CMOS_CLEAN_BOOT_FLAG       0x0008 /* set by a clean shutdown */
28#define COBT_CMOS_HW_NOPROBE_FLAG       0x0010 /* go easy on the probing */
29#define COBT_CMOS_SYSFAULT_FLAG         0x0020 /* system fault detected */
30#define COBT_CMOS_OOPSPANIC_FLAG        0x0040 /* panic on oops */
31#define COBT_CMOS_DELAY_CACHE_FLAG      0x0080 /* delay cache initialization */
32#define COBT_CMOS_NOLOGO_FLAG           0x0100 /* hide "C" logo @ boot */
33#define COBT_CMOS_VERSION_FLAG          0x0200 /* the version field is valid */
34#define COBT_CMOS_FLAG_MAX              0x0200
35
36/* leave byte 0x12 blank - Linux looks for drive info here */
37
38/* CMOS structure version, valid if COBT_CMOS_VERSION_FLAG is true */
39#define COBT_CMOS_VERSION               NVRAM_OFFSET(0x13)
40#define COBT_CMOS_VER_BTOCODE           1 /* min. version needed for btocode */
41
42/* index of default boot method */
43#define COBT_CMOS_BOOT_METHOD           NVRAM_OFFSET(0x20)
44#define COBT_CMOS_BOOT_METHOD_DISK      0
45#define COBT_CMOS_BOOT_METHOD_ROM       1
46#define COBT_CMOS_BOOT_METHOD_NET       2
47
48#define COBT_CMOS_BOOT_DEV_MIN          NVRAM_OFFSET(0x21)
49/* major #, minor # of first through fourth boot device */
50#define COBT_CMOS_BOOT_DEV0_MAJ         NVRAM_OFFSET(0x21)
51#define COBT_CMOS_BOOT_DEV0_MIN         NVRAM_OFFSET(0x22)
52#define COBT_CMOS_BOOT_DEV1_MAJ         NVRAM_OFFSET(0x23)
53#define COBT_CMOS_BOOT_DEV1_MIN         NVRAM_OFFSET(0x24)
54#define COBT_CMOS_BOOT_DEV2_MAJ         NVRAM_OFFSET(0x25)
55#define COBT_CMOS_BOOT_DEV2_MIN         NVRAM_OFFSET(0x26)
56#define COBT_CMOS_BOOT_DEV3_MAJ         NVRAM_OFFSET(0x27)
57#define COBT_CMOS_BOOT_DEV3_MIN         NVRAM_OFFSET(0x28)
58#define COBT_CMOS_BOOT_DEV_MAX          NVRAM_OFFSET(0x28)
59
60/* checksum of bytes 0xe-0x7f */
61#define COBT_CMOS_CHECKSUM              NVRAM_OFFSET(0x2e)
62
63/* running uptime counter, units of 5 minutes (32 bits =~ 41000 years) */
64#define COBT_CMOS_UPTIME_0              NVRAM_OFFSET(0x30)
65#define COBT_CMOS_UPTIME_1              NVRAM_OFFSET(0x31)
66#define COBT_CMOS_UPTIME_2              NVRAM_OFFSET(0x32)
67#define COBT_CMOS_UPTIME_3              NVRAM_OFFSET(0x33)
68
69/* count of successful boots (32 bits) */
70#define COBT_CMOS_BOOTCOUNT_0           NVRAM_OFFSET(0x38)
71#define COBT_CMOS_BOOTCOUNT_1           NVRAM_OFFSET(0x39)
72#define COBT_CMOS_BOOTCOUNT_2           NVRAM_OFFSET(0x3a)
73#define COBT_CMOS_BOOTCOUNT_3           NVRAM_OFFSET(0x3b)
74
75/* 13 bytes: system serial number, same as on the back of the system */
76#define COBT_CMOS_SYS_SERNUM_LEN        13
77#define COBT_CMOS_SYS_SERNUM_0          NVRAM_OFFSET(0x40)
78#define COBT_CMOS_SYS_SERNUM_1          NVRAM_OFFSET(0x41)
79#define COBT_CMOS_SYS_SERNUM_2          NVRAM_OFFSET(0x42)
80#define COBT_CMOS_SYS_SERNUM_3          NVRAM_OFFSET(0x43)
81#define COBT_CMOS_SYS_SERNUM_4          NVRAM_OFFSET(0x44)
82#define COBT_CMOS_SYS_SERNUM_5          NVRAM_OFFSET(0x45)
83#define COBT_CMOS_SYS_SERNUM_6          NVRAM_OFFSET(0x46)
84#define COBT_CMOS_SYS_SERNUM_7          NVRAM_OFFSET(0x47)
85#define COBT_CMOS_SYS_SERNUM_8          NVRAM_OFFSET(0x48)
86#define COBT_CMOS_SYS_SERNUM_9          NVRAM_OFFSET(0x49)
87#define COBT_CMOS_SYS_SERNUM_10         NVRAM_OFFSET(0x4a)
88#define COBT_CMOS_SYS_SERNUM_11         NVRAM_OFFSET(0x4b)
89#define COBT_CMOS_SYS_SERNUM_12         NVRAM_OFFSET(0x4c)
90/* checksum for serial num - 1 byte */
91#define COBT_CMOS_SYS_SERNUM_CSUM       NVRAM_OFFSET(0x4f)
92
93#define COBT_CMOS_ROM_REV_MAJ           NVRAM_OFFSET(0x50)
94#define COBT_CMOS_ROM_REV_MIN           NVRAM_OFFSET(0x51)
95#define COBT_CMOS_ROM_REV_REV           NVRAM_OFFSET(0x52)
96
97#define COBT_CMOS_BTO_CODE_0            NVRAM_OFFSET(0x53)
98#define COBT_CMOS_BTO_CODE_1            NVRAM_OFFSET(0x54)
99#define COBT_CMOS_BTO_CODE_2            NVRAM_OFFSET(0x55)
100#define COBT_CMOS_BTO_CODE_3            NVRAM_OFFSET(0x56)
101
102#define COBT_CMOS_BTO_IP_CSUM           NVRAM_OFFSET(0x57)
103#define COBT_CMOS_BTO_IP_0              NVRAM_OFFSET(0x58)
104#define COBT_CMOS_BTO_IP_1              NVRAM_OFFSET(0x59)
105#define COBT_CMOS_BTO_IP_2              NVRAM_OFFSET(0x5a)
106#define COBT_CMOS_BTO_IP_3              NVRAM_OFFSET(0x5b)
107
108#endif /* COBALT_NVRAM_H */
Note: See TracBrowser for help on using the repository browser.