SMBIOS Library
DellMagic.h
Go to the documentation of this file.
1 // vim:expandtab:autoindent:tabstop=4:shiftwidth=4:filetype=c:
2 /*
3  * Copyright (C) 2005 Dell Inc.
4  * by Michael Brown <Michael_E_Brown@dell.com>
5  * Licensed under the Open Software License version 2.1
6  *
7  * Alternatively, you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published
9  * by the Free Software Foundation; either version 2 of the License,
10  * or (at your option) any later version.
11 
12  * This program is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15  * See the GNU General Public License for more details.
16  */
17 
18 #ifndef DELLMAGIC_H
19 #define DELLMAGIC_H
20 
21 // private stuff
22 #define NvramByte1_Token 0x83
23 #define NvramByte2_Token 0x84
24 #define BIOS_Information_Version_Offset 0x05
25 #define System_Information_Manufacturer_Offset 0x04
26 #define System_Information_Product_Name_Offset 0x05
27 #define System_Information_Serial_Number_Offset 0x07
28 #define System_Enclosure_or_Chassis_Service_Offset 0x07
29 #define System_Enclosure_or_Chassis_Asset_Offset 0x08
30 #define ID_Byte_Location 0xFE845
31 #define ID_Word_Location 0xFE840
32 #define Cmos_Asset_Token 0xC000
33 #define Cmos_Service_Token 0xC003
34 #define OEM_String_Field_Number 1
35 #define Bayonet_Detect_String "Dell System"
36 #define DELL_SYSTEM_STRING_LOC 0xFE076
37 #define DELL_SYSTEM_STRING "Dell System"
38 #define DELL_SYSTEM_STRING_LEN 12
39 #define TWO_BYTE_STRUCT_LOC 0xFE840
40 #define DELL_SYSTEM_STRING_LOC_DIAMOND_1 0xD8044
41 #define DELL_SYSTEM_STRING_LOC_DIAMOND_2 0xDC044
42 #define ID_BYTE_LOC_DIAMOND_1 0xD8040
43 #define ID_BYTE_LOC_DIAMOND_2 0xDC040
44 #define SYSTEM_ID_DIAMOND 0x8C
45 #define OEM_Dell_String "Dell"
46 #define OEM_String_Location 0xFE076
47 #define SVC_TAG_CMOS_LEN_MAX 5
48 #define SVC_TAG_LEN_MAX 7
49 #define ASSET_TAG_CMOS_LEN_MAX 10
50 #define ASSET_TAG_LEN_MAX 10
51 
52 namespace smbios
53 {
54 #if defined(_MSC_VER)
55 #pragma pack(push,1)
56 #endif
57  // all of these are packed, so put them all between the above ifdef/below
58  // endif.
59 
60  struct up_info
61  {
62  char anchor[4];
63  u16 stuff1; // anybody know what this is?
65  u16 stuff2; // anybody know what this is?
67  }
69 
71  {
75  u8 checksum; //(offsets 3+4+5 must equal 0)
76  }
78 
80  {
85  u8 checksum; // (offsets 5+6+7 must equal 0)
88  u8 extended_checksum;// ( offsets 0x0 + 0x1 + 0xA + 0xB + extension bytes must equal 0)
90  u8 first_extended_byte; // Brand ID
91  //u8 ... more extension bytes ...
92  }
94 
95 #if defined(_MSC_VER)
96 #pragma pack(pop)
97 #endif
98 }
99 
100 #endif