IPMI_SDR.h 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204
  1. /*****************************************************************
  2. *****************************************************************
  3. *** **
  4. *** (C)Copyright 2005-2006, American Megatrends Inc. **
  5. *** **
  6. *** All Rights Reserved. **
  7. *** **
  8. *** 6145-F, Northbelt Parkway, Norcross, **
  9. *** **
  10. *** Georgia - 30071, USA. Phone-(770)-246-8600. **
  11. *** **
  12. *****************************************************************
  13. *****************************************************************
  14. ******************************************************************
  15. *
  16. * ipmi_sdr.c
  17. * IPMI SDR Record
  18. *
  19. * Author: Govind Kothandapani <govindk@ami.com>
  20. *
  21. ******************************************************************/
  22. #ifndef IPMI_SDR_H
  23. #define IPMI_SDR_H
  24. #include "Types.h"
  25. /*** External Definitions ***/
  26. #define INVALID_RECORD_ID 0x00
  27. #define OVERFLOW_FLAG 0x80
  28. #pragma pack( 1 )
  29. /* SDRRepositoryInfo_T */
  30. typedef struct
  31. {
  32. INT8U CompletionCode; /* Completion Code */
  33. INT8U Version; /* Version of the SDR 0x51 */
  34. INT16U RecCt; /* Record Count */
  35. INT16U FreeSpace; /* Free space LSB first */
  36. INT32U AddTimeStamp; /* Most recent addition timestamp */
  37. INT32U EraseTimeStamp; /* Most recent erase timestamp */
  38. INT8U OpSupport; /* Operation Support */
  39. } PACKED SDRRepositoryInfo_T;
  40. /* SDRRepositoryAllocInfo_T */
  41. typedef struct
  42. {
  43. INT8U CompletionCode;
  44. INT16U NumAllocUnits; /* Number of possible allocation units */
  45. INT16U AllocUnitSize; /* Allocation unit size in bytes */
  46. INT16U NumFreeAllocUnits; /* Number of free allocation units */
  47. INT16U LargestFreeBlock; /* Largest free block in allocation units */
  48. INT8U MaxRecSize; /* Maximimum record size in allocation units */
  49. } PACKED SDRRepositoryAllocInfo_T;
  50. /* ReserveSDRRepositoryRes_T */
  51. typedef struct
  52. {
  53. INT8U CompletionCode;
  54. INT16U ReservationID;
  55. } PACKED ReserveSDRRepositoryRes_T;
  56. /* GetSDRReq_T */
  57. typedef struct
  58. {
  59. INT16U ReservationID;
  60. INT16U RecID;
  61. INT8U Offset;
  62. INT8U Size;
  63. } PACKED GetSDRReq_T;
  64. /* GetSDRRes_T */
  65. typedef struct
  66. {
  67. INT8U CompletionCode;
  68. INT16U NextRecID;
  69. } PACKED GetSDRRes_T;
  70. /* AddSDRRes_T */
  71. typedef struct
  72. {
  73. INT8U CompletionCode;
  74. INT16U RecID;
  75. } PACKED AddSDRRes_T;
  76. /* PartialAddSDRReq_T */
  77. typedef struct
  78. {
  79. INT16U ReservationID;
  80. INT16U RecID;
  81. INT8U Offset;
  82. INT8U Progress;
  83. } PACKED PartialAddSDRReq_T;
  84. /* PartialAddSDRRes_T */
  85. typedef struct
  86. {
  87. INT8U CompletionCode;
  88. INT16U RecID;
  89. } PACKED PartialAddSDRRes_T;
  90. /* DeleteSDRReq_T */
  91. typedef struct
  92. {
  93. INT16U ReservationID;
  94. INT16U RecID;
  95. } PACKED DeleteSDRReq_T;
  96. /* DeleteSDRRes_T */
  97. typedef struct
  98. {
  99. INT8U CompletionCode;
  100. INT16U RecID;
  101. } PACKED DeleteSDRRes_T;
  102. /* ClearSDRReq_T */
  103. typedef struct
  104. {
  105. INT16U ReservationID;
  106. INT8U CLR [3];
  107. INT8U InitOrStatus;
  108. } PACKED ClearSDRReq_T;
  109. /* ClearSDRRes_T */
  110. typedef struct
  111. {
  112. INT8U CompletionCode;
  113. INT8U EraseProgress;
  114. } PACKED ClearSDRRes_T;
  115. /* GetSDRRepositoryTimeRes_T */
  116. typedef struct
  117. {
  118. INT8U CompletionCode;
  119. INT32U Time;
  120. } PACKED GetSDRRepositoryTimeRes_T;
  121. /* SetSDRRepositoryTimeReq_T */
  122. typedef struct
  123. {
  124. INT32U Time;
  125. } PACKED SetSDRRepositoryTimeReq_T;
  126. /* EnterSDRUpdateModeRes_T */
  127. typedef struct
  128. {
  129. INT8U CompletionCode;
  130. } PACKED EnterSDRUpdateModeRes_T;
  131. /* ExitSDRUpdateModeRes_T */
  132. typedef struct
  133. {
  134. INT8U CompletionCode;
  135. } PACKED ExitSDRUpdateModeRes_T;
  136. /* RunInitAgentReq_T */
  137. typedef struct
  138. {
  139. INT8U RunStatus;
  140. } PACKED RunInitAgentReq_T;
  141. /* RunInitAgentRes_T */
  142. typedef struct
  143. {
  144. INT8U CompletionCode;
  145. INT8U Status;
  146. } PACKED RunInitAgentRes_T;
  147. #pragma pack()
  148. #endif /* IPMI_SDR_H */