1 /** @file
2 This driver parses the mMiscSubclassDataTable structure and reports
3 any generated data to the DataHub.
4 
5 Copyright (c) 2013-2015 Intel Corporation.
6 
7 This program and the accompanying materials
8 are licensed and made available under the terms and conditions of the BSD License
9 which accompanies this distribution.  The full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
11 
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
14 
15 
16 **/
17 
18 
19 #include "CommonHeader.h"
20 
21 #include "SmbiosMisc.h"
22 
23 
24 //
25 // Static (possibly build generated) Bios Vendor data.
26 //
27 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot1) = {
28   STRING_TOKEN(STR_MISC_SYSTEM_SLOT1),        // SlotDesignation
29   EfiSlotTypePci,                             // SlotType
30   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
31   EfiSlotUsageAvailable,                      // SlotUsage
32   EfiSlotLengthLong ,                         // SlotLength
33   1,                                          // SlotId
34   {                                           // SlotCharacteristics
35     0,                                        // CharacteristicsUnknown  :1;
36     0,                                        // Provides50Volts         :1;
37     1,                                        // Provides33Volts         :1;
38     0,                                        // SharedSlot              :1;
39     0,                                        // PcCard16Supported       :1;
40     0,                                        // CardBusSupported        :1;
41     0,                                        // ZoomVideoSupported      :1;
42     0,                                        // ModemRingResumeSupported:1;
43     1,                                        // PmeSignalSupported      :1;
44     0,                                        // HotPlugDevicesSupported :1;
45     1,                                        // SmbusSignalSupported    :1;
46     0                                         // Reserved                :21;
47   },
48   {0}                                           // SlotDevicePath
49 };
50 
51 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot2) = {
52   STRING_TOKEN(STR_MISC_SYSTEM_SLOT2),        // SlotDesignation
53   EfiSlotTypePciExpress,                      // SlotType
54   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
55   EfiSlotUsageAvailable,                      // SlotUsage
56   EfiSlotLengthLong ,                         // SlotLength
57   1,                                          // SlotId
58   {                                           // SlotCharacteristics
59     0,                                        // CharacteristicsUnknown  :1;
60     0,                                        // Provides50Volts         :1;
61     1,                                        // Provides33Volts         :1;
62     0,                                        // SharedSlot              :1;
63     0,                                        // PcCard16Supported       :1;
64     0,                                        // CardBusSupported        :1;
65     0,                                        // ZoomVideoSupported      :1;
66     0,                                        // ModemRingResumeSupported:1;
67     1,                                        // PmeSignalSupported      :1;
68     1,                                        // HotPlugDevicesSupported :1;
69     1,                                        // SmbusSignalSupported    :1;
70     0                                         // Reserved                :21;
71   },
72   {0}                                           // SlotDevicePath
73 };
74 
75 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot3) = {
76   STRING_TOKEN(STR_MISC_SYSTEM_SLOT3),        // SlotDesignation
77   EfiSlotTypePciExpress,                      // SlotType
78   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
79   EfiSlotUsageAvailable,                      // SlotUsage
80   EfiSlotLengthLong ,                         // SlotLength
81   2,                                          // SlotId
82   {                                           // SlotCharacteristics
83     0,                                        // CharacteristicsUnknown  :1;
84     0,                                        // Provides50Volts         :1;
85     1,                                        // Provides33Volts         :1;
86     0,                                        // SharedSlot              :1;
87     0,                                        // PcCard16Supported       :1;
88     0,                                        // CardBusSupported        :1;
89     0,                                        // ZoomVideoSupported      :1;
90     0,                                        // ModemRingResumeSupported:1;
91     1,                                        // PmeSignalSupported      :1;
92     1,                                        // HotPlugDevicesSupported :1;
93     1,                                        // SmbusSignalSupported    :1;
94     0                                         // Reserved                :21;
95   },
96   {0}                                           // SlotDevicePath
97 };
98 
99 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot4) = {
100   STRING_TOKEN(STR_MISC_SYSTEM_SLOT4),        // SlotDesignation
101   EfiSlotTypePciExpress,                      // SlotType
102   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
103   EfiSlotUsageAvailable,                      // SlotUsage
104   EfiSlotLengthLong ,                         // SlotLength
105   2,                                          // SlotId
106   {                                           // SlotCharacteristics
107     0,                                        // CharacteristicsUnknown  :1;
108     0,                                        // Provides50Volts         :1;
109     1,                                        // Provides33Volts         :1;
110     0,                                        // SharedSlot              :1;
111     0,                                        // PcCard16Supported       :1;
112     0,                                        // CardBusSupported        :1;
113     0,                                        // ZoomVideoSupported      :1;
114     0,                                        // ModemRingResumeSupported:1;
115     1,                                        // PmeSignalSupported      :1;
116     1,                                        // HotPlugDevicesSupported :1;
117     1,                                        // SmbusSignalSupported    :1;
118     0                                         // Reserved                :21;
119   },
120   {0}                                           // SlotDevicePath
121 };
122 
123 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot5) = {
124   STRING_TOKEN(STR_MISC_SYSTEM_SLOT5),        // SlotDesignation
125   EfiSlotTypePciExpress,                      // SlotType
126   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
127   EfiSlotUsageAvailable,                      // SlotUsage
128   EfiSlotLengthLong ,                         // SlotLength
129   3,                                          // SlotId
130   {                                           // SlotCharacteristics
131     0,                                        // CharacteristicsUnknown  :1;
132     0,                                        // Provides50Volts         :1;
133     1,                                        // Provides33Volts         :1;
134     0,                                        // SharedSlot              :1;
135     0,                                        // PcCard16Supported       :1;
136     0,                                        // CardBusSupported        :1;
137     0,                                        // ZoomVideoSupported      :1;
138     0,                                        // ModemRingResumeSupported:1;
139     1,                                        // PmeSignalSupported      :1;
140     1,                                        // HotPlugDevicesSupported :1;
141     1,                                        // SmbusSignalSupported    :1;
142     0                                         // Reserved                :21;
143   },
144   {0}                                           // SlotDevicePath
145 };
146 
147 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot6) = {
148   STRING_TOKEN(STR_MISC_SYSTEM_SLOT6),        // SlotDesignation
149   EfiSlotTypePciExpress,                      // SlotType
150   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
151   EfiSlotUsageAvailable,                      // SlotUsage
152   EfiSlotLengthLong ,                         // SlotLength
153   3,                                          // SlotId
154   {                                           // SlotCharacteristics
155     0,                                        // CharacteristicsUnknown  :1;
156     0,                                        // Provides50Volts         :1;
157     1,                                        // Provides33Volts         :1;
158     0,                                        // SharedSlot              :1;
159     0,                                        // PcCard16Supported       :1;
160     0,                                        // CardBusSupported        :1;
161     0,                                        // ZoomVideoSupported      :1;
162     0,                                        // ModemRingResumeSupported:1;
163     1,                                        // PmeSignalSupported      :1;
164     1,                                        // HotPlugDevicesSupported :1;
165     1,                                        // SmbusSignalSupported    :1;
166     0                                         // Reserved                :21;
167   },
168   {0}                                           // SlotDevicePath
169 };
170 
171 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot7) = {
172   STRING_TOKEN(STR_MISC_SYSTEM_SLOT7),        // SlotDesignation
173   EfiSlotTypePciExpress,                      // SlotType
174   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
175   EfiSlotUsageAvailable,                      // SlotUsage
176   EfiSlotLengthLong ,                         // SlotLength
177   3,                                          // SlotId
178   {                                           // SlotCharacteristics
179     0,                                        // CharacteristicsUnknown  :1;
180     0,                                        // Provides50Volts         :1;
181     1,                                        // Provides33Volts         :1;
182     0,                                        // SharedSlot              :1;
183     0,                                        // PcCard16Supported       :1;
184     0,                                        // CardBusSupported        :1;
185     0,                                        // ZoomVideoSupported      :1;
186     0,                                        // ModemRingResumeSupported:1;
187     1,                                        // PmeSignalSupported      :1;
188     1,                                        // HotPlugDevicesSupported :1;
189     1,                                        // SmbusSignalSupported    :1;
190     0                                         // Reserved                :21;
191   },
192   {0}                                           // SlotDevicePath
193 };
194 
195 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot8) = {
196   STRING_TOKEN(STR_MISC_SYSTEM_SLOT8),        // SlotDesignation
197   EfiSlotTypePciExpress,                      // SlotType
198   EfiSlotDataBusWidth32Bit,                   // SlotDataBusWidth
199   EfiSlotUsageAvailable,                      // SlotUsage
200   EfiSlotLengthLong ,                         // SlotLength
201   3,                                          // SlotId
202   {                                           // SlotCharacteristics
203     0,                                        // CharacteristicsUnknown  :1;
204     0,                                        // Provides50Volts         :1;
205     1,                                        // Provides33Volts         :1;
206     0,                                        // SharedSlot              :1;
207     0,                                        // PcCard16Supported       :1;
208     0,                                        // CardBusSupported        :1;
209     0,                                        // ZoomVideoSupported      :1;
210     0,                                        // ModemRingResumeSupported:1;
211     1,                                        // PmeSignalSupported      :1;
212     1,                                        // HotPlugDevicesSupported :1;
213     1,                                        // SmbusSignalSupported    :1;
214     0                                         // Reserved                :21;
215   },
216   {0}                                           // SlotDevicePath
217 };
218 
219 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot9) = {
220   STRING_TOKEN(STR_MISC_SYSTEM_SLOT9),        // SlotDesignation
221   EfiSlotTypeUnknown,                         // SlotType
222   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
223   EfiSlotUsageUnknown,                        // SlotUsage
224   EfiSlotLengthUnknown ,                      // SlotLength
225   0,                                          // SlotId
226   {                                           // SlotCharacteristics
227     0,                                        // CharacteristicsUnknown  :1;
228     0,                                        // Provides50Volts         :1;
229     1,                                        // Provides33Volts         :1;
230     0,                                        // SharedSlot              :1;
231     0,                                        // PcCard16Supported       :1;
232     0,                                        // CardBusSupported        :1;
233     0,                                        // ZoomVideoSupported      :1;
234     0,                                        // ModemRingResumeSupported:1;
235     1,                                        // PmeSignalSupported      :1;
236     1,                                        // HotPlugDevicesSupported :1;
237     1,                                        // SmbusSignalSupported    :1;
238     0                                         // Reserved                :21;
239   },
240   {0}                                           // SlotDevicePath
241 };
242 
243 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot10) = {
244   STRING_TOKEN(STR_MISC_SYSTEM_SLOT10),       // SlotDesignation
245   EfiSlotTypeUnknown,                         // SlotType
246   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
247   EfiSlotUsageUnknown,                        // SlotUsage
248   EfiSlotLengthUnknown ,                      // SlotLength
249   0,                                          // SlotId
250   {                                           // SlotCharacteristics
251     0,                                        // CharacteristicsUnknown  :1;
252     0,                                        // Provides50Volts         :1;
253     1,                                        // Provides33Volts         :1;
254     0,                                        // SharedSlot              :1;
255     0,                                        // PcCard16Supported       :1;
256     0,                                        // CardBusSupported        :1;
257     0,                                        // ZoomVideoSupported      :1;
258     0,                                        // ModemRingResumeSupported:1;
259     1,                                        // PmeSignalSupported      :1;
260     1,                                        // HotPlugDevicesSupported :1;
261     1,                                        // SmbusSignalSupported    :1;
262     0                                         // Reserved                :21;
263   },
264   {0}                                           // SlotDevicePath
265 };
266 
267 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot11) = {
268   STRING_TOKEN(STR_MISC_SYSTEM_SLOT11),       // SlotDesignation
269   EfiSlotTypeUnknown,                         // SlotType
270   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
271   EfiSlotUsageUnknown,                        // SlotUsage
272   EfiSlotLengthUnknown ,                      // SlotLength
273   0,                                          // SlotId
274   {                                           // SlotCharacteristics
275     0,                                        // CharacteristicsUnknown  :1;
276     0,                                        // Provides50Volts         :1;
277     1,                                        // Provides33Volts         :1;
278     0,                                        // SharedSlot              :1;
279     0,                                        // PcCard16Supported       :1;
280     0,                                        // CardBusSupported        :1;
281     0,                                        // ZoomVideoSupported      :1;
282     0,                                        // ModemRingResumeSupported:1;
283     1,                                        // PmeSignalSupported      :1;
284     1,                                        // HotPlugDevicesSupported :1;
285     1,                                        // SmbusSignalSupported    :1;
286     0                                         // Reserved                :21;
287   },
288   {0}                                           // SlotDevicePath
289 };
290 
291 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot12) = {
292   STRING_TOKEN(STR_MISC_SYSTEM_SLOT12),       // SlotDesignation
293   EfiSlotTypeUnknown,                         // SlotType
294   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
295   EfiSlotUsageUnknown,                        // SlotUsage
296   EfiSlotLengthUnknown ,                      // SlotLength
297   0,                                          // SlotId
298   {                                           // SlotCharacteristics
299     0,                                        // CharacteristicsUnknown  :1;
300     0,                                        // Provides50Volts         :1;
301     1,                                        // Provides33Volts         :1;
302     0,                                        // SharedSlot              :1;
303     0,                                        // PcCard16Supported       :1;
304     0,                                        // CardBusSupported        :1;
305     0,                                        // ZoomVideoSupported      :1;
306     0,                                        // ModemRingResumeSupported:1;
307     1,                                        // PmeSignalSupported      :1;
308     1,                                        // HotPlugDevicesSupported :1;
309     1,                                        // SmbusSignalSupported    :1;
310     0                                         // Reserved                :21;
311   },
312   {0}                                           // SlotDevicePath
313 };
314 
315 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot13) = {
316   STRING_TOKEN(STR_MISC_SYSTEM_SLOT13),       // SlotDesignation
317   EfiSlotTypeUnknown,                         // SlotType
318   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
319   EfiSlotUsageUnknown,                        // SlotUsage
320   EfiSlotLengthUnknown ,                      // SlotLength
321   0,                                          // SlotId
322   {                                           // SlotCharacteristics
323     0,                                        // CharacteristicsUnknown  :1;
324     0,                                        // Provides50Volts         :1;
325     1,                                        // Provides33Volts         :1;
326     0,                                        // SharedSlot              :1;
327     0,                                        // PcCard16Supported       :1;
328     0,                                        // CardBusSupported        :1;
329     0,                                        // ZoomVideoSupported      :1;
330     0,                                        // ModemRingResumeSupported:1;
331     1,                                        // PmeSignalSupported      :1;
332     1,                                        // HotPlugDevicesSupported :1;
333     1,                                        // SmbusSignalSupported    :1;
334     0                                         // Reserved                :21;
335   },
336   {0}                                           // SlotDevicePath
337 };
338 
339 MISC_SMBIOS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlot14) = {
340   STRING_TOKEN(STR_MISC_SYSTEM_SLOT14),       // SlotDesignation
341   EfiSlotTypeUnknown,                         // SlotType
342   EfiSlotDataBusWidthUnknown,                 // SlotDataBusWidth
343   EfiSlotUsageUnknown,                        // SlotUsage
344   EfiSlotLengthUnknown ,                      // SlotLength
345   0,                                          // SlotId
346   {                                           // SlotCharacteristics
347     0,                                        // CharacteristicsUnknown  :1;
348     0,                                        // Provides50Volts         :1;
349     1,                                        // Provides33Volts         :1;
350     0,                                        // SharedSlot              :1;
351     0,                                        // PcCard16Supported       :1;
352     0,                                        // CardBusSupported        :1;
353     0,                                        // ZoomVideoSupported      :1;
354     0,                                        // ModemRingResumeSupported:1;
355     1,                                        // PmeSignalSupported      :1;
356     1,                                        // HotPlugDevicesSupported :1;
357     1,                                        // SmbusSignalSupported    :1;
358     0                                         // Reserved                :21;
359   },
360   {0}                                           // SlotDevicePath
361 };
362 
363 
364