MdePkg/Include/IndustryStandard/SmBios.h | 62 +++++++++++--------- 1 file changed, 35 insertions(+), 27 deletions(-)
In Type9 structure since PeerGroups has a variable
number of entries, must not define new fields in the structure.So added an
extended structure and defined new fields added after PeerGroups. Also done
some improvements to Smbios 3.5.0 spec changes.
Signed-off-by:
sainadh nagolu <sainadhn@ami.com>
---
MdePkg/Include/IndustryStandard/SmBios.h | 62 +++++++++++---------
1 file changed, 35 insertions(+), 27 deletions(-)
diff --git a/MdePkg/Include/IndustryStandard/SmBios.h b/MdePkg/Include/IndustryStandard/SmBios.h
index c7a4971f14..f62ad7fa4d 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -1503,6 +1503,17 @@ typedef struct {
UINT8 DataBusWidth;
UINT8 PeerGroupingCount;
MISC_SLOT_PEER_GROUP PeerGroups[1];
+ //
+ // Since PeerGroups has a variable number of entries, must not define new
+ // fields in the structure. Remaining fields can be referenced using
+ // SMBIOS_TABLE_TYPE9_EXTENDED structure
+ //
+} SMBIOS_TABLE_TYPE9;
+
+///
+/// Extended structure for System Slots (Type 9)
+///
+typedef struct {
//
// Add for smbios 3.4
//
@@ -1513,7 +1524,7 @@ typedef struct {
// Add for smbios 3.5
//
UINT8 SlotHeight; ///< The enumeration value from MISC_SLOT_HEIGHT.
-} SMBIOS_TABLE_TYPE9;
+} SMBIOS_TABLE_TYPE9_EXTENDED;
///
/// On Board Devices Information - Device Types.
@@ -2746,11 +2757,11 @@ typedef enum {
///
/// Firmware Inventory Firmware Characteristics (Type 45).
///
-typedef enum {
- CharacteristicsUpdatable = 0x00,
- CharacteristicsWriteProtected = 0x01,
- CharacteristicsReserved = 0x02 /// 0x02 - 0x0F are reserved
-} FIRMWARE_INVENTORY_CHARACTERISTICS;
+typedef struct {
+ UINT16 Updatable :1;
+ UINT16 WriteProtected :1;
+ UINT16 Reserved :14;
+} FIRMWARE_CHARACTERISTICS;
///
/// Firmware Inventory State Information (Type 45).
@@ -2763,7 +2774,7 @@ typedef enum {
FirmwareInventoryStateAbsent = 0x05,
FirmwareInventoryStateStandbyOffline = 0x06,
FirmwareInventoryStateStandbySpare = 0x07,
- FirmwareInventoryStateUnavailableOffline = 0x08,
+ FirmwareInventoryStateUnavailableOffline = 0x08
} FIRMWARE_INVENTORY_STATE;
///
@@ -2780,21 +2791,19 @@ typedef enum {
/// One Type 45 structure is provided for each firmware component.
///
typedef struct {
- SMBIOS_STRUCTURE Hdr;
- SMBIOS_HANDLE RefHandle;
-
- UINT8 FirmwareComponentName;
- UINT8 FirmwareVersion;
- UINT8 FirmwareVersionFormat; ///< The enumeration value from FIRMWARE_INVENTORY_VERSION_FORMAT_TYPE
- UINT8 FirmwareId;
- UINT8 FirmwareIdFormat;
- UINT8 ReleaseDate;
- UINT8 Manufacturer;
- UINT8 LowestSupportedVersion;
- UINT64 ImageSize;
- UINT32 Characteristics;
- UINT8 State;
- UINT8 AssociatedComponentCount;
+ SMBIOS_STRUCTURE Hdr;
+ SMBIOS_TABLE_STRING FirmwareComponentName;
+ SMBIOS_TABLE_STRING FirmwareVersion;
+ UINT8 FirmwareVersionFormat; ///< The enumeration value from FIRMWARE_INVENTORY_VERSION_FORMAT_TYPE
+ SMBIOS_TABLE_STRING FirmwareId;
+ UINT8 FirmwareIdFormat; ///< The enumeration value from FIRMWARE_INVENTORY_FIRMWARE_ID_FORMAT_TYPE.
+ SMBIOS_TABLE_STRING ReleaseDate;
+ SMBIOS_TABLE_STRING Manufacturer;
+ SMBIOS_TABLE_STRING LowestSupportedVersion;
+ UINT64 ImageSize;
+ FIRMWARE_CHARACTERISTICS Characteristics;
+ UINT8 State; ///< The enumeration value from FIRMWARE_INVENTORY_STATE.
+ UINT8 AssociatedComponentCount;
///
/// zero or n-number of handles depends on AssociatedComponentCount
/// handles are of type SMBIOS_HANDLE
@@ -2820,11 +2829,10 @@ typedef enum {
/// parent structure.
///
typedef struct {
- SMBIOS_STRUCTURE Hdr;
- SMBIOS_HANDLE RefHandle;
- UINT16 StringPropertyId;
- UINT8 StringPropertyValue;
- SMBIOS_HANDLE ParentHandle;
+ SMBIOS_STRUCTURE Hdr;
+ UINT16 StringPropertyId; ///< The enumeration value from STRING_PROPERTY_ID.
+ SMBIOS_TABLE_STRING StringPropertyValue;
+ SMBIOS_HANDLE ParentHandle;
} SMBIOS_TABLE_TYPE46;
///
--
2.36.0.windows.1
-The information contained in this message may be confidential and proprietary to American Megatrends (AMI). This communication is intended to be read only by the individual or entity to whom it is addressed or by their designee. If the reader of this message is not the intended recipient, you are on notice that any distribution of this message, in any form, is strictly prohibited. Please promptly notify the sender by reply e-mail or by telephone at 770-246-8600, and then delete or destroy all copies of the transmission.
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#91944): https://edk2.groups.io/g/devel/message/91944
Mute This Topic: https://groups.io/mt/92672838/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-
The change is good. But the change in Smbios type 9 will impact ShellPkg\Library\UefiShellDebug1CommandsLib\SmbiosView\PrintInfo.c. Please also update ShellPkg. Thanks Liming > -----邮件原件----- > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Sainadh > Nagolu via groups.io > 发送时间: 2022年7月28日 0:21 > 收件人: devel@edk2.groups.io > 抄送: Sainadh Nagolu <sainadhn@ami.com>; Sundaresan S > <sundaresans@ami.com>; Vasudevan Sambandan <vasudevans@ami.com>; > gaoliming@byosoft.com.cn > 主题: [edk2-devel] [PATCH] MdePkg:Improved Smbios Type9 table and > Smbios 3.5.0 spec changes > > In Type9 structure since PeerGroups has a variable > number of entries, must not define new fields in the structure.So added an > extended structure and defined new fields added after PeerGroups. Also > done > some improvements to Smbios 3.5.0 spec changes. > > Signed-off-by: > sainadh nagolu <sainadhn@ami.com> > > --- > MdePkg/Include/IndustryStandard/SmBios.h | 62 +++++++++++--------- > 1 file changed, 35 insertions(+), 27 deletions(-) > > diff --git a/MdePkg/Include/IndustryStandard/SmBios.h > b/MdePkg/Include/IndustryStandard/SmBios.h > index c7a4971f14..f62ad7fa4d 100644 > --- a/MdePkg/Include/IndustryStandard/SmBios.h > +++ b/MdePkg/Include/IndustryStandard/SmBios.h > @@ -1503,6 +1503,17 @@ typedef struct { > UINT8 DataBusWidth; > > UINT8 PeerGroupingCount; > > MISC_SLOT_PEER_GROUP PeerGroups[1]; > > + // > > + // Since PeerGroups has a variable number of entries, must not define > new > > + // fields in the structure. Remaining fields can be referenced using > > + // SMBIOS_TABLE_TYPE9_EXTENDED structure > > + // > > +} SMBIOS_TABLE_TYPE9; > > + > > +/// > > +/// Extended structure for System Slots (Type 9) > > +/// > > +typedef struct { > > // > > // Add for smbios 3.4 > > // > > @@ -1513,7 +1524,7 @@ typedef struct { > // Add for smbios 3.5 > > // > > UINT8 SlotHeight; ///< The > enumeration value from MISC_SLOT_HEIGHT. > > -} SMBIOS_TABLE_TYPE9; > > +} SMBIOS_TABLE_TYPE9_EXTENDED; > > > > /// > > /// On Board Devices Information - Device Types. > > @@ -2746,11 +2757,11 @@ typedef enum { > /// > > /// Firmware Inventory Firmware Characteristics (Type 45). > > /// > > -typedef enum { > > - CharacteristicsUpdatable = 0x00, > > - CharacteristicsWriteProtected = 0x01, > > - CharacteristicsReserved = 0x02 /// 0x02 - 0x0F are reserved > > -} FIRMWARE_INVENTORY_CHARACTERISTICS; > > +typedef struct { > > + UINT16 Updatable :1; > > + UINT16 WriteProtected :1; > > + UINT16 Reserved :14; > > +} FIRMWARE_CHARACTERISTICS; > > > > /// > > /// Firmware Inventory State Information (Type 45). > > @@ -2763,7 +2774,7 @@ typedef enum { > FirmwareInventoryStateAbsent = 0x05, > > FirmwareInventoryStateStandbyOffline = 0x06, > > FirmwareInventoryStateStandbySpare = 0x07, > > - FirmwareInventoryStateUnavailableOffline = 0x08, > > + FirmwareInventoryStateUnavailableOffline = 0x08 > > } FIRMWARE_INVENTORY_STATE; > > > > /// > > @@ -2780,21 +2791,19 @@ typedef enum { > /// One Type 45 structure is provided for each firmware component. > > /// > > typedef struct { > > - SMBIOS_STRUCTURE Hdr; > > - SMBIOS_HANDLE RefHandle; > > - > > - UINT8 FirmwareComponentName; > > - UINT8 FirmwareVersion; > > - UINT8 FirmwareVersionFormat; ///< The > enumeration value from FIRMWARE_INVENTORY_VERSION_FORMAT_TYPE > > - UINT8 FirmwareId; > > - UINT8 FirmwareIdFormat; > > - UINT8 ReleaseDate; > > - UINT8 Manufacturer; > > - UINT8 LowestSupportedVersion; > > - UINT64 ImageSize; > > - UINT32 Characteristics; > > - UINT8 State; > > - UINT8 AssociatedComponentCount; > > + SMBIOS_STRUCTURE Hdr; > > + SMBIOS_TABLE_STRING FirmwareComponentName; > > + SMBIOS_TABLE_STRING FirmwareVersion; > > + UINT8 FirmwareVersionFormat; ///< The > enumeration value from FIRMWARE_INVENTORY_VERSION_FORMAT_TYPE > > + SMBIOS_TABLE_STRING FirmwareId; > > + UINT8 FirmwareIdFormat; ///< The > enumeration value from > FIRMWARE_INVENTORY_FIRMWARE_ID_FORMAT_TYPE. > > + SMBIOS_TABLE_STRING ReleaseDate; > > + SMBIOS_TABLE_STRING Manufacturer; > > + SMBIOS_TABLE_STRING LowestSupportedVersion; > > + UINT64 ImageSize; > > + FIRMWARE_CHARACTERISTICS Characteristics; > > + UINT8 State; ///< The > enumeration value from FIRMWARE_INVENTORY_STATE. > > + UINT8 AssociatedComponentCount; > > /// > > /// zero or n-number of handles depends on AssociatedComponentCount > > /// handles are of type SMBIOS_HANDLE > > @@ -2820,11 +2829,10 @@ typedef enum { > /// parent structure. > > /// > > typedef struct { > > - SMBIOS_STRUCTURE Hdr; > > - SMBIOS_HANDLE RefHandle; > > - UINT16 StringPropertyId; > > - UINT8 StringPropertyValue; > > - SMBIOS_HANDLE ParentHandle; > > + SMBIOS_STRUCTURE Hdr; > > + UINT16 StringPropertyId; ///< The > enumeration value from STRING_PROPERTY_ID. > > + SMBIOS_TABLE_STRING StringPropertyValue; > > + SMBIOS_HANDLE ParentHandle; > > } SMBIOS_TABLE_TYPE46; > > > > /// > > -- > 2.36.0.windows.1 > -The information contained in this message may be confidential and > proprietary to American Megatrends (AMI). This communication is intended to > be read only by the individual or entity to whom it is addressed or by their > designee. If the reader of this message is not the intended recipient, you are > on notice that any distribution of this message, in any form, is strictly > prohibited. Please promptly notify the sender by reply e-mail or by telephone > at 770-246-8600, and then delete or destroy all copies of the transmission. > > > > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#92145): https://edk2.groups.io/g/devel/message/92145 Mute This Topic: https://groups.io/mt/92829976/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=-=-=-=-=-=-=-=-=-=-=-
Also attaching the patch files here for reference. -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#92509): https://edk2.groups.io/g/devel/message/92509 Mute This Topic: https://groups.io/mt/92829976/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=-=-=-=-=-=-=-=-=-=-=- Rar! �l� �ك� �Fg%fͪ�� ���'� HEdk2PatchFiles/MdePkg(3.5.0 and Type9)/Include/IndustryStandard/SmBios.h �$t~��ȎIU@C34TTPWu���<�U�m�"RM=Vo#U5v�kn��w���-��I�����o�4 3#��I ��U�fFx*��4Ҟ��$H�!��� ������n�Z���������0���bן���}˽�y���ׯF����>!�㻋�+��� �~� ͠>�ϓ.}^��[����C��n�/=�{3{\v�kNr�����a�� n����r���n�o�������P#�/ �ijb��Q�9�������7��&*@@pR��Z��ά���C��qĉ�]�B\�|`�b�)��>�iBF@}9���8<��ןq�n��+�R�꼢6\��\�@ �]�ŜR�P �����+�����~��{���?O����� �x����Qb�uλ�;o��C��~��*��~��㝠�-��J�5��9���){�sW��!8a����*k��� �c�<��� B08���?]��y�[ռ������\>h� �&$�0u�A���X4�V�J�#��|�pe����>�~.� ��9���-{�4���� 3�$�&LSG�B2c�������j���L Dy�ܒ��� ;{;�/vus\ϟ�� n � �?� R�����<��>���%3�.��u �=:}9��i�E���{�:����[8�9���";2b�;�! 8�Cx��|>PA ��NL���鮝���"mXpb�N�H;@@H` �� ���js,)By���.�������� InB���/ ��$-�>���?��WNE�^��]~��;�/�V �wt�0MV��ұ|�џ�L`J��n����m<3�Q�(��栧I��@QDj��f�B)��I�(NӞ3rRy�X5�E!N�D��z��Ϗgm���<�^� ��#�tE�\� v�EN���B����r.�"!u?�� @����U�e��R[�D��({�Y�Y50/{�6Ͷ�EN`���b'� ��vj���@?#ۋ�@�B;����?U�e���`�L=]���\{��!�L�w�������?OH��r��ϰDc� ~�;�#�n�� �h�������妃��^��M%|�a� w4��{��[��ܽ]��\o련 %���+��������z8hO1b�p0�/j�R������ޫ�z��o�+/����'��+=�W&�J�Q��_p }�� z�NN��z�R���hC�݀��%�D�8��v�����ն�Ej��#y�����Z�}_����u������lX,������'k�� �Ѻ��!���H�ǟs��:�Z�Bl�����n.��hլ �j�؞��ğ�7���[�Եִjv �X�(:�Z�6�'���Du���� C;O2p�^ћK#�h�� ��!-�w�M���z��h���XCqV���������QѮ�#Z�2mX�΅�z�[��V�I��*���8��~�d���!3.�Π�|ۑwGF��������Y1⤫��c�ߓ'SѼ�Z,G6��W�b�F��0|� ��c/+�G��zt�܅���pT �Ek�Ɏ�I���3541a���� ǤTF�a��{a����S�ACw��>,Z�j[��y����s�c�a�%���֯�� �q߰ ;yt���7C��.57�N�4!�l�J�ȫ������b�� ��覥9�g�N��{__�DA��9������[>�%.i3�����|@�}�V�o+���VR[��oag,0J- �P� �[�Śmbi|a��?M��i^�!p�- ����H�z���f�hX���F�ݶ��J+g�*'��$A/�)N�xyy��;��1��g:�;�T���Hr���(<�@:Zs�m���[���'��.!�?*��r�S��T�:c(��9��^+����]q����>?��sr�ף� �"��_ �t�)ߩ��!�W��O�ފ��Ղ�Ƞ\p�NJx���:����O�� W����7��F�Jv���c�y��*$��jS��ǏM@!~��p��Ly���.����z&�$9�K��C��?�� �p�hQ�� �@����<T�w��� � [�]��V#=���!~A�bR^'~rI�&D\r�!W$���#�b>D<��Bح�{R�F�[P%�"�=�,�![6��"T.����}s�#rf�������p��wn������}�4��!��@�,n6�%������2�����)#P+���)�ns�bZ�z��%��ٝOqW�>� ���&t@%+<�M�o;'�Â`��u�H�<Q+�B��O����μ'��)r- }��-"Nx�u�O����Øa?-}��y�~cC��J�j� ����llIY� ������pA�8�2�SM�X���KF��������I�4w�xmJ�I����%�0�"j[}� f?\�q�M����Ŗ}Z��xx�"K�4Hs�_�Tt�K��L�'c�x�o��A��u��"�kP|�;����+Rd�}@/���m5݂4�I���MG�5e16����A��@t;=J���2.o乺� �[k�JN��������D �a�=��@t&������~��[h�T.�&{T�8�f���LoCfۂ��D���{��[_/�T���&& ��S:h �@�����`�fIi����Ew�2��"�@s�'�0���g �}J�ϒ�F���q�C�4GW�dP��)A�,�,=��N��B������F��B�P����ZԉjOK@o$Ț�h��Dg%�ϴ3U�-fg����Жx�����e+Fd���\�U�*��D��Kxl���^��?�0}B�!dx!�jL�9T��������@;��k�L ���k����6�ʐ����SN��Ź�����1�'��S1I�6�1�PTgB*b���s^p�?��\Ĺ�S@�9>��[_�v�F�Y|�8�5�L��� ?7q�����\\��m�a߄<����be� y���E� v��i��H �# ��>�}|L�C�?����æbr�P w����c v]��z�f0(Ϯ�!������;n�9rD������b��zxB����X�@��G��Y�Q� -@&b^�:�℁J2f��F"�;.>