Hi Ray, Both is fine to me, one thought is that we must have one CPU, so change to 1 and I also checked some existing usage cases like the EFI_SMRAM_HOB_DESCRIPTOR_BLOCK.Descriptor, WIN_CERTIFICATE_UEFI_GUID. CertData, it also the same way.
Thanks, Jiaxin > -----Original Message----- > From: Ni, Ray <ray...@intel.com> > Sent: Friday, February 10, 2023 3:15 PM > To: Wu, Jiaxin <jiaxin...@intel.com>; devel@edk2.groups.io > Cc: Dong, Eric <eric.d...@intel.com>; Zeng, Star <star.z...@intel.com>; > Laszlo Ersek <ler...@redhat.com>; Gerd Hoffmann <kra...@redhat.com>; > Kumar, Rahul R <rahul.r.ku...@intel.com> > Subject: RE: [PATCH v4 2/5] UefiCpuPkg/SmmBaseHob.h: Add SMM Base > HOB Data > > Jiaxin, > > + /// > > + /// Pointer to SmBase address for each Processors. > > + /// > > + UINT64 SmBase[1]; > > Why SmBase[1] instead of SmBase[0]? > I think using SmBase[0] can better help C code to calculate the HOB size. > Simply sizeof (SMM_BASE_HOB_DATA) * sizeof (UINT64) * CpuCount, > instead of sizeof (SMM_BASE_HOB_DATA) * sizeof (UINT64) * (CpuCount - > 1). > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#99964): https://edk2.groups.io/g/devel/message/99964 Mute This Topic: https://groups.io/mt/96871372/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-