]> git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
MdePkg: Apply uncrustify changes
[mirror_edk2.git] / MdePkg / Include / IndustryStandard / IpmiNetFnApp.h
1 /** @file
2 IPMI 2.0 definitions from the IPMI Specification Version 2.0, Revision 1.1.
3
4 This file contains all NetFn App commands, including:
5 IPM Device "Global" Commands (Chapter 20)
6 Firmware Firewall & Command Discovery Commands (Chapter 21)
7 BMC Watchdog Timer Commands (Chapter 27)
8 IPMI Messaging Support Commands (Chapter 22)
9 RMCP+ Support and Payload Commands (Chapter 24)
10
11 See IPMI specification, Appendix G, Command Assignments
12 and Appendix H, Sub-function Assignments.
13
14 Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
15 SPDX-License-Identifier: BSD-2-Clause-Patent
16 **/
17
18 #ifndef _IPMI_NET_FN_APP_H_
19 #define _IPMI_NET_FN_APP_H_
20
21 #pragma pack(1)
22 //
23 // Net function definition for App command
24 //
25 #define IPMI_NETFN_APP 0x06
26
27 //
28 // Below is Definitions for IPM Device "Global" Commands (Chapter 20)
29 //
30
31 //
32 // Definitions for Get Device ID command
33 //
34 #define IPMI_APP_GET_DEVICE_ID 0x1
35
36 //
37 // Constants and Structure definitions for "Get Device ID" command to follow here
38 //
39 typedef union {
40 struct {
41 UINT8 DeviceRevision : 4;
42 UINT8 Reserved : 3;
43 UINT8 DeviceSdr : 1;
44 } Bits;
45 UINT8 Uint8;
46 } IPMI_GET_DEVICE_ID_DEVICE_REV;
47
48 typedef union {
49 struct {
50 UINT8 MajorFirmwareRev : 7;
51 UINT8 UpdateMode : 1;
52 } Bits;
53 UINT8 Uint8;
54 } IPMI_GET_DEVICE_ID_FIRMWARE_REV_1;
55
56 typedef union {
57 struct {
58 UINT8 SensorDeviceSupport : 1;
59 UINT8 SdrRepositorySupport : 1;
60 UINT8 SelDeviceSupport : 1;
61 UINT8 FruInventorySupport : 1;
62 UINT8 IpmbMessageReceiver : 1;
63 UINT8 IpmbMessageGenerator : 1;
64 UINT8 BridgeSupport : 1;
65 UINT8 ChassisSupport : 1;
66 } Bits;
67 UINT8 Uint8;
68 } IPMI_GET_DEVICE_ID_DEVICE_SUPPORT;
69
70 typedef struct {
71 UINT8 CompletionCode;
72 UINT8 DeviceId;
73 IPMI_GET_DEVICE_ID_DEVICE_REV DeviceRevision;
74 IPMI_GET_DEVICE_ID_FIRMWARE_REV_1 FirmwareRev1;
75 UINT8 MinorFirmwareRev;
76 UINT8 SpecificationVersion;
77 IPMI_GET_DEVICE_ID_DEVICE_SUPPORT DeviceSupport;
78 UINT8 ManufacturerId[3];
79 UINT16 ProductId;
80 UINT32 AuxFirmwareRevInfo;
81 } IPMI_GET_DEVICE_ID_RESPONSE;
82
83 //
84 // Definitions for Cold Reset command
85 //
86 #define IPMI_APP_COLD_RESET 0x2
87
88 //
89 // Constants and Structure definitions for "Cold Reset" command to follow here
90 //
91
92 //
93 // Definitions for Warm Reset command
94 //
95 #define IPMI_APP_WARM_RESET 0x3
96
97 //
98 // Constants and Structure definitions for "Warm Reset" command to follow here
99 //
100
101 //
102 // Definitions for Get Self Results command
103 //
104 #define IPMI_APP_GET_SELFTEST_RESULTS 0x4
105
106 //
107 // Constants and Structure definitions for "Get Self Test Results" command to follow here
108 //
109 typedef struct {
110 UINT8 CompletionCode;
111 UINT8 Result;
112 UINT8 Param;
113 } IPMI_SELF_TEST_RESULT_RESPONSE;
114
115 #define IPMI_APP_SELFTEST_NO_ERROR 0x55
116 #define IPMI_APP_SELFTEST_NOT_IMPLEMENTED 0x56
117 #define IPMI_APP_SELFTEST_ERROR 0x57
118 #define IPMI_APP_SELFTEST_FATAL_HW_ERROR 0x58
119 #define IPMI_APP_SELFTEST_INACCESSIBLE_SEL 0x80
120 #define IPMI_APP_SELFTEST_INACCESSIBLE_SDR 0x40
121 #define IPMI_APP_SELFTEST_INACCESSIBLE_FRU 0x20
122 #define IPMI_APP_SELFTEST_IPMB_SIGNAL_FAIL 0x10
123 #define IPMI_APP_SELFTEST_SDR_REPOSITORY_EMPTY 0x08
124 #define IPMI_APP_SELFTEST_FRU_CORRUPT 0x04
125 #define IPMI_APP_SELFTEST_FW_BOOTBLOCK_CORRUPT 0x02
126 #define IPMI_APP_SELFTEST_FW_CORRUPT 0x01
127
128 //
129 // Definitions for Manufacturing Test ON command
130 //
131 #define IPMI_APP_MANUFACTURING_TEST_ON 0x5
132
133 //
134 // Constants and Structure definitions for "Manufacturing Test ON" command to follow here
135 //
136
137 //
138 // Definitions for Set ACPI Power State command
139 //
140 #define IPMI_APP_SET_ACPI_POWERSTATE 0x6
141
142 //
143 // Constants and Structure definitions for "Set ACPI Power State" command to follow here
144 //
145
146 //
147 // Definitions for System Power State
148 //
149 // Working
150 #define IPMI_SYSTEM_POWER_STATE_S0_G0 0x0
151 #define IPMI_SYSTEM_POWER_STATE_S1 0x1
152 #define IPMI_SYSTEM_POWER_STATE_S2 0x2
153 #define IPMI_SYSTEM_POWER_STATE_S3 0x3
154 #define IPMI_SYSTEM_POWER_STATE_S4 0x4
155 // Soft off
156 #define IPMI_SYSTEM_POWER_STATE_S5_G2 0x5
157 // Sent when message source cannot differentiate between S4 and S5
158 #define IPMI_SYSTEM_POWER_STATE_S4_S5 0x6
159 // Mechanical off
160 #define IPMI_SYSTEM_POWER_STATE_G3 0x7
161 // Sleeping - cannot differentiate between S1-S3
162 #define IPMI_SYSTEM_POWER_STATE_SLEEPING 0x8
163 // Sleeping - cannot differentiate between S1-S4
164 #define IPMI_SYSTEM_POWER_STATE_G1_SLEEPING 0x9
165 // S5 entered by override
166 #define IPMI_SYSTEM_POWER_STATE_OVERRIDE 0xA
167 #define IPMI_SYSTEM_POWER_STATE_LEGACY_ON 0x20
168 #define IPMI_SYSTEM_POWER_STATE_LEGACY_OFF 0x21
169 #define IPMI_SYSTEM_POWER_STATE_UNKNOWN 0x2A
170 #define IPMI_SYSTEM_POWER_STATE_NO_CHANGE 0x7F
171
172 //
173 // Definitions for Device Power State
174 //
175 #define IPMI_DEVICE_POWER_STATE_D0 0x0
176 #define IPMI_DEVICE_POWER_STATE_D1 0x1
177 #define IPMI_DEVICE_POWER_STATE_D2 0x2
178 #define IPMI_DEVICE_POWER_STATE_D3 0x3
179 #define IPMI_DEVICE_POWER_STATE_UNKNOWN 0x2A
180 #define IPMI_DEVICE_POWER_STATE_NO_CHANGE 0x7F
181
182 typedef union {
183 struct {
184 UINT8 PowerState : 7;
185 UINT8 StateChange : 1;
186 } Bits;
187 UINT8 Uint8;
188 } IPMI_ACPI_POWER_STATE;
189
190 typedef struct {
191 IPMI_ACPI_POWER_STATE SystemPowerState;
192 IPMI_ACPI_POWER_STATE DevicePowerState;
193 } IPMI_SET_ACPI_POWER_STATE_REQUEST;
194
195 //
196 // Definitions for Get ACPI Power State command
197 //
198 #define IPMI_APP_GET_ACPI_POWERSTATE 0x7
199
200 //
201 // Constants and Structure definitions for "Get ACPI Power State" command to follow here
202 //
203
204 //
205 // Definitions for Get Device GUID command
206 //
207 #define IPMI_APP_GET_DEVICE_GUID 0x8
208
209 //
210 // Constants and Structure definitions for "Get Device GUID" command to follow here
211 //
212 //
213 // Message structure definition for "Get Device Guid" IPMI command
214 //
215 typedef struct {
216 UINT8 CompletionCode;
217 UINT8 Guid[16];
218 } IPMI_GET_DEVICE_GUID_RESPONSE;
219
220 //
221 // Below is Definitions for BMC Watchdog Timer Commands (Chapter 27)
222 //
223
224 //
225 // Definitions for Reset WatchDog Timer command
226 //
227 #define IPMI_APP_RESET_WATCHDOG_TIMER 0x22
228
229 //
230 // Definitions for Set WatchDog Timer command
231 //
232 #define IPMI_APP_SET_WATCHDOG_TIMER 0x24
233
234 //
235 // Constants and Structure definitions for "Set WatchDog Timer" command to follow here
236 //
237
238 //
239 // Definitions for watchdog timer use
240 //
241 #define IPMI_WATCHDOG_TIMER_BIOS_FRB2 0x1
242 #define IPMI_WATCHDOG_TIMER_BIOS_POST 0x2
243 #define IPMI_WATCHDOG_TIMER_OS_LOADER 0x3
244 #define IPMI_WATCHDOG_TIMER_SMS 0x4
245 #define IPMI_WATCHDOG_TIMER_OEM 0x5
246
247 //
248 // Structure definition for timer Use
249 //
250 typedef union {
251 struct {
252 UINT8 TimerUse : 3;
253 UINT8 Reserved : 3;
254 UINT8 TimerRunning : 1;
255 UINT8 TimerUseExpirationFlagLog : 1;
256 } Bits;
257 UINT8 Uint8;
258 } IPMI_WATCHDOG_TIMER_USE;
259
260 //
261 // Definitions for watchdog timeout action
262 //
263 #define IPMI_WATCHDOG_TIMER_ACTION_NO_ACTION 0x0
264 #define IPMI_WATCHDOG_TIMER_ACTION_HARD_RESET 0x1
265 #define IPMI_WATCHDOG_TIMER_ACTION_POWER_DONW 0x2
266 #define IPMI_WATCHDOG_TIMER_ACTION_POWER_CYCLE 0x3
267
268 //
269 // Definitions for watchdog pre-timeout interrupt
270 //
271 #define IPMI_WATCHDOG_PRE_TIMEOUT_INTERRUPT_NONE 0x0
272 #define IPMI_WATCHDOG_PRE_TIMEOUT_INTERRUPT_SMI 0x1
273 #define IPMI_WATCHDOG_PRE_TIMEOUT_INTERRUPT_NMI 0x2
274 #define IPMI_WATCHDOG_PRE_TIMEOUT_INTERRUPT_MESSAGING 0x3
275
276 //
277 // Structure definitions for Timer Actions
278 //
279 typedef union {
280 struct {
281 UINT8 TimeoutAction : 3;
282 UINT8 Reserved1 : 1;
283 UINT8 PreTimeoutInterrupt : 3;
284 UINT8 Reserved2 : 1;
285 } Bits;
286 UINT8 Uint8;
287 } IPMI_WATCHDOG_TIMER_ACTIONS;
288
289 //
290 // Bit definitions for Timer use expiration flags
291 //
292 #define IPMI_WATCHDOG_TIMER_EXPIRATION_FLAG_BIOS_FRB2 BIT1
293 #define IPMI_WATCHDOG_TIMER_EXPIRATION_FLAG_BIOS_POST BIT2
294 #define IPMI_WATCHDOG_TIMER_EXPIRATION_FLAG_OS_LOAD BIT3
295 #define IPMI_WATCHDOG_TIMER_EXPIRATION_FLAG_SMS_OS BIT4
296 #define IPMI_WATCHDOG_TIMER_EXPIRATION_FLAG_OEM BIT5
297
298 typedef struct {
299 IPMI_WATCHDOG_TIMER_USE TimerUse;
300 IPMI_WATCHDOG_TIMER_ACTIONS TimerActions;
301 UINT8 PretimeoutInterval;
302 UINT8 TimerUseExpirationFlagsClear;
303 UINT16 InitialCountdownValue;
304 } IPMI_SET_WATCHDOG_TIMER_REQUEST;
305
306 //
307 // Definitions for Get WatchDog Timer command
308 //
309 #define IPMI_APP_GET_WATCHDOG_TIMER 0x25
310
311 //
312 // Constants and Structure definitions for "Get WatchDog Timer" command to follow here
313 //
314 typedef struct {
315 UINT8 CompletionCode;
316 IPMI_WATCHDOG_TIMER_USE TimerUse;
317 IPMI_WATCHDOG_TIMER_ACTIONS TimerActions;
318 UINT8 PretimeoutInterval;
319 UINT8 TimerUseExpirationFlagsClear;
320 UINT16 InitialCountdownValue;
321 UINT16 PresentCountdownValue;
322 } IPMI_GET_WATCHDOG_TIMER_RESPONSE;
323
324 //
325 // Below is Definitions for IPMI Messaging Support Commands (Chapter 22)
326 //
327
328 //
329 // Definitions for Set BMC Global Enables command
330 //
331 #define IPMI_APP_SET_BMC_GLOBAL_ENABLES 0x2E
332
333 //
334 // Constants and Structure definitions for "Set BMC Global Enables " command to follow here
335 //
336 typedef union {
337 struct {
338 UINT8 ReceiveMessageQueueInterrupt : 1;
339 UINT8 EventMessageBufferFullInterrupt : 1;
340 UINT8 EventMessageBuffer : 1;
341 UINT8 SystemEventLogging : 1;
342 UINT8 Reserved : 1;
343 UINT8 Oem0Enable : 1;
344 UINT8 Oem1Enable : 1;
345 UINT8 Oem2Enable : 1;
346 } Bits;
347 UINT8 Uint8;
348 } IPMI_BMC_GLOBAL_ENABLES;
349
350 typedef struct {
351 IPMI_BMC_GLOBAL_ENABLES SetEnables;
352 } IPMI_SET_BMC_GLOBAL_ENABLES_REQUEST;
353
354 //
355 // Definitions for Get BMC Global Enables command
356 //
357 #define IPMI_APP_GET_BMC_GLOBAL_ENABLES 0x2F
358
359 //
360 // Constants and Structure definitions for "Get BMC Global Enables " command to follow here
361 //
362 typedef struct {
363 UINT8 CompletionCode;
364 IPMI_BMC_GLOBAL_ENABLES GetEnables;
365 } IPMI_GET_BMC_GLOBAL_ENABLES_RESPONSE;
366
367 //
368 // Definitions for Clear Message Flags command
369 //
370 #define IPMI_APP_CLEAR_MESSAGE_FLAGS 0x30
371
372 //
373 // Constants and Structure definitions for "Clear Message Flags" command to follow here
374 //
375 typedef union {
376 struct {
377 UINT8 ReceiveMessageQueue : 1;
378 UINT8 EventMessageBuffer : 1;
379 UINT8 Reserved1 : 1;
380 UINT8 WatchdogPerTimeoutInterrupt : 1;
381 UINT8 Reserved2 : 1;
382 UINT8 Oem0 : 1;
383 UINT8 Oem1 : 1;
384 UINT8 Oem2 : 1;
385 } Bits;
386 UINT8 Uint8;
387 } IPMI_MESSAGE_FLAGS;
388
389 typedef struct {
390 IPMI_MESSAGE_FLAGS ClearFlags;
391 } IPMI_CLEAR_MESSAGE_FLAGS_REQUEST;
392
393 //
394 // Definitions for Get Message Flags command
395 //
396 #define IPMI_APP_GET_MESSAGE_FLAGS 0x31
397
398 //
399 // Constants and Structure definitions for "Get Message Flags" command to follow here
400 //
401 typedef struct {
402 UINT8 CompletionCode;
403 IPMI_MESSAGE_FLAGS GetFlags;
404 } IPMI_GET_MESSAGE_FLAGS_RESPONSE;
405
406 //
407 // Definitions for Enable Message Channel Receive command
408 //
409 #define IPMI_APP_ENABLE_MESSAGE_CHANNEL_RECEIVE 0x32
410
411 //
412 // Constants and Structure definitions for "Enable Message Channel Receive" command to follow here
413 //
414
415 //
416 // Definitions for Get Message command
417 //
418 #define IPMI_APP_GET_MESSAGE 0x33
419
420 //
421 // Constants and Structure definitions for "Get Message" command to follow here
422 //
423 typedef union {
424 struct {
425 UINT8 ChannelNumber : 4;
426 UINT8 InferredPrivilegeLevel : 4;
427 } Bits;
428 UINT8 Uint8;
429 } IPMI_GET_MESSAGE_CHANNEL_NUMBER;
430
431 typedef struct {
432 UINT8 CompletionCode;
433 IPMI_GET_MESSAGE_CHANNEL_NUMBER ChannelNumber;
434 UINT8 MessageData[0];
435 } IPMI_GET_MESSAGE_RESPONSE;
436
437 //
438 // Definitions for Send Message command
439 //
440 #define IPMI_APP_SEND_MESSAGE 0x34
441
442 //
443 // Constants and Structure definitions for "Send Message" command to follow here
444 //
445 typedef union {
446 struct {
447 UINT8 ChannelNumber : 4;
448 UINT8 Authentication : 1;
449 UINT8 Encryption : 1;
450 UINT8 Tracking : 2;
451 } Bits;
452 UINT8 Uint8;
453 } IPMI_SEND_MESSAGE_CHANNEL_NUMBER;
454
455 typedef struct {
456 UINT8 CompletionCode;
457 IPMI_SEND_MESSAGE_CHANNEL_NUMBER ChannelNumber;
458 UINT8 MessageData[0];
459 } IPMI_SEND_MESSAGE_REQUEST;
460
461 typedef struct {
462 UINT8 CompletionCode;
463 UINT8 ResponseData[0];
464 } IPMI_SEND_MESSAGE_RESPONSE;
465
466 //
467 // Definitions for Read Event Message Buffer command
468 //
469 #define IPMI_APP_READ_EVENT_MSG_BUFFER 0x35
470
471 //
472 // Constants and Structure definitions for "Read Event Message Buffer" command to follow here
473 //
474
475 //
476 // Definitions for Get BT Interface Capabilities command
477 //
478 #define IPMI_APP_GET_BT_INTERFACE_CAPABILITY 0x36
479
480 //
481 // Constants and Structure definitions for "Get BT Interface Capabilities" command to follow here
482 //
483
484 //
485 // Definitions for Get System GUID command
486 //
487 #define IPMI_APP_GET_SYSTEM_GUID 0x37
488
489 //
490 // Constants and Structure definitions for "Get System GUID" command to follow here
491 //
492
493 //
494 // Definitions for Get Channel Authentication Capabilities command
495 //
496 #define IPMI_APP_GET_CHANNEL_AUTHENTICATION_CAPABILITIES 0x38
497
498 //
499 // Constants and Structure definitions for "Get Channel Authentication Capabilities" command to follow here
500 //
501
502 //
503 // Definitions for Get Session Challenge command
504 //
505 #define IPMI_APP_GET_SESSION_CHALLENGE 0x39
506
507 //
508 // Constants and Structure definitions for "Get Session Challenge" command to follow here
509 //
510
511 //
512 // Definitions for Activate Session command
513 //
514 #define IPMI_APP_ACTIVATE_SESSION 0x3A
515
516 //
517 // Constants and Structure definitions for "Activate Session" command to follow here
518 //
519
520 //
521 // Definitions for Set Session Privelege Level command
522 //
523 #define IPMI_APP_SET_SESSION_PRIVELEGE_LEVEL 0x3B
524
525 //
526 // Constants and Structure definitions for "Set Session Privelege Level" command to follow here
527 //
528
529 //
530 // Definitions for Close Session command
531 //
532 #define IPMI_APP_CLOSE_SESSION 0x3C
533
534 //
535 // Constants and Structure definitions for "Close Session" command to follow here
536 //
537
538 //
539 // Definitions for Get Session Info command
540 //
541 #define IPMI_APP_GET_SESSION_INFO 0x3D
542
543 //
544 // Constants and Structure definitions for "Get Session Info" command to follow here
545 //
546
547 //
548 // Definitions for Get Auth Code command
549 //
550 #define IPMI_APP_GET_AUTHCODE 0x3F
551
552 //
553 // Constants and Structure definitions for "Get AuthCode" command to follow here
554 //
555
556 //
557 // Definitions for Set Channel Access command
558 //
559 #define IPMI_APP_SET_CHANNEL_ACCESS 0x40
560
561 //
562 // Constants and Structure definitions for "Set Channel Access" command to follow here
563 //
564
565 //
566 // Definitions for Get Channel Access command
567 //
568 #define IPMI_APP_GET_CHANNEL_ACCESS 0x41
569
570 //
571 // Constants and Structure definitions for "Get Channel Access" command to follow here
572 //
573
574 //
575 // Definitions for channel access memory type in Get Channel Access command request
576 //
577 #define IPMI_CHANNEL_ACCESS_MEMORY_TYPE_NON_VOLATILE 0x1
578 #define IPMI_CHANNEL_ACCESS_MEMORY_TYPE_PRESENT_VOLATILE_SETTING 0x2
579
580 //
581 // Definitions for channel access modes in Get Channel Access command response
582 //
583 #define IPMI_CHANNEL_ACCESS_MODES_DISABLED 0x0
584 #define IPMI_CHANNEL_ACCESS_MODES_PRE_BOOT_ONLY 0x1
585 #define IPMI_CHANNEL_ACCESS_MODES_ALWAYS_AVAILABLE 0x2
586 #define IPMI_CHANNEL_ACCESS_MODES_SHARED 0x3
587
588 typedef union {
589 struct {
590 UINT8 ChannelNo : 4;
591 UINT8 Reserved : 4;
592 } Bits;
593 UINT8 Uint8;
594 } IPMI_GET_CHANNEL_ACCESS_CHANNEL_NUMBER;
595
596 typedef union {
597 struct {
598 UINT8 Reserved : 6;
599 UINT8 MemoryType : 2;
600 } Bits;
601 UINT8 Uint8;
602 } IPMI_GET_CHANNEL_ACCESS_TYPE;
603
604 typedef struct {
605 IPMI_GET_CHANNEL_ACCESS_CHANNEL_NUMBER ChannelNumber;
606 IPMI_GET_CHANNEL_ACCESS_TYPE AccessType;
607 } IPMI_GET_CHANNEL_ACCESS_REQUEST;
608
609 typedef union {
610 struct {
611 UINT8 AccessMode : 3;
612 UINT8 UserLevelAuthEnabled : 1;
613 UINT8 MessageAuthEnable : 1;
614 UINT8 Alert : 1;
615 UINT8 Reserved : 2;
616 } Bits;
617 UINT8 Uint8;
618 } IPMI_GET_CHANNEL_ACCESS_CHANNEL_ACCESS;
619
620 typedef union {
621 struct {
622 UINT8 ChannelPriviledgeLimit : 4;
623 UINT8 Reserved : 4;
624 } Bits;
625 UINT8 Uint8;
626 } IPMI_GET_CHANNEL_ACCESS_PRIVILEGE_LIMIT;
627
628 typedef struct {
629 UINT8 CompletionCode;
630 IPMI_GET_CHANNEL_ACCESS_CHANNEL_ACCESS ChannelAccess;
631 IPMI_GET_CHANNEL_ACCESS_PRIVILEGE_LIMIT PrivilegeLimit;
632 } IPMI_GET_CHANNEL_ACCESS_RESPONSE;
633
634 //
635 // Definitions for Get Channel Info command
636 //
637 #define IPMI_APP_GET_CHANNEL_INFO 0x42
638
639 //
640 // Constants and Structure definitions for "Get Channel Info" command to follow here
641 //
642
643 //
644 // Definitions for channel media type
645 //
646 // IPMB (I2C)
647 #define IPMI_CHANNEL_MEDIA_TYPE_IPMB 0x1
648 // ICMB v1.0
649 #define IPMI_CHANNEL_MEDIA_TYPE_ICMB_1_0 0x2
650 // ICMB v0.9
651 #define IPMI_CHANNEL_MEDIA_TYPE_ICMB_0_9 0x3
652 // 802.3 LAN
653 #define IPMI_CHANNEL_MEDIA_TYPE_802_3_LAN 0x4
654 // Asynch. Serial/Modem (RS-232)
655 #define IPMI_CHANNEL_MEDIA_TYPE_RS_232 0x5
656 // Other LAN
657 #define IPMI_CHANNEL_MEDIA_TYPE_OTHER_LAN 0x6
658 // PCI SMBus
659 #define IPMI_CHANNEL_MEDIA_TYPE_PCI_SM_BUS 0x7
660 // SMBus v1.0/1.1
661 #define IPMI_CHANNEL_MEDIA_TYPE_SM_BUS_V1 0x8
662 // SMBus v2.0
663 #define IPMI_CHANNEL_MEDIA_TYPE_SM_BUS_V2 0x9
664 // USB 1.x
665 #define IPMI_CHANNEL_MEDIA_TYPE_USB1 0xA
666 // USB 2.x
667 #define IPMI_CHANNEL_MEDIA_TYPE_USB2 0xB
668 // System Interface (KCS, SMIC, or BT)
669 #define IPMI_CHANNEL_MEDIA_TYPE_SYSTEM_INTERFACE 0xC
670 // OEM
671 #define IPMI_CHANNEL_MEDIA_TYPE_OEM_START 0x60
672 #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END 0x7F
673
674 typedef union {
675 struct {
676 UINT8 ChannelNo : 4;
677 UINT8 Reserved : 4;
678 } Bits;
679 UINT8 Uint8;
680 } IPMI_CHANNEL_INFO_CHANNEL_NUMBER;
681
682 typedef union {
683 struct {
684 UINT8 ChannelMediumType : 7;
685 UINT8 Reserved : 1;
686 } Bits;
687 UINT8 Uint8;
688 } IPMI_CHANNEL_INFO_MEDIUM_TYPE;
689
690 typedef union {
691 struct {
692 UINT8 ChannelProtocolType : 5;
693 UINT8 Reserved : 3;
694 } Bits;
695 UINT8 Uint8;
696 } IPMI_CHANNEL_INFO_PROTOCOL_TYPE;
697
698 typedef union {
699 struct {
700 UINT8 ActiveSessionCount : 6;
701 UINT8 SessionSupport : 2;
702 } Bits;
703 UINT8 Uint8;
704 } IPMI_CHANNEL_INFO_SESSION_SUPPORT;
705
706 typedef struct {
707 UINT8 CompletionCode;
708 IPMI_CHANNEL_INFO_CHANNEL_NUMBER ChannelNumber;
709 IPMI_CHANNEL_INFO_MEDIUM_TYPE MediumType;
710 IPMI_CHANNEL_INFO_PROTOCOL_TYPE ProtocolType;
711 IPMI_CHANNEL_INFO_SESSION_SUPPORT SessionSupport;
712 UINT8 VendorId[3];
713 UINT16 AuxChannelInfo;
714 } IPMI_GET_CHANNEL_INFO_RESPONSE;
715
716 //
717 // Definitions for Get Channel Info command
718 //
719 #define IPMI_APP_GET_CHANNEL_INFO 0x42
720
721 //
722 // Constants and Structure definitions for "Get Channel Info" command to follow here
723 //
724
725 //
726 // Definitions for Set User Access command
727 //
728 #define IPMI_APP_SET_USER_ACCESS 0x43
729
730 //
731 // Constants and Structure definitions for "Set User Access" command to follow here
732 //
733
734 //
735 // Definitions for Get User Access command
736 //
737 #define IPMI_APP_GET_USER_ACCESS 0x44
738
739 //
740 // Constants and Structure definitions for "Get User Access" command to follow here
741 //
742 typedef union {
743 struct {
744 UINT8 ChannelNo : 4;
745 UINT8 Reserved : 4;
746 } Bits;
747 UINT8 Uint8;
748 } IPMI_GET_USER_ACCESS_CHANNEL_NUMBER;
749
750 typedef union {
751 struct {
752 UINT8 UserId : 6;
753 UINT8 Reserved : 2;
754 } Bits;
755 UINT8 Uint8;
756 } IPMI_USER_ID;
757
758 typedef struct {
759 IPMI_GET_USER_ACCESS_CHANNEL_NUMBER ChannelNumber;
760 IPMI_USER_ID UserId;
761 } IPMI_GET_USER_ACCESS_REQUEST;
762
763 typedef union {
764 struct {
765 UINT8 MaxUserId : 6;
766 UINT8 Reserved : 2;
767 } Bits;
768 UINT8 Uint8;
769 } IPMI_GET_USER_ACCESS_MAX_USER_ID;
770
771 typedef union {
772 struct {
773 UINT8 CurrentUserId : 6;
774 UINT8 UserIdEnableStatus : 2;
775 } Bits;
776 UINT8 Uint8;
777 } IPMI_GET_USER_ACCESS_CURRENT_USER;
778
779 typedef union {
780 struct {
781 UINT8 FixedUserId : 6;
782 UINT8 Reserved : 2;
783 } Bits;
784 UINT8 Uint8;
785 } IPMI_GET_USER_ACCESS_FIXED_NAME_USER;
786
787 typedef union {
788 struct {
789 UINT8 UserPrivilegeLimit : 4;
790 UINT8 EnableIpmiMessaging : 1;
791 UINT8 EnableUserLinkAuthetication : 1;
792 UINT8 UserAccessAvailable : 1;
793 UINT8 Reserved : 1;
794 } Bits;
795 UINT8 Uint8;
796 } IPMI_GET_USER_ACCESS_CHANNEL_ACCESS;
797
798 typedef struct {
799 UINT8 CompletionCode;
800 IPMI_GET_USER_ACCESS_MAX_USER_ID MaxUserId;
801 IPMI_GET_USER_ACCESS_CURRENT_USER CurrentUser;
802 IPMI_GET_USER_ACCESS_FIXED_NAME_USER FixedNameUser;
803 IPMI_GET_USER_ACCESS_CHANNEL_ACCESS ChannelAccess;
804 } IPMI_GET_USER_ACCESS_RESPONSE;
805
806 //
807 // Definitions for Set User Name command
808 //
809 #define IPMI_APP_SET_USER_NAME 0x45
810
811 //
812 // Constants and Structure definitions for "Set User Name" command to follow here
813 //
814 typedef struct {
815 IPMI_USER_ID UserId;
816 UINT8 UserName[16];
817 } IPMI_SET_USER_NAME_REQUEST;
818
819 //
820 // Definitions for Get User Name command
821 //
822 #define IPMI_APP_GET_USER_NAME 0x46
823
824 //
825 // Constants and Structure definitions for "Get User Name" command to follow here
826 //
827 typedef struct {
828 IPMI_USER_ID UserId;
829 } IPMI_GET_USER_NAME_REQUEST;
830
831 typedef struct {
832 UINT8 CompletionCode;
833 UINT8 UserName[16];
834 } IPMI_GET_USER_NAME_RESPONSE;
835
836 //
837 // Definitions for Set User Password command
838 //
839 #define IPMI_APP_SET_USER_PASSWORD 0x47
840
841 //
842 // Constants and Structure definitions for "Set User Password" command to follow here
843 //
844
845 //
846 // Definitions for Set User password command operation type
847 //
848 #define IPMI_SET_USER_PASSWORD_OPERATION_TYPE_DISABLE_USER 0x0
849 #define IPMI_SET_USER_PASSWORD_OPERATION_TYPE_ENABLE_USER 0x1
850 #define IPMI_SET_USER_PASSWORD_OPERATION_TYPE_SET_PASSWORD 0x2
851 #define IPMI_SET_USER_PASSWORD_OPERATION_TYPE_TEST_PASSWORD 0x3
852
853 //
854 // Definitions for Set user password command password size
855 //
856 #define IPMI_SET_USER_PASSWORD_PASSWORD_SIZE_16 0x0
857 #define IPMI_SET_USER_PASSWORD_PASSWORD_SIZE_20 0x1
858
859 typedef union {
860 struct {
861 UINT8 UserId : 6;
862 UINT8 Reserved : 1;
863 UINT8 PasswordSize : 1;
864 } Bits;
865 UINT8 Uint8;
866 } IPMI_SET_USER_PASSWORD_USER_ID;
867
868 typedef union {
869 struct {
870 UINT8 Operation : 2;
871 UINT8 Reserved : 6;
872 } Bits;
873 UINT8 Uint8;
874 } IPMI_SET_USER_PASSWORD_OPERATION;
875
876 typedef struct {
877 IPMI_SET_USER_PASSWORD_USER_ID UserId;
878 IPMI_SET_USER_PASSWORD_OPERATION Operation;
879 UINT8 PasswordData[0]; // 16 or 20 bytes, depending on the 'PasswordSize' field
880 } IPMI_SET_USER_PASSWORD_REQUEST;
881
882 //
883 // Below is Definitions for RMCP+ Support and Payload Commands (Chapter 24)
884 //
885
886 //
887 // Definitions for Activate Payload command
888 //
889 #define IPMI_APP_ACTIVATE_PAYLOAD 0x48
890
891 //
892 // Constants and Structure definitions for "Activate Payload" command to follow here
893 //
894
895 //
896 // Definitions for De-Activate Payload command
897 //
898 #define IPMI_APP_DEACTIVATE_PAYLOAD 0x49
899
900 //
901 // Constants and Structure definitions for "DeActivate Payload" command to follow here
902 //
903
904 //
905 // Definitions for Get Payload activation Status command
906 //
907 #define IPMI_APP_GET_PAYLOAD_ACTIVATION_STATUS 0x4a
908
909 //
910 // Constants and Structure definitions for "Get Payload activation Status" command to follow here
911 //
912
913 //
914 // Definitions for Get Payload Instance Info command
915 //
916 #define IPMI_APP_GET_PAYLOAD_INSTANCE_INFO 0x4b
917
918 //
919 // Constants and Structure definitions for "Get Payload Instance Info" command to follow here
920 //
921
922 //
923 // Definitions for Set User Payload Access command
924 //
925 #define IPMI_APP_SET_USER_PAYLOAD_ACCESS 0x4C
926
927 //
928 // Constants and Structure definitions for "Set User Payload Access" command to follow here
929 //
930
931 //
932 // Definitions for Get User Payload Access command
933 //
934 #define IPMI_APP_GET_USER_PAYLOAD_ACCESS 0x4D
935
936 //
937 // Constants and Structure definitions for "Get User Payload Access" command to follow here
938 //
939
940 //
941 // Definitions for Get Channel Payload Support command
942 //
943 #define IPMI_APP_GET_CHANNEL_PAYLOAD_SUPPORT 0x4E
944
945 //
946 // Constants and Structure definitions for "Get Channel Payload Support" command to follow here
947 //
948
949 //
950 // Definitions for Get Channel Payload Version command
951 //
952 #define IPMI_APP_GET_CHANNEL_PAYLOAD_VERSION 0x4F
953
954 //
955 // Constants and Structure definitions for "Get Channel Payload Version" command to follow here
956 //
957
958 //
959 // Definitions for Get Channel OEM Payload Info command
960 //
961 #define IPMI_APP_GET_CHANNEL_OEM_PAYLOAD_INFO 0x50
962
963 //
964 // Constants and Structure definitions for "Get Channel OEM Payload Info" command to follow here
965 //
966
967 //
968 // Definitions for Master Write-Read command
969 //
970 #define IPMI_APP_MASTER_WRITE_READ 0x52
971
972 //
973 // Constants and Structure definitions for "Master Write Read" command to follow here
974 //
975
976 //
977 // Definitions for Get Channel Cipher Suites command
978 //
979 #define IPMI_APP_GET_CHANNEL_CIPHER_SUITES 0x54
980
981 //
982 // Constants and Structure definitions for "Get Channel Cipher Suites" command to follow here
983 //
984
985 //
986 // Below is Definitions for RMCP+ Support and Payload Commands (Chapter 24, Section 3)
987 //
988
989 //
990 // Definitions for Suspend-Resume Payload Encryption command
991 //
992 #define IPMI_APP_SUSPEND_RESUME_PAYLOAD_ENCRYPTION 0x55
993
994 //
995 // Constants and Structure definitions for "Suspend-Resume Payload Encryption" command to follow here
996 //
997
998 //
999 // Below is Definitions for IPMI Messaging Support Commands (Chapter 22, Section 25 and 9)
1000 //
1001
1002 //
1003 // Definitions for Set Channel Security Keys command
1004 //
1005 #define IPMI_APP_SET_CHANNEL_SECURITY_KEYS 0x56
1006
1007 //
1008 // Constants and Structure definitions for "Set Channel Security Keys" command to follow here
1009 //
1010
1011 //
1012 // Definitions for Get System Interface Capabilities command
1013 //
1014 #define IPMI_APP_GET_SYSTEM_INTERFACE_CAPABILITIES 0x57
1015
1016 //
1017 // Constants and Structure definitions for "Get System Interface Capabilities" command to follow here
1018 //
1019
1020 //
1021 // Definitions for Get System Interface Capabilities command SSIF transaction support
1022 //
1023 #define IPMI_GET_SYSTEM_INTERFACE_CAPABILITIES_SSIF_TRANSACTION_SUPPORT_SINGLE_PARTITION_RW 0x0
1024 #define IPMI_GET_SYSTEM_INTERFACE_CAPABILITIES_SSIF_TRANSACTION_SUPPORT_MULTI_PARTITION_RW 0x1
1025 #define IPMI_GET_SYSTEM_INTERFACE_CAPABILITIES_SSIF_TRANSACTION_SUPPORT_MULTI_PARTITION_RW_WITH_MIDDLE 0x2
1026
1027 #pragma pack()
1028 #endif