From: Chris Phillips <chrisp@hpe.com>
To: edk2-devel@lists.01.org
Cc: michael.d.kinney@intel.com, liming.gao@intel.com
Subject: [PATCH] MdePkg: Add comments for SMBIOS Type 3 structure to cover SKU Number
Date: Tue, 10 Jan 2017 00:49:08 -0600 [thread overview]
Message-ID: <386f0aa8-708b-46e6-b20d-77ae416355ba@AIA2PHNNRN.local> (raw)
Starting with SMBIOS spec version 2.7, Type 3 added SKU Number.
SKU Number is at a variable offset (depends on count and length of Contained Elements), so cannot add SKU Number to the SMBIOS_TABLE_TYPE3 structure.
Adding comments to explain how to get SKU Number.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Chris Phillips <chrisp@hpe.com>
---
MdePkg/Include/IndustryStandard/SmBios.h | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/MdePkg/Include/IndustryStandard/SmBios.h b/MdePkg/Include/IndustryStandard/SmBios.h
index c66422fc3a..a24713d214 100644
--- a/MdePkg/Include/IndustryStandard/SmBios.h
+++ b/MdePkg/Include/IndustryStandard/SmBios.h
@@ -2,7 +2,7 @@
Industry Standard Definitions of SMBIOS Table Specification v3.0.0.
Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>
-(C) Copyright 2015 Hewlett Packard Enterprise Development LP<BR>
+(C) Copyright 2015-2017 Hewlett Packard Enterprise Development LP<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
The full text of the license may be found at
@@ -467,7 +467,18 @@ typedef struct {
UINT8 NumberofPowerCords;
UINT8 ContainedElementCount;
UINT8 ContainedElementRecordLength;
+ //
+ // Can have 0 to (ContainedElementCount * ContainedElementRecordLength) contained elements
+ //
CONTAINED_ELEMENT ContainedElements[1];
+ //
+ // Add for smbios 2.7
+ //
+ // Since ContainedElements has a variable number of entries, must not define SKUNumber in
+ // the structure. Need to reference it by starting at offset 0x15 and adding
+ // (ContainedElementCount * ContainedElementRecordLength) bytes.
+ //
+ // SMBIOS_TABLE_STRING SKUNumber;
} SMBIOS_TABLE_TYPE3;
///
--
2.11.0.windows.1
next reply other threads:[~2017-01-10 6:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-10 6:49 Chris Phillips [this message]
2017-01-10 10:06 ` [PATCH] MdePkg: Add comments for SMBIOS Type 3 structure to cover SKU Number Zeng, Star
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=386f0aa8-708b-46e6-b20d-77ae416355ba@AIA2PHNNRN.local \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox