From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web10.8397.1599636472360637266 for ; Wed, 09 Sep 2020 00:27:52 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: ard.biesheuvel@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id ADFF41FB; Wed, 9 Sep 2020 00:27:50 -0700 (PDT) Received: from [192.168.1.80] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D619E3F68F; Wed, 9 Sep 2020 00:27:48 -0700 (PDT) Subject: Re: [PATCH edk2-Platform v2 1/1] Hisilicon/Smbios: Replace DEPRECATED code with S-suffixed one To: Wenyi Xie , devel@edk2.groups.io, leif@nuviainc.com, philmd@redhat.com Cc: michael.d.kinney@intel.com, lersek@redhat.com, songdongkuang@huawei.com References: <1599620592-5056-1-git-send-email-xiewenyi2@huawei.com> <1599620592-5056-2-git-send-email-xiewenyi2@huawei.com> From: "Ard Biesheuvel" Message-ID: Date: Wed, 9 Sep 2020 10:27:47 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <1599620592-5056-2-git-send-email-xiewenyi2@huawei.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 9/9/20 5:03 AM, Wenyi Xie wrote: > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2777 >=20 > The deprecated code under DISABLE_NEW_DEPRECATED_INTERFACES > will be removed, which will result in compilation breakage > of the Hisilicon platforms. Prevent that by switching to > S-suffixed one. >=20 > Cc: Leif Lindholm > Cc: Ard Biesheuvel > Cc: Philippe Mathieu-Daud=C3=A9 > Signed-off-by: Wenyi Xie The whole point of the UnicodeStrToAsciiStrS() routine is that it=20 returns a status code, and so it can fail. So please capture the return=20 code, and at least use ASSERT_EFI_ERROR() on it so any errors are=20 flagged in DEBUG mode. > --- > Silicon/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosType9.c = | 2 +- > Silicon/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemorySubClass.c = | 12 ++++++------ > Silicon/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/ProcessorSubCla= ss.c | 14 +++++++------- > Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type00/MiscBiosVendorF= unction.c | 6 +++--- > Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type01/MiscSystemManuf= acturerFunction.c | 12 ++++++------ > Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type02/MiscBaseBoardMa= nufacturerFunction.c | 12 ++++++------ > Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type03/MiscChassisManu= facturerFunction.c | 10 +++++----- > Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type09/MiscSystemSlotD= esignationFunction.c | 2 +- > 8 files changed, 35 insertions(+), 35 deletions(-) >=20 > diff --git a/Silicon/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosT= ype9.c b/Silicon/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosType9.c > index 57e049a41da0..4c8c693db039 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosType9.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/AddSmbiosType9/AddSmbiosType9.c > @@ -135,7 +135,7 @@ AddSmbiosType9Record ( > (VOID)CopyMem (SmbiosRecord, Type9Record, sizeof (SMBIOS_TABLE_TYPE= 9)); > SmbiosRecord->Hdr.Length =3D sizeof (SMBIOS_TABLE_TYPE9); > OptionalStrStart =3D (CHAR8 *)(SmbiosRecord + 1); > - (VOID)UnicodeStrToAsciiStr (SlotDesignation, OptionalStrStart); > + UnicodeStrToAsciiStrS (SlotDesignation, OptionalStrStart, SlotStrLen= + 1); > =20 > // > // Now we have got the full smbios record, call smbios protocol to = add this record. > diff --git a/Silicon/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemoryS= ubClass.c b/Silicon/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemorySubC= lass.c > index a1af02047409..f438ddcb5dd6 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemorySubClass= .c > +++ b/Silicon/Hisilicon/Drivers/Smbios/MemorySubClassDxe/MemorySubClass= .c > @@ -625,12 +625,12 @@ SmbiosAddType17Table ( > SmbiosGetDimmVoltageInfo (pGblData, Skt, Ch, Dimm, Type17Record); > =20 > OptionalStrStart =3D (CHAR8 *) (Type17Record + 1); > - UnicodeStrToAsciiStr (DeviceLocatorStr, OptionalStrStart); > - UnicodeStrToAsciiStr (BankLocatorStr, OptionalStrStart + DeviceLoc= atorStrLen + 1); > - UnicodeStrToAsciiStr (ManufactureStr, OptionalStrStart + DeviceLoc= atorStrLen + 1 + BankLocatorStrLen + 1); > - UnicodeStrToAsciiStr (SerialNumberStr, OptionalStrStart + DeviceLo= catorStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1); > - UnicodeStrToAsciiStr (AssertTagStr, OptionalStrStart + DeviceLocat= orStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1 + SerialNumb= erStrLen + 1); > - UnicodeStrToAsciiStr (PartNumberStr, OptionalStrStart + DeviceLoca= torStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1 + SerialNum= berStrLen + 1 + AssertTagStrLen + 1); > + UnicodeStrToAsciiStrS (DeviceLocatorStr, OptionalStrStart, DeviceL= ocatorStrLen + 1); > + UnicodeStrToAsciiStrS (BankLocatorStr, OptionalStrStart + DeviceLo= catorStrLen + 1, BankLocatorStrLen + 1); > + UnicodeStrToAsciiStrS (ManufactureStr, OptionalStrStart + DeviceLo= catorStrLen + 1 + BankLocatorStrLen + 1, ManufactureStrLen + 1); > + UnicodeStrToAsciiStrS (SerialNumberStr, OptionalStrStart + DeviceL= ocatorStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1, SerialN= umberStrLen + 1); > + UnicodeStrToAsciiStrS (AssertTagStr, OptionalStrStart + DeviceLoca= torStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1 + SerialNum= berStrLen + 1, AssertTagStrLen + 1); > + UnicodeStrToAsciiStrS (PartNumberStr, OptionalStrStart + DeviceLoc= atorStrLen + 1 + BankLocatorStrLen + 1 + ManufactureStrLen + 1 + SerialNu= mberStrLen + 1 + AssertTagStrLen + 1, PartNumberStrLen + 1); > =20 > MemDevSmbiosHandle =3D SMBIOS_HANDLE_PI_RESERVED; > Status =3D mSmbios->Add (mSmbios, NULL, &MemDevSmbiosHandle, (EFI= _SMBIOS_TABLE_HEADER*) Type17Record); > diff --git a/Silicon/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/Proc= essorSubClass.c b/Silicon/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/P= rocessorSubClass.c > index 647632f15ac2..0aa206d79cbb 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/ProcessorSu= bClass.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/ProcessorSubClassDxe/ProcessorSu= bClass.c > @@ -391,7 +391,7 @@ AddSmbiosCacheTypeTable ( > (VOID)CopyMem(Type7Record, &mSmbiosCacheTable[CacheLevel], si= zeof (SMBIOS_TABLE_TYPE7)); > =20 > OptionalStrStart =3D (CHAR8 *) (Type7Record + 1); > - UnicodeStrToAsciiStr (CacheSocketStr, OptionalStrStart); > + UnicodeStrToAsciiStrS (CacheSocketStr, OptionalStrStart, Cache= SocketStrLen + 1); > =20 > SmbiosHandle =3D SMBIOS_HANDLE_PI_RESERVED; > Status =3D mSmbios->Add (mSmbios, NULL, &SmbiosHandle, (EFI_S= MBIOS_TABLE_HEADER *)Type7Record); > @@ -610,12 +610,12 @@ AddSmbiosProcessorTypeTable ( > *ProcessorId =3D ArmReadMidr(); > =20 > OptionalStrStart =3D (CHAR8 *) (Type4Record + 1); > - UnicodeStrToAsciiStr (ProcessorSocketStr, OptionalStrStart); > - UnicodeStrToAsciiStr (ProcessorManuStr, OptionalStrStart + Process= orSocketStrLen + 1); > - UnicodeStrToAsciiStr (ProcessorVersionStr, OptionalStrStart + Proc= essorSocketStrLen + 1 + ProcessorManuStrLen + 1); > - UnicodeStrToAsciiStr (SerialNumberStr, OptionalStrStart + Processo= rSocketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1)= ; > - UnicodeStrToAsciiStr (AssetTagStr, OptionalStrStart + ProcessorSoc= ketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1 + Se= rialNumberStrLen + 1); > - UnicodeStrToAsciiStr (PartNumberStr, OptionalStrStart + ProcessorS= ocketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1 + = SerialNumberStrLen + 1 + AssetTagStrLen + 1); > + UnicodeStrToAsciiStrS (ProcessorSocketStr, OptionalStrStart, Proce= ssorSocketStrLen + 1); > + UnicodeStrToAsciiStrS (ProcessorManuStr, OptionalStrStart + Proces= sorSocketStrLen + 1, ProcessorManuStrLen + 1); > + UnicodeStrToAsciiStrS (ProcessorVersionStr, OptionalStrStart + Pro= cessorSocketStrLen + 1 + ProcessorManuStrLen + 1, ProcessorVersionStrLen = + 1); > + UnicodeStrToAsciiStrS (SerialNumberStr, OptionalStrStart + Process= orSocketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1= , SerialNumberStrLen + 1); > + UnicodeStrToAsciiStrS (AssetTagStr, OptionalStrStart + ProcessorSo= cketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1 + S= erialNumberStrLen + 1, AssetTagStrLen + 1); > + UnicodeStrToAsciiStrS (PartNumberStr, OptionalStrStart + Processor= SocketStrLen + 1 + ProcessorManuStrLen + 1 + ProcessorVersionStrLen + 1 += SerialNumberStrLen + 1 + AssetTagStrLen + 1, PartNumberStrLen + 1); > =20 > SmbiosHandle =3D SMBIOS_HANDLE_PI_RESERVED; > Status =3D mSmbios->Add (mSmbios, NULL, &SmbiosHandle, (EFI_SMBIO= S_TABLE_HEADER *)Type4Record); > diff --git a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type00/Misc= BiosVendorFunction.c b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Typ= e00/MiscBiosVendorFunction.c > index b62ec1dd8fdf..abd766ac8ad9 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type00/MiscBiosVen= dorFunction.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type00/MiscBiosVen= dorFunction.c > @@ -213,9 +213,9 @@ MISC_SMBIOS_TABLE_FUNCTION(MiscBiosVendor) > SmbiosRecord->BiosSize =3D Base2ToByteWith64KUnit(BiosPhysicalSiz= eHexValue) - 1; > =20 > OptionalStrStart =3D (CHAR8 *)(SmbiosRecord + 1); > - UnicodeStrToAsciiStr(Vendor, OptionalStrStart); > - UnicodeStrToAsciiStr(Version, OptionalStrStart + VendorStrLen + 1)= ; > - UnicodeStrToAsciiStr(ReleaseDate, OptionalStrStart + VendorStrLen = + 1 + VerStrLen + 1); > + UnicodeStrToAsciiStrS (Vendor, OptionalStrStart, VendorStrLen + 1)= ; > + UnicodeStrToAsciiStrS (Version, OptionalStrStart + VendorStrLen + = 1, VerStrLen + 1); > + UnicodeStrToAsciiStrS (ReleaseDate, OptionalStrStart + VendorStrLe= n + 1 + VerStrLen + 1, DateStrLen + 1); > // > // Now we have got the full smbios record, call smbios protocol t= o add this record. > // > diff --git a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type01/Misc= SystemManufacturerFunction.c b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMis= cDxe/Type01/MiscSystemManufacturerFunction.c > index f829b09d9cb7..4c16afa04206 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type01/MiscSystemM= anufacturerFunction.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type01/MiscSystemM= anufacturerFunction.c > @@ -135,12 +135,12 @@ MISC_SMBIOS_TABLE_FUNCTION(MiscSystemManufacturer= ) > } > =20 > OptionalStrStart =3D (CHAR8 *)(SmbiosRecord + 1); > - UnicodeStrToAsciiStr(Manufacturer, OptionalStrStart); > - UnicodeStrToAsciiStr(ProductName, OptionalStrStart + ManuStrLen += 1); > - UnicodeStrToAsciiStr(Version, OptionalStrStart + ManuStrLen += 1 + PdNameStrLen + 1); > - UnicodeStrToAsciiStr(SerialNumber, OptionalStrStart + ManuStrLen += 1 + PdNameStrLen + 1 + VerStrLen + 1); > - UnicodeStrToAsciiStr(SKUNumber, OptionalStrStart + ManuStrLen += 1 + PdNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1); > - UnicodeStrToAsciiStr(Family, OptionalStrStart + ManuStrLen += 1 + PdNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1 + SKUNumStrLe= n + 1); > + UnicodeStrToAsciiStrS (Manufacturer, OptionalStrStart, ManuStrLen = + 1); > + UnicodeStrToAsciiStrS (ProductName, OptionalStrStart + ManuStrLen= + 1, PdNameStrLen + 1); > + UnicodeStrToAsciiStrS (Version, OptionalStrStart + ManuStrLen= + 1 + PdNameStrLen + 1, VerStrLen + 1); > + UnicodeStrToAsciiStrS (SerialNumber, OptionalStrStart + ManuStrLen= + 1 + PdNameStrLen + 1 + VerStrLen + 1, SerialNumStrLen + 1); > + UnicodeStrToAsciiStrS (SKUNumber, OptionalStrStart + ManuStrLen= + 1 + PdNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1, SKUNumStrL= en + 1); > + UnicodeStrToAsciiStrS (Family, OptionalStrStart + ManuStrLen= + 1 + PdNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1 + SKUNumStr= Len + 1, FamilyStrLen + 1); > =20 > // > // Now we have got the full smbios record, call smbios protocol t= o add this record. > diff --git a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type02/Misc= BaseBoardManufacturerFunction.c b/Silicon/Hisilicon/Drivers/Smbios/Smbios= MiscDxe/Type02/MiscBaseBoardManufacturerFunction.c > index 3834bf93f70b..20bb001bb33c 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type02/MiscBaseBoa= rdManufacturerFunction.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type02/MiscBaseBoa= rdManufacturerFunction.c > @@ -142,12 +142,12 @@ MISC_SMBIOS_TABLE_FUNCTION(MiscBaseBoardManufactu= rer) > FreePool(HandleArray); > =20 > OptionalStrStart =3D (CHAR8 *)(SmbiosRecord + 1); > - UnicodeStrToAsciiStr(BaseBoardManufacturer, OptionalStrStart); > - UnicodeStrToAsciiStr(BaseBoardProductName, OptionalStrStart + Man= uStrLen + 1); > - UnicodeStrToAsciiStr(Version, OptionalStrStart + Man= uStrLen + 1 + ProductNameStrLen + 1); > - UnicodeStrToAsciiStr(SerialNumber, OptionalStrStart + Man= uStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1); > - UnicodeStrToAsciiStr(AssetTag, OptionalStrStart + Man= uStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1= ); > - UnicodeStrToAsciiStr(ChassisLocation, OptionalStrStart + Man= uStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1= + AssetTagStrLen + 1); > + UnicodeStrToAsciiStrS (BaseBoardManufacturer, OptionalStrStart, Ma= nuStrLen + 1); > + UnicodeStrToAsciiStrS (BaseBoardProductName, OptionalStrStart + M= anuStrLen + 1, ProductNameStrLen + 1); > + UnicodeStrToAsciiStrS (Version, OptionalStrStart + M= anuStrLen + 1 + ProductNameStrLen + 1, VerStrLen + 1); > + UnicodeStrToAsciiStrS (SerialNumber, OptionalStrStart + M= anuStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1, SerialNumStrLen + = 1); > + UnicodeStrToAsciiStrS (AssetTag, OptionalStrStart + M= anuStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen += 1, AssetTagStrLen + 1); > + UnicodeStrToAsciiStrS (ChassisLocation, OptionalStrStart + M= anuStrLen + 1 + ProductNameStrLen + 1 + VerStrLen + 1 + SerialNumStrLen += 1 + AssetTagStrLen + 1, ChassisLocaStrLen + 1); > =20 > Status =3D LogSmbiosData( (UINT8*)SmbiosRecord, &SmbiosHandle); > if(EFI_ERROR(Status)) > diff --git a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type03/Misc= ChassisManufacturerFunction.c b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMi= scDxe/Type03/MiscChassisManufacturerFunction.c > index ec00e1cd10ad..cd98cc966322 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type03/MiscChassis= ManufacturerFunction.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type03/MiscChassis= ManufacturerFunction.c > @@ -147,11 +147,11 @@ MISC_SMBIOS_TABLE_FUNCTION(MiscChassisManufacture= r) > *((UINT8 *)SmbiosRecord + sizeof (SMBIOS_TABLE_TYPE3) + ExtendLen= gth) =3D 5; > =20 > OptionalStrStart =3D (CHAR8 *)((UINT8 *)SmbiosRecord + sizeof (SM= BIOS_TABLE_TYPE3) + ExtendLength + 1); > - UnicodeStrToAsciiStr(Manufacturer, OptionalStrStart); > - UnicodeStrToAsciiStr(Version, OptionalStrStart + ManuStrL= en + 1); > - UnicodeStrToAsciiStr(SerialNumber, OptionalStrStart + ManuStrL= en + 1 + VerStrLen + 1); > - UnicodeStrToAsciiStr(AssertTag, OptionalStrStart + ManuStrL= en + 1 + VerStrLen + 1 + SerialNumStrLen + 1); > - UnicodeStrToAsciiStr(ChassisSkuNumber, OptionalStrStart + ManuStrL= en + 1 + VerStrLen + 1 + SerialNumStrLen +1 + AssertTagStrLen + 1); > + UnicodeStrToAsciiStrS (Manufacturer, OptionalStrStart, ManuStr= Len + 1); > + UnicodeStrToAsciiStrS (Version, OptionalStrStart + ManuSt= rLen + 1, VerStrLen + 1); > + UnicodeStrToAsciiStrS (SerialNumber, OptionalStrStart + ManuSt= rLen + 1 + VerStrLen + 1, SerialNumStrLen + 1); > + UnicodeStrToAsciiStrS (AssertTag, OptionalStrStart + ManuSt= rLen + 1 + VerStrLen + 1 + SerialNumStrLen + 1, AssertTagStrLen + 1); > + UnicodeStrToAsciiStrS (ChassisSkuNumber, OptionalStrStart + ManuSt= rLen + 1 + VerStrLen + 1 + SerialNumStrLen +1 + AssertTagStrLen + 1, ChaN= umStrLen + 1); > // > // Now we have got the full smbios record, call smbios protocol t= o add this record. > // > diff --git a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type09/Misc= SystemSlotDesignationFunction.c b/Silicon/Hisilicon/Drivers/Smbios/Smbios= MiscDxe/Type09/MiscSystemSlotDesignationFunction.c > index ca1a7a2c0055..e03b28d2f6aa 100644 > --- a/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type09/MiscSystemS= lotDesignationFunction.c > +++ b/Silicon/Hisilicon/Drivers/Smbios/SmbiosMiscDxe/Type09/MiscSystemS= lotDesignationFunction.c > @@ -172,7 +172,7 @@ MISC_SMBIOS_TABLE_FUNCTION(MiscSystemSlotDesignatio= n) > SmbiosRecord->Hdr.Length =3D sizeof (SMBIOS_TABLE_TYPE9); > =20 > OptionalStrStart =3D (CHAR8 *)(SmbiosRecord + 1); > - UnicodeStrToAsciiStr(SlotDesignation, OptionalStrStart); > + UnicodeStrToAsciiStrS (SlotDesignation, OptionalStrStart, SlotDesi= gnationStrLen + 1); > // > // Now we have got the full smbios record, call smbios protocol t= o add this record. > // >=20