Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-stable201905

2019-05-22 Thread Liming Gao
Laszlo:

>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Laszlo Ersek
>Sent: Wednesday, May 22, 2019 9:05 PM
>To: devel@edk2.groups.io; Gao, Liming 
>Cc: Kinney, Michael D ; Cetola, Stephano
>; Andrew Fish ; Leif
>Lindholm 
>Subject: Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-
>stable201905
>
>On 05/22/19 14:09, Liming Gao wrote:
>
>> Here, I don't want to argue whether they are feature or bug. I just
>> want to share my thinking, and collect feedback, then work out the
>> clear rule so that all developers can follow.
>
>Good question. Assume we push a series that adds a feature, but then we
>realize it was not complete. Do we consider the rest of the work feature
>enablement, or bugfix for an earlier (already existing) feature?
>

Now, I have one case BaseTools: Update Conf/target.template to remove 
Nt32Pkg/Nt32Pkg.dsc.
 
https://edk2.groups.io/g/devel/message/41155?p=,,,20,0,0,0::Created,,EmulatorPkg,20,2,0,31697760
Nt32Pkg has been removed. BaseTools/Conf/target.template should be updatd. So, 
I send this patch for it. I regard it as the bug, and plan to push it for this 
release. 

>Maybe it helps if we try to determine the scope of the feature
>precisely, up-front, in the BZ. If a patch falls under that scope (and
>under nothing else, e.g. it is not a standalone fix for another bug in
>its own right), then we could consider it "feature addition /
>enablement".
>
>In that regard, the ShellPkg & EmulatorPkg patches would be feature
>enablement, not bug fixes.
>
>But I'm worried that this approach would only push the problem to a
>different location, namely, to determining the scope as precisely as
>possible in the TianoCore BZ. Sometimes we don't know that a module or
>package is affected in the scope, until we try something in practice.
>

I agree. I think this is hard to be followed. I would like to propose 
the simple rule for the patches in Soft Feature Freeze and Hard Feature Freeze. 
If the patch has not got R-B before Soft Feature Freeze, the patch wants
to catch the release. The patch must get the approve from at least one Stewards.
The patch needs to be sent to all Stewards and claim it to be added in the 
release.

>Laszlo
>
>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41269): https://edk2.groups.io/g/devel/message/41269
Mute This Topic: https://groups.io/mt/31653140/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V2] BaseTools:Make BaseTools support the correct RAW FFS FILE generation

2019-05-22 Thread Fan, ZhijuX
BZ:https://bugzilla.tianocore.org/show_bug.cgi?id=1765

RAW FFS File has no section for its data. For RAW FFS File,
directly call GenFfs tool to generate FFS file.

Ffs Rule:
[Rule.Common.USER_DEFINED.MicroCode]
  FILE RAW = $(NAMED_GUID) {
SectionType FileType $(INF_OUTPUT)/$(MODULE_NAME).bin
  }
As shown in the rule above,if SectionType and FileType not defined,
FFS files are generated directly, and no other type of file is
generated.

Cc: Bob Feng 
Cc: Liming Gao 
Signed-off-by: Zhiju.Fan 
---
 BaseTools/Source/Python/Common/DataType.py   |  1 +
 BaseTools/Source/Python/GenFds/EfiSection.py | 10 --
 BaseTools/Source/Python/GenFds/FdfParser.py  | 14 --
 BaseTools/Source/Python/GenFds/Section.py|  7 ++-
 4 files changed, 27 insertions(+), 5 deletions(-)

diff --git a/BaseTools/Source/Python/Common/DataType.py 
b/BaseTools/Source/Python/Common/DataType.py
index 780711bf8e..1879aea665 100644
--- a/BaseTools/Source/Python/Common/DataType.py
+++ b/BaseTools/Source/Python/Common/DataType.py
@@ -121,6 +121,7 @@ BINARY_FILE_TYPE_VER = 'VER'
 BINARY_FILE_TYPE_UI = 'UI'
 BINARY_FILE_TYPE_BIN = 'BIN'
 BINARY_FILE_TYPE_FV = 'FV'
+BINARY_FILE_TYPE_FFS = 'FFS'
 
 PLATFORM_COMPONENT_TYPE_LIBRARY_CLASS = 'LIBRARY_CLASS'
 PLATFORM_COMPONENT_TYPE_MODULE = 'MODULE'
diff --git a/BaseTools/Source/Python/GenFds/EfiSection.py 
b/BaseTools/Source/Python/GenFds/EfiSection.py
index 302f244faf..5346a0569f 100644
--- a/BaseTools/Source/Python/GenFds/EfiSection.py
+++ b/BaseTools/Source/Python/GenFds/EfiSection.py
@@ -93,7 +93,7 @@ class EfiSection (EfiSectionClassObject):
 if '.depex' in SuffixMap:
 FileList.append(Filename)
 else:
-FileList, IsSect = Section.Section.GetFileList(FfsInf, 
self.FileType, self.FileExtension, Dict, IsMakefile=IsMakefile)
+FileList, IsSect = Section.Section.GetFileList(FfsInf, 
self.FileType, self.FileExtension, Dict, IsMakefile=IsMakefile, 
SectionType=SectionType)
 if IsSect :
 return FileList, self.Alignment
 
@@ -227,14 +227,20 @@ class EfiSection (EfiSectionClassObject):
 else:
 EdkLogger.error("GenFds", GENFDS_ERROR, "Output file for 
%s section could not be found for %s" % (SectionType, InfFileName))
 
+elif len(FileList) > 1 and SectionType == BINARY_FILE_TYPE_FFS:
+EdkLogger.error("GenFds", GENFDS_ERROR,"Files suffixed with %s 
are not allowed to have more than one file in %s[Binaries] section" % 
(self.FileExtension, InfFileName))
+
 else:
 """Convert the File to Section file one by one """
 for File in FileList:
 """ Copy Map file to FFS output path """
 Index = Index + 1
 Num = '%s.%d' %(SecNum, Index)
-OutputFile = os.path.join( OutputPath, ModuleName + 
SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
 File = GenFdsGlobalVariable.MacroExtend(File, Dict)
+if SectionType == BINARY_FILE_TYPE_FFS:
+OutputFileList.append(File)
+return OutputFileList, Align
+OutputFile = os.path.join( OutputPath, ModuleName + 
SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
 
 #Get PE Section alignment when align is set to AUTO
 if self.Alignment == 'Auto' and (SectionType == 
BINARY_FILE_TYPE_PE32 or SectionType == BINARY_FILE_TYPE_TE):
diff --git a/BaseTools/Source/Python/GenFds/FdfParser.py 
b/BaseTools/Source/Python/GenFds/FdfParser.py
index ea1c3eeb30..8446e3be4c 100644
--- a/BaseTools/Source/Python/GenFds/FdfParser.py
+++ b/BaseTools/Source/Python/GenFds/FdfParser.py
@@ -3749,8 +3749,19 @@ class FdfParser:
 #
 def _GetEfiSection(self, Obj):
 OldPos = self.GetFileBufferPos()
+EfiSectionObj = EfiSection()
 if not self._GetNextWord():
-return False
+CurrentLine = 
self._CurrentLine()[self.CurrentOffsetWithinLine:].split()[0].strip()
+if self._Token == '{' and Obj.FvFileType == "RAW" and TAB_SPLIT in 
CurrentLine:
+if self._IsToken(TAB_VALUE_SPLIT):
+EfiSectionObj.FileExtension = self._GetFileExtension()
+elif self._GetNextToken():
+EfiSectionObj.FileName = self._Token
+EfiSectionObj.SectionType = BINARY_FILE_TYPE_FFS
+Obj.SectionList.append(EfiSectionObj)
+return True
+else:
+return False
 SectionName = self._Token
 
 if SectionName not in {
@@ -3816,7 +3827,6 @@ class FdfParser:
 Obj.SectionList.append(FvImageSectionObj)
 return True
 
-EfiSectionObj = EfiSection()
 EfiSectionObj.SectionType = SectionName
 
 if not self._GetNextToken():
diff --git 

Re: [edk2-devel] [PATCH] BaseTools:Make BaseTools support the correct RAW FFS FILE generation

2019-05-22 Thread Liming Gao
Zhiju:
  This usage is only valid when FILE type RAW. Please add this check. 

Thanks
Liming
>-Original Message-
>From: Fan, ZhijuX
>Sent: Thursday, May 23, 2019 11:30 AM
>To: devel@edk2.groups.io
>Cc: Gao, Liming ; Feng, Bob C 
>Subject: [PATCH] BaseTools:Make BaseTools support the correct RAW FFS FILE
>generation
>
>BZ:https://bugzilla.tianocore.org/show_bug.cgi?id=1765
>
>RAW FFS File has no section for its data. For RAW FFS File,
>directly call GenFfs tool to generate FFS file.
>
>Ffs Rule:
>[Rule.Common.USER_DEFINED.MicroCode]
>  FILE RAW = $(NAMED_GUID) {
>SectionType FileType $(INF_OUTPUT)/$(MODULE_NAME).bin
>  }
>As shown in the rule above,if SectionType and FileType not defined,
>FFS files are generated directly, and no other type of file is
>generated.
>
>Cc: Bob Feng 
>Cc: Liming Gao 
>Signed-off-by: Zhiju.Fan 
>---
> BaseTools/Source/Python/Common/DataType.py   |  1 +
> BaseTools/Source/Python/GenFds/EfiSection.py | 10 --
> BaseTools/Source/Python/GenFds/FdfParser.py  | 14 --
> BaseTools/Source/Python/GenFds/Section.py|  7 ++-
> 4 files changed, 27 insertions(+), 5 deletions(-)
>
>diff --git a/BaseTools/Source/Python/Common/DataType.py
>b/BaseTools/Source/Python/Common/DataType.py
>index 780711bf8e..1879aea665 100644
>--- a/BaseTools/Source/Python/Common/DataType.py
>+++ b/BaseTools/Source/Python/Common/DataType.py
>@@ -121,6 +121,7 @@ BINARY_FILE_TYPE_VER = 'VER'
> BINARY_FILE_TYPE_UI = 'UI'
> BINARY_FILE_TYPE_BIN = 'BIN'
> BINARY_FILE_TYPE_FV = 'FV'
>+BINARY_FILE_TYPE_FFS = 'FFS'
>
> PLATFORM_COMPONENT_TYPE_LIBRARY_CLASS = 'LIBRARY_CLASS'
> PLATFORM_COMPONENT_TYPE_MODULE = 'MODULE'
>diff --git a/BaseTools/Source/Python/GenFds/EfiSection.py
>b/BaseTools/Source/Python/GenFds/EfiSection.py
>index 302f244faf..5346a0569f 100644
>--- a/BaseTools/Source/Python/GenFds/EfiSection.py
>+++ b/BaseTools/Source/Python/GenFds/EfiSection.py
>@@ -93,7 +93,7 @@ class EfiSection (EfiSectionClassObject):
> if '.depex' in SuffixMap:
> FileList.append(Filename)
> else:
>-FileList, IsSect = Section.Section.GetFileList(FfsInf, 
>self.FileType,
>self.FileExtension, Dict, IsMakefile=IsMakefile)
>+FileList, IsSect = Section.Section.GetFileList(FfsInf, 
>self.FileType,
>self.FileExtension, Dict, IsMakefile=IsMakefile, SectionType=SectionType)
> if IsSect :
> return FileList, self.Alignment
>
>@@ -227,14 +227,20 @@ class EfiSection (EfiSectionClassObject):
> else:
> EdkLogger.error("GenFds", GENFDS_ERROR, "Output file for 
> %s
>section could not be found for %s" % (SectionType, InfFileName))
>
>+elif len(FileList) > 1 and SectionType == BINARY_FILE_TYPE_FFS:
>+EdkLogger.error("GenFds", GENFDS_ERROR,"Files suffixed with %s
>are not allowed to have more than one file in %s[Binaries] section" %
>(self.FileExtension, InfFileName))
>+
> else:
> """Convert the File to Section file one by one """
> for File in FileList:
> """ Copy Map file to FFS output path """
> Index = Index + 1
> Num = '%s.%d' %(SecNum, Index)
>-OutputFile = os.path.join( OutputPath, ModuleName +
>SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
> File = GenFdsGlobalVariable.MacroExtend(File, Dict)
>+if SectionType == BINARY_FILE_TYPE_FFS:
>+OutputFileList.append(File)
>+return OutputFileList, Align
>+OutputFile = os.path.join( OutputPath, ModuleName +
>SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
>
> #Get PE Section alignment when align is set to AUTO
> if self.Alignment == 'Auto' and (SectionType ==
>BINARY_FILE_TYPE_PE32 or SectionType == BINARY_FILE_TYPE_TE):
>diff --git a/BaseTools/Source/Python/GenFds/FdfParser.py
>b/BaseTools/Source/Python/GenFds/FdfParser.py
>index ea1c3eeb30..8446e3be4c 100644
>--- a/BaseTools/Source/Python/GenFds/FdfParser.py
>+++ b/BaseTools/Source/Python/GenFds/FdfParser.py
>@@ -3749,8 +3749,19 @@ class FdfParser:
> #
> def _GetEfiSection(self, Obj):
> OldPos = self.GetFileBufferPos()
>+EfiSectionObj = EfiSection()
> if not self._GetNextWord():
>-return False
>+CurrentLine =
>self._CurrentLine()[self.CurrentOffsetWithinLine:].split()[0].strip()
>+if self._Token == '{' and TAB_SPLIT in CurrentLine:
>+if self._IsToken(TAB_VALUE_SPLIT):
>+EfiSectionObj.FileExtension = self._GetFileExtension()
>+elif self._GetNextToken():
>+EfiSectionObj.FileName = self._Token
>+EfiSectionObj.SectionType = BINARY_FILE_TYPE_FFS
>+Obj.SectionList.append(EfiSectionObj)
>+return True
>+   

Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL to 1.1.1b

2019-05-22 Thread Wang, Jian J
Ard,


> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Ard
> Biesheuvel
> Sent: Tuesday, May 21, 2019 9:39 PM
> To: Laszlo Ersek 
> Cc: Wang, Jian J ; devel@edk2.groups.io; Lu, XiaoyuX
> ; Ye, Ting ; Leif Lindholm
> ; Gao, Liming 
> Subject: Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL to 1.1.1b
> 
> On Tue, 21 May 2019 at 13:23, Laszlo Ersek  wrote:
> >
> > Hi,
> >
> > On 05/21/19 11:09, Wang, Jian J wrote:
> > > Ard,
> > >
> > >> -Original Message-
> > >> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Ard
> > >> Biesheuvel
> > >> Sent: Tuesday, May 21, 2019 5:02 PM
> > >> To: Wang, Jian J 
> > >> Cc: devel@edk2.groups.io; Laszlo Ersek ; Lu, XiaoyuX
> > >> ; Ye, Ting ; Leif Lindholm
> > >> ; Gao, Liming 
> > >> Subject: Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL to
> 1.1.1b
> > >>
> > >> On Tue, 21 May 2019 at 09:43, Wang, Jian J  wrote:
> > >>>
> > >>> Hi Ard,
> > >>>
> > >>> Any comments?
> > >>>
> > >>> Regards,
> > >>> Jian
> > >>>
> >  -Original Message-
> >  From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf
> Of
> > >> Wang,
> >  Jian J
> >  Sent: Monday, May 20, 2019 9:41 AM
> >  To: devel@edk2.groups.io; ard.biesheu...@linaro.org; Laszlo Ersek
> >  
> >  Cc: Lu, XiaoyuX ; Ye, Ting ;
> Leif
> >  Lindholm ; Gao, Liming
> 
> >  Subject: Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL to
> > >> 1.1.1b
> > 
> >  Ard,
> > 
> > 
> > > -Original Message-
> > > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf
> Of
> > >> Ard
> > > Biesheuvel
> > > Sent: Friday, May 17, 2019 11:06 PM
> > > To: Laszlo Ersek 
> > > Cc: Wang, Jian J ; devel@edk2.groups.io; Lu,
> > >> XiaoyuX
> > > ; Ye, Ting ; Leif Lindholm
> > > ; Gao, Liming 
> > > Subject: Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL
> to
> >  1.1.1b
> > >
> > > On Fri, 17 May 2019 at 15:17, Laszlo Ersek  wrote:
> > >>
> > >> On 05/17/19 15:04, Laszlo Ersek wrote:
> > >>> On 05/17/19 07:11, Wang, Jian J wrote:
> >  Hi Laszlo,
> > 
> >  There's already a float library used in OpensslLib.inf.
> > 
> >  [LibraryClasses.ARM]
> >    ArmSoftFloatLib
> > 
> >  The problem is that the below instance doesn't implement
> > >> __aeabi_ui2d
> >  and __aeabi_d2uiz (I encountered this one as well)
> > 
> >    ArmPkg\Library\ArmSoftFloatLib\ArmSoftFloatLib.inf
> > 
> >  I think we can update this library support those two APIs. So what
> > >> about
> >  we still push the patch and file a BZ to fix this issue?
> > >>>
> > >>> I'm OK with that, but it will break ARM and AARCH64 platforms that
> > >>> consume OpensslLib (directly or through BaseCryptLib), so this
> question
> > >>> is up to Leif and Ard to decide.
> > >>
> > >> Correction: break ARM platforms only, not AARCH64.
> > >>
> > >
> > > We obviously need to fix this before we can upgrade to a new OpenSSL
> > >> version.
> > >
> > > Do we really have a need for the random functions? These seem the
> only
> > > ones that use floating point, which the UEFI spec does not permit, so
> > > it would be better if we could fix this by removing the dependency on
> > > FP in the first place (and get rid of ArmSoftFloatLib entirely)
> > >
> > 
> >  BaseCryptLib provides RandSeed/RandBytes interface which wrap
> openssl
> > >> rand
> >  functionalities. These interfaces are used by following components in
> edk2
> > 
> >    - CryptoPkg\Library\TlsLib\TlsInit.c
> >    - SecurityPkg\HddPassword\HddPasswordDxe.c
> > 
> >  Openssl components, like asn1, bn, evp, ocsp, pem, pkcs7, pkcs12, rsa,
> ssl (in
> >  addition
> >  to cms, dsa, srp, which are disabled in edk2) will call rand_* 
> >  interface as
> well.
> > 
> > >>
> > >> If we have both internal (to Openssl) and external users of the RNG
> > >> api, then I guess there is no way to work around this. It is
> > >> unfortunate, since the RNG code in OpenSSL doesn't actually use double
> > >> types except for keeping an entropy count, which could just as easily
> > >> be kept in an integer variable.
> >
> > (1) I think I agree... However, it seems that the first function (or one
> > of the first functions) in OpenSSL to take an "entropy" parameter, of
> > type "double", was RAND_add(). And the RAND_add() manual states,
> >
> >RAND_add() mixes the num bytes at buf into the PRNG state.
> >Thus, if the data at buf are unpredictable to an adversary,
> >this increases the uncertainty about the state and makes the
> >PRNG output less predictable. Suitable input comes from user
> >interaction (random key presses, mouse movements) 

[edk2-devel] [PATCH] EmulatorPkg: Fix bugs about BlockIo2

2019-05-22 Thread Zhiguang Liu
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=1760

Signal BlockIO2 callback event manually
Add some checks before readfile/writefile function.

Signed-off-by: Zhiguang Liu 

Cc: Jordan Justen 

Cc: Andrew Fish 

Cc: Ray Ni 
---
 EmulatorPkg/EmuBlockIoDxe/EmuBlockIo.c | 13 ++---
 EmulatorPkg/Win/Host/WinBlockIo.c  | 41 
+++--
 2 files changed, 45 insertions(+), 9 deletions(-)

diff --git a/EmulatorPkg/EmuBlockIoDxe/EmuBlockIo.c 
b/EmulatorPkg/EmuBlockIoDxe/EmuBlockIo.c
index 96424a82ae..b275d908c7 100644
--- a/EmulatorPkg/EmuBlockIoDxe/EmuBlockIo.c
+++ b/EmulatorPkg/EmuBlockIoDxe/EmuBlockIo.c
@@ -95,7 +95,11 @@ EmuBlockIo2ReadBlocksEx (
   OldTpl = gBS->RaiseTPL (TPL_CALLBACK);
 
   Status = Private->Io->ReadBlocks (Private->Io, MediaId, LBA, Token, 
BufferSize, Buffer);
-
+  if (Token != NULL && Token->Event != NULL) {
+if (!EFI_ERROR (Status)) {
+  gBS->SignalEvent (Token->Event);
+}
+  }
   gBS->RestoreTPL (OldTpl);
   return Status;
 }
@@ -150,9 +154,12 @@ EmuBlockIo2WriteBlocksEx (
   Private = EMU_BLOCK_IO2_PRIVATE_DATA_FROM_THIS (This);
 
   OldTpl = gBS->RaiseTPL (TPL_CALLBACK);
-
   Status = Private->Io->WriteBlocks (Private->Io, MediaId, LBA, Token, 
BufferSize, Buffer);
-
+  if (Token != NULL && Token->Event != NULL) {
+if (!EFI_ERROR (Status)) {
+  gBS->SignalEvent (Token->Event);
+}
+  }
   gBS->RestoreTPL (OldTpl);
   return Status;
 }
diff --git a/EmulatorPkg/Win/Host/WinBlockIo.c 
b/EmulatorPkg/Win/Host/WinBlockIo.c
index 5ccd17388e..8941ff1b17 100644
--- a/EmulatorPkg/Win/Host/WinBlockIo.c
+++ b/EmulatorPkg/Win/Host/WinBlockIo.c
@@ -300,9 +300,24 @@ WinNtBlockIoReadBlocks (
   DWORD   BytesRead;
   UINT64  DistanceToMove;
   UINT64  DistanceMoved;
-
+  UINT64  LastBlock;
   Private = WIN_NT_BLOCK_IO_PRIVATE_DATA_FROM_THIS (This);
-
+  if (!Private->Media->MediaPresent) {
+return EFI_NO_MEDIA;
+  }
+  if (Private->Media->MediaId != MediaId) {
+return EFI_MEDIA_CHANGED;
+  }
+  if ((UINTN) Buffer % Private->Media->IoAlign != 0) {
+return EFI_INVALID_PARAMETER;
+  }
+  if ((BufferSize % Private->BlockSize) != 0) {
+return EFI_BAD_BUFFER_SIZE;
+  }
+  LastBlock = Lba + (BufferSize / Private->BlockSize);
+  if (LastBlock > Private->Media->LastBlock+1) {
+return EFI_INVALID_PARAMETER;
+  }
   //
   // Seek to proper position
   //
@@ -371,9 +386,24 @@ WinNtBlockIoWriteBlocks (
   EFI_STATUS  Status;
   UINT64  DistanceToMove;
   UINT64  DistanceMoved;
-
+  UINT64  LastBlock;
   Private = WIN_NT_BLOCK_IO_PRIVATE_DATA_FROM_THIS (This);
-
+  if (!Private->Media->MediaPresent) {
+return EFI_NO_MEDIA;
+  }
+  if (Private->Media->MediaId != MediaId) {
+return EFI_MEDIA_CHANGED;
+  }
+  if ((UINTN) Buffer % Private->Media->IoAlign != 0) {
+return EFI_INVALID_PARAMETER;
+  }
+  if ((BufferSize % Private->BlockSize) != 0) {
+return EFI_BAD_BUFFER_SIZE;
+  }
+  LastBlock = Lba + (BufferSize / Private->BlockSize);
+  if (LastBlock > Private->Media->LastBlock+1) {
+return EFI_INVALID_PARAMETER;
+  }
   //
   // Seek to proper position
   //
@@ -450,14 +480,13 @@ WinNtBlockIoReset (
   )
 {
   WIN_NT_BLOCK_IO_PRIVATE *Private;
-
   Private = WIN_NT_BLOCK_IO_PRIVATE_DATA_FROM_THIS (This);
 
   if (Private->NtHandle != INVALID_HANDLE_VALUE) {
 CloseHandle (Private->NtHandle);
 Private->NtHandle = INVALID_HANDLE_VALUE;
   }
-
+  WinNtBlockIoCreateMapping (This, Private->Media);
   return EFI_SUCCESS;
 }
 
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41265): https://edk2.groups.io/g/devel/message/41265
Mute This Topic: https://groups.io/mt/31728072/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V2] Maintainers.txt: Add maintainers

2019-05-22 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: Desimone, Nathaniel L
> Sent: Wednesday, May 22, 2019 11:35 AM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A ; Chaganty, Rangasai V
> 
> Subject: [edk2-platforms][PATCH V2] Maintainers.txt: Add maintainers
> 
> Add maintainers for MinPlatformPkg, ClevoOpenBoardPkg, and
> KabylakeSiliconPkg
> 
> Cc: Michael Kubacki 
> Cc: Sai Chaganty 
> Signed-off-by: Nate DeSimone 
> ---
>  Maintainers.txt | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/Maintainers.txt b/Maintainers.txt index 927cd5ed93..e900523eee
> 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -68,10 +68,12 @@ R: Nate DeSimone
>   Platform/Intel/KabylakeOpenBoardPkg
>  M: Chasel Chiu 
>  M: Michael Kubacki 
> +M: Nate DeSimone 
> 
>  Platform/Intel/MinPlatformPkg
>  M: Michael Kubacki 
>  M: Chasel Chiu 
> +M: Nate DeSimone 
>  R: Liming Gao 
> 
>  Platform/Intel/PurleyOpenBoardPkg
> @@ -95,6 +97,7 @@ M: Yi Qian 
> Silicon/Intel/KabylakeSiliconPkg
>  M: Chasel Chiu 
>  M: Michael A Kubacki 
> +M: Sai Chaganty 
> 
>  Silicon/Intel/LewisburgPkg
>  M: Piwko, Maciej 
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41264): https://edk2.groups.io/g/devel/message/41264
Mute This Topic: https://groups.io/mt/31723265/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH] BaseTools:Make BaseTools support the correct RAW FFS FILE generation

2019-05-22 Thread Fan, ZhijuX
BZ:https://bugzilla.tianocore.org/show_bug.cgi?id=1765

RAW FFS File has no section for its data. For RAW FFS File,
directly call GenFfs tool to generate FFS file.

Ffs Rule:
[Rule.Common.USER_DEFINED.MicroCode]
  FILE RAW = $(NAMED_GUID) {
SectionType FileType $(INF_OUTPUT)/$(MODULE_NAME).bin
  }
As shown in the rule above,if SectionType and FileType not defined,
FFS files are generated directly, and no other type of file is
generated.

Cc: Bob Feng 
Cc: Liming Gao 
Signed-off-by: Zhiju.Fan 
---
 BaseTools/Source/Python/Common/DataType.py   |  1 +
 BaseTools/Source/Python/GenFds/EfiSection.py | 10 --
 BaseTools/Source/Python/GenFds/FdfParser.py  | 14 --
 BaseTools/Source/Python/GenFds/Section.py|  7 ++-
 4 files changed, 27 insertions(+), 5 deletions(-)

diff --git a/BaseTools/Source/Python/Common/DataType.py 
b/BaseTools/Source/Python/Common/DataType.py
index 780711bf8e..1879aea665 100644
--- a/BaseTools/Source/Python/Common/DataType.py
+++ b/BaseTools/Source/Python/Common/DataType.py
@@ -121,6 +121,7 @@ BINARY_FILE_TYPE_VER = 'VER'
 BINARY_FILE_TYPE_UI = 'UI'
 BINARY_FILE_TYPE_BIN = 'BIN'
 BINARY_FILE_TYPE_FV = 'FV'
+BINARY_FILE_TYPE_FFS = 'FFS'
 
 PLATFORM_COMPONENT_TYPE_LIBRARY_CLASS = 'LIBRARY_CLASS'
 PLATFORM_COMPONENT_TYPE_MODULE = 'MODULE'
diff --git a/BaseTools/Source/Python/GenFds/EfiSection.py 
b/BaseTools/Source/Python/GenFds/EfiSection.py
index 302f244faf..5346a0569f 100644
--- a/BaseTools/Source/Python/GenFds/EfiSection.py
+++ b/BaseTools/Source/Python/GenFds/EfiSection.py
@@ -93,7 +93,7 @@ class EfiSection (EfiSectionClassObject):
 if '.depex' in SuffixMap:
 FileList.append(Filename)
 else:
-FileList, IsSect = Section.Section.GetFileList(FfsInf, 
self.FileType, self.FileExtension, Dict, IsMakefile=IsMakefile)
+FileList, IsSect = Section.Section.GetFileList(FfsInf, 
self.FileType, self.FileExtension, Dict, IsMakefile=IsMakefile, 
SectionType=SectionType)
 if IsSect :
 return FileList, self.Alignment
 
@@ -227,14 +227,20 @@ class EfiSection (EfiSectionClassObject):
 else:
 EdkLogger.error("GenFds", GENFDS_ERROR, "Output file for 
%s section could not be found for %s" % (SectionType, InfFileName))
 
+elif len(FileList) > 1 and SectionType == BINARY_FILE_TYPE_FFS:
+EdkLogger.error("GenFds", GENFDS_ERROR,"Files suffixed with %s 
are not allowed to have more than one file in %s[Binaries] section" % 
(self.FileExtension, InfFileName))
+
 else:
 """Convert the File to Section file one by one """
 for File in FileList:
 """ Copy Map file to FFS output path """
 Index = Index + 1
 Num = '%s.%d' %(SecNum, Index)
-OutputFile = os.path.join( OutputPath, ModuleName + 
SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
 File = GenFdsGlobalVariable.MacroExtend(File, Dict)
+if SectionType == BINARY_FILE_TYPE_FFS:
+OutputFileList.append(File)
+return OutputFileList, Align
+OutputFile = os.path.join( OutputPath, ModuleName + 
SUP_MODULE_SEC + Num + SectionSuffix.get(SectionType))
 
 #Get PE Section alignment when align is set to AUTO
 if self.Alignment == 'Auto' and (SectionType == 
BINARY_FILE_TYPE_PE32 or SectionType == BINARY_FILE_TYPE_TE):
diff --git a/BaseTools/Source/Python/GenFds/FdfParser.py 
b/BaseTools/Source/Python/GenFds/FdfParser.py
index ea1c3eeb30..8446e3be4c 100644
--- a/BaseTools/Source/Python/GenFds/FdfParser.py
+++ b/BaseTools/Source/Python/GenFds/FdfParser.py
@@ -3749,8 +3749,19 @@ class FdfParser:
 #
 def _GetEfiSection(self, Obj):
 OldPos = self.GetFileBufferPos()
+EfiSectionObj = EfiSection()
 if not self._GetNextWord():
-return False
+CurrentLine = 
self._CurrentLine()[self.CurrentOffsetWithinLine:].split()[0].strip()
+if self._Token == '{' and TAB_SPLIT in CurrentLine:
+if self._IsToken(TAB_VALUE_SPLIT):
+EfiSectionObj.FileExtension = self._GetFileExtension()
+elif self._GetNextToken():
+EfiSectionObj.FileName = self._Token
+EfiSectionObj.SectionType = BINARY_FILE_TYPE_FFS
+Obj.SectionList.append(EfiSectionObj)
+return True
+else:
+return False
 SectionName = self._Token
 
 if SectionName not in {
@@ -3816,7 +3827,6 @@ class FdfParser:
 Obj.SectionList.append(FvImageSectionObj)
 return True
 
-EfiSectionObj = EfiSection()
 EfiSectionObj.SectionType = SectionName
 
 if not self._GetNextToken():
diff --git a/BaseTools/Source/Python/GenFds/Section.py 

Re: [edk2-devel] RFC for Edk2-ToolEnv

2019-05-22 Thread Michael D Kinney
Hi Sean,

Does the PIP module here support both local platform builds and 
CI builds?

I am looking at the name of the repo and trying to align with
the edk2-tools-library repo name so it is obvious the two repos
are related.  Maybe focus on the CI part for the name and we 
reuse the CI features to simplify local builds.

edk2-tools-ci

Finalizing the name is the only open I am aware of.

Thanks,

Mike

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io]
> On Behalf Of rebe...@bluestop.org
> Sent: Tuesday, May 14, 2019 4:34 PM
> To: Sean ;
> devel@edk2.groups.io
> Subject: Re: [edk2-devel] RFC for Edk2-ToolEnv
> 
> On 2019-05-14 17:23, sean.brogan via groups.io wrote:
> > Take a look at the proposed content and how it is
> used.  We even have
> > examples of calling from DevOps and i don't think
> Jenkins would be any
> > different.  I don't think we are trying to duplicate CI
> > functionality.  We are providing the "last mile" so
> that those CI
> > engines can run EDK specific tests and tools.  Standard
> CI engines
> > have no concept of packages, DSC, FDF, INFs, firmware,
> etc.
> 
> 
> Okay, that's great. Of course we do also have lots of
> code running on
> the CI server at work, not the client, that does things
> like packaging
> etc., and this proposal will include server-side code
> too.
> 
> Also, I don't think there is anything that'll be as
> nicely integrated as
> this, so I'm happy with it.
> 
> 
> --
> Rebecca Cran
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41262): https://edk2.groups.io/g/devel/message/41262
Mute This Topic: https://groups.io/mt/31614611/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] RFC for Edk2-Library

2019-05-22 Thread Michael D Kinney
Hi Sean,

Can you send an RFC V2 that makes the following changes:

1) Add use of python virtual environments
2) Update Repository name: edk2-tools-library
3) Provide a summary of the APIs/Services that this PIP module 
   provides and the APIs/Services from the edk2 repo that this
   PIP module depends on.
4) Contribution process.  Add recommendation that PRs be focused
   on changes that make sense to be squashed.  Submit a different
   PR for a different feature/issue.  Break up a complex PR into
   multiple PRs.
5) Remove the following bullet:

   "* Potentially move content from basetools/source/python/common/*"

   We can discuss this concept after TianoCore platforms are
   successfully using these new features and the overlap between
   the edk2 repo and edk2-tools-library repo is clearly understood.

A follow on task should evaluate GitHub PR options for submitting
and preserving a patch series.

Thanks,

Mike


> -Original Message-
> From: Laszlo Ersek [mailto:ler...@redhat.com]
> Sent: Monday, May 13, 2019 1:29 PM
> To: Kinney, Michael D ;
> devel@edk2.groups.io; sean.bro...@microsoft.com
> Subject: Re: [edk2-devel] RFC for Edk2-Library
> 
> On 05/13/19 20:20, Kinney, Michael D wrote:
> > Laszlo,
> >
> > On Windows build systems, we have to install OpenSSL
> command line
> > utilities.  For all host systems, the OpenSSL command
> line
> > utilities need to be in the system path.  My point is
> that this
> > is similar to other dependencies like iASL and NASM.
> 
> OK. I think I must have misunderstood you at some point.
> Sorry about that.
> 
> > For the patch discussion, I did not mean to confuse
> things.  From
> > one perspective, there are two types of patch
> submissions.  Single
> > commit (no series) and multiple commits (patch series).
> The squash
> > merge of a PR works just fine for the single commit (no
> series) type.
> > There may be feedback/comments that require code
> changes and once the
> > PR is accepted, the history in the repository shows a
> single commit.
> > As the PR evolves, commits are made on the PR to
> address each piece
> > of feedback.  Squashing all of these together at the
> time the PR is
> > accepted is the correct action and matches what we do
> the for email
> > based review process.  The final result for both PR and
> email is a
> > single commit with a cleaned up commit message.
> 
> OK.
> 
> > You may consider the single commit (no series) type
> more rare than the
> > multiple commit (patch series) type.  However, there
> may be cases where
> > a multiple commit (patch series) was used where the
> changes could have
> > been submitted as a set of single commit (no series)
> changes.
> 
> OK.
> 
> Thanks
> Laszlo
> 
> >
> > Best regards,
> >
> > Mike
> >
> >> -Original Message-
> >> From: devel@edk2.groups.io
> [mailto:devel@edk2.groups.io]
> >> On Behalf Of Laszlo Ersek
> >> Sent: Monday, May 13, 2019 3:46 AM
> >> To: Kinney, Michael D ;
> >> devel@edk2.groups.io; sean.bro...@microsoft.com
> >> Subject: Re: [edk2-devel] RFC for Edk2-Library
> >>
> >> On 05/10/19 02:01, Kinney, Michael D wrote:
> >>> Laszlo,
> >>>
> >>> 1) We also use OpenSSL command line tool to locally
> >> sign
> >>>capsules and recovery images for local testing.
> So
> >> both
> >>>tool dependency and source dependency apply to the
> >> OpenSSL
> >>>content.
> >>
> >> I haven't used the tools yet that you refer to, so I'm
> >> unsure how
> >> exactly they invoke the "openssl" utility. If they
> just
> >> rely on the PATH
> >> environment variable, then what they invoke comes from
> >> the system-wide
> >> openssl package.
> >>
> >>>
> >>> 2) If a dev submits a PR, and there are many review
> >> comments
> >>>that require code changes, then those code changes
> >> are
> >>>added to that PR until all feedback is addressed.
> >>
> >> I don't understand how. Let's say the pull request
> refers
> >> to a branch
> >> with three commits, and the majority of the review
> >> comments request
> >> updates for patch #2 (i.e., in the middle). How can
> the
> >> submitter "add
> >> changes to the PR"? It is patch #2 that needs to be
> >> reworked, which will
> >> require rebases, and so the hash of the HEAD commit of
> >> the topic branch
> >> (patch #3) will change as well.
> >>
> >>>At that
> >>>point, if the change is something that should be
> in
> >> a single
> >>>commit, then doing a squash merge with a cleaned
> up
> >> commit
> >>>message would be appropriate.
> >>
> >> I don't understand -- we modify only patch #2, yes, to
> >> address review
> >> comments, but why does that justify squashing #1
> through
> >> #3 into a
> >> single commit?
> >>
> >>>And the history of all the
> >>>review feedback preserved in the PR.
> >>
> >> That's good (but it could be better -- see the lacking
> >> email
> >> integration. Anyway this is not strictly tied to my
> >> concern with
> >> squash-on-merge).
> >>
> >>>
> >>>If we create a 2nd 

[edk2-devel] edk2-stable201905 features and soft/hard freeze and release date

2019-05-22 Thread Michael D Kinney
Hello,

There have been a few discussion during the soft freeze for
edk2-stable201905 on changes that can be accepted or not.

The TianoCore Stewards met today to discuss these topics and
make some decisions on the following features.

* Update OpenSSL version to upcoming 1.1.1
  https://bugzilla.tianocore.org/show_bug.cgi?id=1089

  This feature must be completed for edk2-stable201905.
  We are willing to extend the soft freeze, hard freeze,
  and release date to make sure this feature is completed.
  Please complete the patches and reviews and perform all
  validation required for this feature and provide status
  to the mailing list.  The release date will be pushed out
  if required to accommodate this feature.

* Move network related components from MdeModulePkg to NetworkPkg
  https://bugzilla.tianocore.org/show_bug.cgi?id=1293

  Updating MdeModulePkg to remove the extra build of the network
  modules is considered low risk and should be completed for 
  edk2-stable201905.

* Standardize EDK II PI root-of-trust verification implementation
  https://bugzilla.tianocore.org/show_bug.cgi?id=1617

  Move to edk-stable201908

* FeatureFlagExpression Support in LibraryClasses section of INF file
  https://bugzilla.tianocore.org/show_bug.cgi?id=1446

  Move to edk-stable201908

* Add new tool chain for LLVM/CLANG8.0
  https://bugzilla.tianocore.org/show_bug.cgi?id=1603

  Move to edk-stable201908

Please let us know if there are any other features that require
consideration for edk2-stable201905.

Of course critical bug fixes are accepted during the soft/hard
freeze.  If there is any doubt if a patch is a bug fix or a 
feature, please ask before doing any commits.

Thanks,

Mike




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41260): https://edk2.groups.io/g/devel/message/41260
Mute This Topic: https://groups.io/mt/31727161/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch 1/3] NetworkPkg: Move Network library and drivers from MdeModulePkg to NetworkPkg

2019-05-22 Thread Wu, Jiaxin
Reviewed-by: Jiaxin Wu 



> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Liming Gao
> Sent: Wednesday, May 15, 2019 8:02 PM
> To: devel@edk2.groups.io
> Cc: Fu, Siyuan ; Wu, Jiaxin 
> Subject: [edk2-devel] [Patch 1/3] NetworkPkg: Move Network library and
> drivers from MdeModulePkg to NetworkPkg
> 
> Signed-off-by: Liming Gao 
> Cc: Siyuan Fu 
> Cc: Jiaxin Wu 
> ---
>  .../Network => NetworkPkg}/ArpDxe/ArpDriver.c  |  0
>  .../Universal/Network => NetworkPkg}/ArpDxe/ArpImpl.c  |  0
>  .../Universal/Network => NetworkPkg}/ArpDxe/ArpMain.c  |  0
>  .../Network => NetworkPkg}/ArpDxe/ComponentName.c  |  0
>  .../Network => NetworkPkg}/Dhcp4Dxe/ComponentName.c|  0
>  .../Network => NetworkPkg}/Dhcp4Dxe/Dhcp4Driver.c  |  0
>  .../Network => NetworkPkg}/Dhcp4Dxe/Dhcp4Impl.c|  0
>  .../Network => NetworkPkg}/Dhcp4Dxe/Dhcp4Io.c  |  0
>  .../Network => NetworkPkg}/Dhcp4Dxe/Dhcp4Option.c  |  0
>  .../Universal/Network => NetworkPkg}/DpcDxe/Dpc.c  |  0
>  .../Network => NetworkPkg}/Ip4Dxe/ComponentName.c  |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Common.c  |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Config2Impl.c |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Config2Nv.c   |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Driver.c  |  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4Icmp.c  |  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4If.c|  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4Igmp.c  |  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4Impl.c  |  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4Input.c |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Option.c  |  0
>  .../Network => NetworkPkg}/Ip4Dxe/Ip4Output.c  |  0
>  .../Universal/Network => NetworkPkg}/Ip4Dxe/Ip4Route.c |  0
>  .../Library/DxeDpcLib/DpcLib.c |  0
>  .../Library/DxeHttpLib/DxeHttpLib.c|  0
>  .../Library/DxeIpIoLib/DxeIpIoLib.c|  0
>  .../Library/DxeNetLib/DxeNetLib.c  |  0
>  .../Library/DxeNetLib/NetBuffer.c  |  0
>  .../Library/DxeTcpIoLib/DxeTcpIoLib.c  |  0
>  .../Library/DxeUdpIoLib/DxeUdpIoLib.c  |  0
>  .../Network => NetworkPkg}/MnpDxe/ComponentName.c  |  0
>  .../Network => NetworkPkg}/MnpDxe/MnpConfig.c  |  0
>  .../Network => NetworkPkg}/MnpDxe/MnpDriver.c  |  0
>  .../Universal/Network => NetworkPkg}/MnpDxe/MnpIo.c|  0
>  .../Universal/Network => NetworkPkg}/MnpDxe/MnpMain.c  |  0
>  .../Universal/Network => NetworkPkg}/MnpDxe/MnpVlan.c  |  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/ComponentName.c   |  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Driver.c|  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Impl.c  |  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Option.c|  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Rrq.c   |  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Support.c   |  0
>  .../Network => NetworkPkg}/Mtftp4Dxe/Mtftp4Wrq.c   |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Callback.c |  0
>  .../Network => NetworkPkg}/SnpDxe/ComponentName.c  |  0
>  .../Network => NetworkPkg}/SnpDxe/Get_status.c |  0
>  .../Network => NetworkPkg}/SnpDxe/Initialize.c |  0
>  .../Network => NetworkPkg}/SnpDxe/Mcast_ip_to_mac.c|  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Nvdata.c   |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Receive.c  |  0
>  .../Network => NetworkPkg}/SnpDxe/Receive_filters.c|  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Reset.c|  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Shutdown.c |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Snp.c  |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Start.c|  0
>  .../Network => NetworkPkg}/SnpDxe/Station_address.c|  0
>  .../Network => NetworkPkg}/SnpDxe/Statistics.c |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Stop.c |  0
>  .../Universal/Network => NetworkPkg}/SnpDxe/Transmit.c |  0
>  .../Network => NetworkPkg}/SnpDxe/WaitForPacket.c  |  0
>  .../Network => NetworkPkg}/Udp4Dxe/ComponentName.c |  0
>  .../Network => NetworkPkg}/Udp4Dxe/Udp4Driver.c|  0
>  .../Network => NetworkPkg}/Udp4Dxe/Udp4Impl.c  |  0
>  .../Network => NetworkPkg}/Udp4Dxe/Udp4Main.c  |  0
>  .../VlanConfigDxe/ComponentName.c  |  0
>  .../VlanConfigDxe/VlanConfigDriver.c   |  0
>  .../VlanConfigDxe/VlanConfigImpl.c |  0
>  .../Network => NetworkPkg}/ArpDxe/ArpDriver.h  |  0
>  .../Universal/Network => NetworkPkg}/ArpDxe/ArpDxe.inf |  0
>  .../Universal/Network => NetworkPkg}/ArpDxe/ArpDxe.uni |  0
>  .../Network => NetworkPkg}/ArpDxe/ArpDxeExtra.uni  |  0
>  .../Universal/Network => NetworkPkg}/ArpDxe/ArpImpl.h  |  0
>  .../Network => 

Re: [edk2-devel] [PATCH V2] UefiCpuPkg CpuCommFeaturesLib: Fix ASSERT if LMCE is supported

2019-05-22 Thread Zeng, Star
Laszlo,

> -Original Message-
> From: Laszlo Ersek [mailto:ler...@redhat.com]
> Sent: Wednesday, May 22, 2019 6:32 PM
> To: devel@edk2.groups.io; Zeng, Star 
> Cc: Dong, Eric ; Ni, Ray ; Kumar,
> Chandana C ; Li, Kevin Y
> 
> Subject: Re: [edk2-devel] [PATCH V2] UefiCpuPkg CpuCommFeaturesLib: Fix
> ASSERT if LMCE is supported
> 
> On 05/22/19 12:17, Zeng, Star wrote:
> > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1829
> >
> > There will be ASSERT if LMCE is supported as below.
> > DXE_ASSERT!: [CpuFeaturesDxe]
> >   XXX\UefiCpuPkg\Library\CpuCommonFeaturesLib\MachineCheck.c (342):
> > ConfigData != ((void *) 0)
> >
> > The code should get Config Data and FeatureControlGetConfigData could
> > be used.
> >
> > This issue is there since the code was added at the commit below.
> >
> > Revision: 3d6275c1137c9633ce24e31522b71105367bd6a0
> > Date: 2017/8/4 8:46:41
> > UefiCpuPkg CpuCommonFeaturesLib: Enable LMCE feature.
> >
> > The commits below are also related to move the code.
> >
> > Revision: 023387144299741d727521b425ef443438aecc1f
> > Date: 2017/9/1 10:12:38
> > UefiCpuPkg/Lmce.c Remove useless file.
> >
> > Revision: 306a5bcc6b0170d28b0db10bd359817bb4b1db9f
> > Date: 2017/8/17 11:40:38
> > UefiCpuPkg/CpuCommonFeaturesLib: Merge machine check code to same
> file.
> >
> > So, the code should not be tested at all on a platform that supports
> > LMCE.
> >
> > BTW: A typo in LmceInitialize is also fixed.
> > The typo is introduced by the commit below.
> >
> > Revision: d28daaddb3e732468e930a809d3d3943a5de9558
> > Date: 2018/10/17 9:24:05
> > UefiCpuPkg/CpuCommonFeaturesLib: Register MSR base on scope Info.
> >
> > Cc: Laszlo Ersek 
> > Cc: Eric Dong 
> > Cc: Ray Ni 
> > Cc: Chandana Kumar 
> > Cc: Kevin Li 
> > Signed-off-by: Star Zeng 
> >
> > Notes:
> > v2: Based on Laszlo's great feedback.
> > - Update Ray's name and email address to match Maintainers.txt.
> > - Remove "Change-Id" line that was added unintended.
> > - Add more code history.
> >
> > ---
> 
> [*]
> 
> >  UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c |
> 2 +-
> >  UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c | 2 +-
> >  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> Thanks for the update. Just one more quick note:
> 
> - if you want to include the v2 changes in the commit message, then please
> describe them above your Signed-off-by (in the normal commit message
> body).
> 
> - If you don't want the v2 notes to be present in the final commit message,
> then please add them between the "---" mark, and the diffstat.
> I marked the location above with [*]. Then "git am" will automatically ignore
> the notes.

Yeah, it is great to learn this.

Thanks,
Star

> 
> No need to resubmit now, it's just a hint for the future.
> 
> Thanks
> Laszlo
> 
> > diff --git
> > a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> > b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> > index 738b57dc87f9..9ddc6ce9d476 100644
> > ---
> a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> > +++
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> > @@ -214,7 +214,7 @@ CpuCommonFeaturesLibConstructor (
> >if (IsCpuFeatureSupported (CPU_FEATURE_LMCE)) {
> >  Status = RegisterCpuFeature (
> > "LMCE",
> > -   NULL,
> > +   FeatureControlGetConfigData,
> > LmceSupport,
> > LmceInitialize,
> > CPU_FEATURE_LMCE,
> > diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> > b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> > index 9ee559130080..2528e0044ecb 100644
> > --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> > +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> > @@ -322,7 +322,7 @@ LmceInitialize (
> >MSR_IA32_FEATURE_CONTROL_REGISTER*MsrRegister;
> >
> >//
> > -  // The scope of FastStrings bit in the MSR_IA32_MISC_ENABLE is core
> > for below processor type, only program
> > +  // The scope of LcmeOn bit in the MSR_IA32_MISC_ENABLE is core for
> > + below processor type, only program
> >// MSR_IA32_MISC_ENABLE for thread 0 in each core.
> >//
> >if (IS_SILVERMONT_PROCESSOR (CpuInfo->DisplayFamily,
> > CpuInfo->DisplayModel) ||
> >


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41256): https://edk2.groups.io/g/devel/message/41256
Mute This Topic: https://groups.io/mt/31718348/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms][PATCH V2] Maintainers.txt: Add maintainers

2019-05-22 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 


> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Nate
> DeSimone
> Sent: Thursday, May 23, 2019 2:35 AM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A ; Chaganty, Rangasai V
> 
> Subject: [edk2-devel] [edk2-platforms][PATCH V2] Maintainers.txt: Add
> maintainers
> 
> Add maintainers for MinPlatformPkg, ClevoOpenBoardPkg, and
> KabylakeSiliconPkg
> 
> Cc: Michael Kubacki 
> Cc: Sai Chaganty 
> Signed-off-by: Nate DeSimone 
> ---
>  Maintainers.txt | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/Maintainers.txt b/Maintainers.txt index 927cd5ed93..e900523eee
> 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -68,10 +68,12 @@ R: Nate DeSimone 
> Platform/Intel/KabylakeOpenBoardPkg
>  M: Chasel Chiu 
>  M: Michael Kubacki 
> +M: Nate DeSimone 
> 
>  Platform/Intel/MinPlatformPkg
>  M: Michael Kubacki 
>  M: Chasel Chiu 
> +M: Nate DeSimone 
>  R: Liming Gao 
> 
>  Platform/Intel/PurleyOpenBoardPkg
> @@ -95,6 +97,7 @@ M: Yi Qian 
> Silicon/Intel/KabylakeSiliconPkg
>  M: Chasel Chiu 
>  M: Michael A Kubacki 
> +M: Sai Chaganty 
> 
>  Silicon/Intel/LewisburgPkg
>  M: Piwko, Maciej 
> --
> 2.16.2.windows.1
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41255): https://edk2.groups.io/g/devel/message/41255
Mute This Topic: https://groups.io/mt/31723265/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms] [PATCH v2 3/5] KabylakeOpenBoardPkg: Added GCC5 build support

2019-05-22 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 


> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Agyeman, Prince
> Sent: Tuesday, May 21, 2019 11:08 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> 
> Subject: [edk2-devel] [edk2-platforms] [PATCH v2 3/5] KabylakeOpenBoardPkg:
> Added GCC5 build support
> 
> From: Prince Agyeman 
> 
> Fixed:
> * Include file paths in dec
> * Gcc build options
> 
> Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm 
> version
> 2.11.08
> 
> Signed-off-by: Prince Agyeman 
> ---
>  .../KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildOption.dsc   |
> 4 +++-
>  Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec| 6
> +++---
>  2 files changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git
> a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildO
> ption.dsc
> b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuild
> Option.dsc
> index 04c5786..8e885cc 100644
> ---
> a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildO
> ption.dsc
> +++
> b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuild
> +++ Option.dsc
> @@ -1,7 +1,7 @@
>  ## @file
>  # platform build option configuration file.
>  #
> -# Copyright (c) 2017, Intel Corporation. All rights reserved.
> +# Copyright (c) 2017 - 2019, Intel Corporation. All rights
> +reserved.
>  #
>  # SPDX-License-Identifier: BSD-2-Clause-Patent  # @@ -102,6 +102,7 @@
> DEFINE DSC_PLTPKG_FEATURE_BUILD_OPTIONS =
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(  # For IA32 Specific Build Flag  #
>  GCC:   *_*_IA32_PP_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> +GCC:   *_*_IA32_CC_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> -D PI_SPECIFICATION_VERSION=0x00010015 -DASF_PEI -Wno-unused
> -Wl,--allow-multiple-definition
>  MSFT:  *_*_IA32_ASM_FLAGS =
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
>  MSFT:  *_*_IA32_CC_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> $(OPTIMIZE_DISABLE_OPTIONS) -D PI_SPECIFICATION_VERSION=0x00010015
> -DASF_PEI
>  MSFT:  *_*_IA32_VFRPP_FLAGS   =
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(OPTIMIZE_DISABLE_OPTIONS)
> @@ -124,6 +125,7 @@ MSFT:  *_*_IA32_ASLCC_FLAGS   =
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(OPTIMIZE_D
>  # For X64 Specific Build Flag
>  #
>  GCC:   *_*_X64_PP_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> +GCC:   *_*_X64_CC_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> -D PI_SPECIFICATION_VERSION=0x00010015 -Wno-unused
> -Wl,--allow-multiple-definition
>  MSFT:  *_*_X64_ASM_FLAGS  =
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
>  MSFT:  *_*_X64_CC_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
> $(OPTIMIZE_DISABLE_OPTIONS) -D PI_SPECIFICATION_VERSION=0x00010015
>  MSFT:  *_*_X64_VFRPP_FLAGS=
> $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(OPTIMIZE_DISABLE_OPTIONS)
> diff --git a/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
> b/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
> index e326598..68977d0 100644
> --- a/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
> +++ b/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
> @@ -5,7 +5,7 @@
>  # INF files to generate AutoGen.c and AutoGen.h files  # for the build
> infrastructure.
>  #
> -# Copyright (c) 2017, Intel Corporation. All rights reserved.
> +# Copyright (c) 2017 - 2019, Intel Corporation. All rights
> +reserved.
>  #
>  # SPDX-License-Identifier: BSD-2-Clause-Patent  # @@ -20,8 +20,8 @@
> PACKAGE_GUID = 0A8BA6E8-C8AC-4AC1-87AC-52772FA6AE5E
> 
>  [Includes]
>  Include
> -KabylakeRvp3\Include
> -Features\Tbt\Include
> +KabylakeRvp3/Include
> +Features/Tbt/Include
> 
>  [Guids]
> 
> --
> 2.7.4
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41254): https://edk2.groups.io/g/devel/message/41254
Mute This Topic: https://groups.io/mt/31693034/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms] [PATCH v2 2/5] KabylakeSiliconPkg: Casting functions to EFIAPI

2019-05-22 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 


> -Original Message-
> From: Agyeman, Prince
> Sent: Tuesday, May 21, 2019 11:08 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> ; Kubacki, Michael A
> ; Kinney, Michael D
> ; Desimone, Nathaniel L
> ; Gao, Liming ; Sinha,
> Ankit 
> Subject: [edk2-platforms] [PATCH v2 2/5] KabylakeSiliconPkg: Casting functions
> to EFIAPI
> 
> From: Prince Agyeman 
> 
> This fixes the calling convension issues in gcc
> 
> Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm 
> version
> 2.11.08
> 
> Cc: Michael Kubacki 
> Cc: Michael D Kinney 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> Cc: Ankit Sinha 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h | 3
> ++-
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c | 3
> ++-
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h|
> 4 +++-
>  .../Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore.c|
> 4 +++-
>  4 files changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> index 44f151c..666340e 100644
> --- a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> +++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> @@ -1,7 +1,7 @@
>  /** @file
>Header file for PCH Init SMM Handler
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -205,6 +205,7 @@ PchPcieLinkEqHandlerFunction (
> 
>  **/
>  VOID
> +EFIAPI
>  PchPcieIoTrapSmiCallback (
>IN EFI_HANDLE DispatchHandle,
>IN EFI_SMM_IO_TRAP_CONTEXT*CallbackContext,
> diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> index aed33bb..847fbfb 100644
> --- a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> +++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> @@ -1,7 +1,7 @@
>  /** @file
>PCH Pcie SMM Driver Entry
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -238,6 +238,7 @@ PchPciePmIoTrapSmiCallback (
> 
>  **/
>  VOID
> +EFIAPI
>  PchPcieIoTrapSmiCallback (
>IN  EFI_HANDLEDispatchHandle,
>IN  EFI_SMM_IO_TRAP_CONTEXT*CallbackContext,
> diff --git
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> index 508832e..a9f0664 100644
> --- a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> +++
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> @@ -1,7 +1,7 @@
>  /** @file
>Prototypes and defines for the PCH SMM Dispatcher.
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -510,6 +510,7 @@ typedef struct {
>registered and the SMI source has been 
> enabled.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL  *This,
>IN  EFI_SMM_HANDLER_ENTRY_POINT2  DispatchFunction,
> @@ -530,6 +531,7 @@ PchSmmCoreRegister (
>@retval EFI_INVALID_PARAMETER   Handle is invalid.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreUnRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL *This,
>IN  EFI_HANDLE   *DispatchHandle
> diff --git
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore.
> c
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore.
> c
> index 0c494bf..cb3bfba 100644
> ---
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore.
> c
> +++
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCo
> +++ re.c
> @@ -2,7 +2,7 @@
>This driver is responsible for the registration of child drivers
>and the abstraction of the PCH SMI sources.
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -325,6 +325,7 @@ SmiInputValueDuplicateCheck (
>registered and the SMI source has been 
> enabled.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL  *This,
>IN  EFI_SMM_HANDLER_ENTRY_POINT2  

Re: [edk2-devel] [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build support

2019-05-22 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 


> -Original Message-
> From: Desimone, Nathaniel L
> Sent: Thursday, May 23, 2019 3:12 AM
> To: Agyeman, Prince ; devel@edk2.groups.io
> Cc: Chiu, Chasel ; Kubacki, Michael A
> ; Kinney, Michael D
> ; Gao, Liming ; Sinha,
> Ankit 
> Subject: RE: [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5
> build support
> 
> Reviewed-by: Nate DeSimone 
> 
> -Original Message-
> From: Agyeman, Prince
> Sent: Monday, May 20, 2019 8:08 PM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> ; Kubacki, Michael A
> ; Kinney, Michael D
> ; Desimone, Nathaniel L
> ; Gao, Liming ; Sinha,
> Ankit 
> Subject: [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build
> support
> 
> From: Prince Agyeman 
> 
> Fixes:
> * Replacing .asm and .S with nasm in SecFspWrapperPlatformSecLib for
> cross-platform build support
> * Modified RuleInclude.fdf
> * Modified python files to be OS independent
> 
> Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm 
> version
> 2.11.08
> 
> Cc: Michael Kubacki 
> Cc: Michael D Kinney 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> Cc: Ankit Sinha 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  .../Ia32/PeiCoreEntry.S| 117 ---
>  .../Ia32/{PeiCoreEntry.asm => PeiCoreEntry.nasm}   |  46 +--
>  .../SecFspWrapperPlatformSecLib/Ia32/SecEntry.S| 342 
> -
>  .../Ia32/{SecEntry.asm => SecEntry.nasm}   | 132 
>  .../SecFspWrapperPlatformSecLib/Ia32/Stack.S   |  67 
>  .../Ia32/{Stack.asm => Stack.nasm} |  39 ++-
>  .../SecFspWrapperPlatformSecLib.inf|  12 +-
>  .../MinPlatformPkg/Include/Fdf/RuleInclude.fdf |   6 +-
>  .../Tools/Fsp/RebaseAndPatchFspBinBaseAddress.py   |   2 +-
>  .../MinPlatformPkg/Tools/PatchFv/PatchBinFv.py |   8 +-
>  .../MinPlatformPkg/Tools/PatchFv/RebaseBinFv.py|  15 +-
>  Platform/Intel/build_bios.py   |  28 +-
>  12 files changed, 143 insertions(+), 671 deletions(-)  delete mode 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/PeiCoreEntry.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/{PeiCoreEntry.asm => PeiCoreEntry.nasm} (66%)  delete mode
> 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/SecEntry.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/{SecEntry.asm => SecEntry.nasm} (72%)  delete mode 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/Stack.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformS
> ecLib/Ia32/{Stack.asm => Stack.nasm} (59%)
> 
> diff --git
> a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/PeiCoreEntry.S
> b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/PeiCoreEntry.S
> deleted file mode 100644
> index 8c8356f..000
> ---
> a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/PeiCoreEntry.S
> +++ /dev/null
> @@ -1,117 +0,0 @@
> -## @file
> -# Find and call SecStartup
> -#
> -# Copyright (c) 2017, Intel Corporation. All rights reserved. -#
> SPDX-License-Identifier: BSD-2-Clause-Patent -# -##
> -
> -ASM_GLOBAL ASM_PFX(CallPeiCoreEntryPoint)
> -ASM_PFX(CallPeiCoreEntryPoint):
> -  #
> -  # Obtain the hob list pointer
> -  #
> -  movl0x4(%esp), %eax
> -  #
> -  # Obtain the stack information
> -  #   ECX: start of range
> -  #   EDX: end of range
> -  #
> -  movl0x8(%esp), %ecx
> -  movl0xC(%esp), %edx
> -
> -  #
> -  # Platform init
> -  #
> -  pushal
> -  pushl %edx
> -  pushl %ecx
> -  pushl %eax
> -  call  ASM_PFX(PlatformInit)
> -  popl  %eax
> -  popl  %eax
> -  popl  %eax
> -  popal
> -
> -  #
> -  # Set stack top pointer
> -  #
> -  movl%edx, %esp
> -
> -  #
> -  # Push the hob list pointer
> -  #
> -  pushl   %eax
> -
> -  #
> -  # Save the value
> -  #   ECX: start of range
> -  #   EDX: end of range
> -  #
> -  movl%esp, %ebp
> -  pushl   %ecx
> -  pushl   %edx
> -
> -  #
> -  # Push processor count to stack first, then BIST status (AP then BSP)
> -  #
> -  movl$1, %eax
> -  cpuid
> -  shr $16, %ebx
> -  andl$0x00FF, %ebx
> -  cmp $1, %bl
> -  jae PushProcessorCount
> -
> -  #
> -  # Some processors report 0 logical processors.  Effectively 0 = 1.
> -  # So we fix up the processor count
> -  #
> -  inc %ebx
> -
> -PushProcessorCount:
> -  pushl   %ebx
> -
> -  #
> -  # We need to implement a long-term solution for BIST capture.  For now, we
> just copy BSP BIST
> -  # for all processor threads
> -  #
> -  xorl%ecx, %ecx
> -  movb%bl, %cl
> -PushBist:
> -  movd%mm0, %eax
> -  pushl   %eax
> -  loopPushBist
> -
> -  # Save Time-Stamp Counter
> -  movd  %mm5, %eax
> -  pushl %eax
> 

Re: [edk2-devel] [Patch] BaseTools: Remove './SecMain' from 'run' target

2019-05-22 Thread Michael D Kinney
Hi Bob,

I just noticed that there is a 2nd reference to 'SecMain'
in build.py that was missed in this patch review.

Is there a reason both were not removed?

Mike

> -Original Message-
> From: Kinney, Michael D
> Sent: Tuesday, May 21, 2019 8:45 AM
> To: Gao, Liming ; Feng, Bob C
> ; devel@edk2.groups.io; Kinney,
> Michael D 
> Subject: RE: [Patch] BaseTools: Remove './SecMain' from
> 'run' target
> 
> Reviewed-by: Michael D Kinney
> 
> 
> If we want the 'run' target to work for the
> EmulatorPkg, we
> can add a python post build script to support that.
> Please
> enter a BZ feature request.
> 
> There is an example in the following edk2-staging
> branch that
> runs QEMU for an OvmfPkg build using a 'run' target.
> 
> https://github.com/tianocore/edk2-
> staging/tree/Bug_1525_FmpDevicePkg_MultipleControllers/
> OvmfPkg
> 
> The DSC file contains a POSTBUILD statement.  There are
> two
> python scripts in this example, but could be
> consolidated to
> a single python script for the EmulatorPkg.  Run.py
> finds the
> output directory where the EmulatorPkg executable for
> each
> supported host OS can be found.
> 
> https://github.com/tianocore/edk2-
> staging/blob/Bug_1525_FmpDevicePkg_MultipleControllers/
> OvmfPkg/OvmfPkgIa32X64.dsc
> 
> https://github.com/tianocore/edk2-
> staging/blob/Bug_1525_FmpDevicePkg_MultipleControllers/
> OvmfPkg/PostBuild.py
> 
> https://github.com/tianocore/edk2-
> staging/blob/Bug_1525_FmpDevicePkg_MultipleControllers/
> OvmfPkg/Run.py
> 
> Best regards,
> 
> Mike
> 
> > -Original Message-
> > From: Gao, Liming
> > Sent: Tuesday, May 21, 2019 8:06 AM
> > To: Feng, Bob C ;
> > devel@edk2.groups.io
> > Cc: Kinney, Michael D 
> > Subject: RE: [Patch] BaseTools: Remove './SecMain'
> from
> > 'run' target
> >
> > Bob:
> >   Because NT32 has been removed, this change should
> be
> > OK. Reviewed-by: Liming Gao 
> >
> > Thanks
> > Liming
> > > -Original Message-
> > > From: Feng, Bob C
> > > Sent: Friday, May 10, 2019 3:34 PM
> > > To: Gao, Liming ;
> > devel@edk2.groups.io
> > > Cc: Kinney, Michael D 
> > > Subject: RE: [Patch] BaseTools: Remove './SecMain'
> > from 'run' target
> > >
> > > I think NT32Pkg need a POSTBUILD scripts to execute
> > its run command.
> > >
> > >
> > > -Original Message-
> > > From: Gao, Liming
> > > Sent: Friday, May 10, 2019 3:26 PM
> > > To: Feng, Bob C ;
> > devel@edk2.groups.io
> > > Cc: Kinney, Michael D 
> > > Subject: RE: [Patch] BaseTools: Remove './SecMain'
> > from 'run' target
> > >
> > > Bob:
> > >   Please make sure run command still works on NT32
> > platform.
> > >
> > > >-Original Message-
> > > >From: Feng, Bob C
> > > >Sent: Friday, May 10, 2019 2:34 PM
> > > >To: devel@edk2.groups.io
> > > >Cc: Feng, Bob C ; Gao,
> Liming
> > > >; Kinney, Michael D
> > 
> > > >Subject: [Patch] BaseTools: Remove './SecMain'
> from
> > 'run' target
> > > >
> > > >BZ:
> > https://bugzilla.tianocore.org/show_bug.cgi?id=1561
> > > >
> > > >When a target of 'run' is passed into build.py,
> > BaseTools
> > > >unconditionally attempts to execute the
> application
> > called './SecMain'
> > > >in the build output directory.
> > > >
> > > >This behavior applies to the Nt32Pkg which is
> being
> > replaced with
> > > >features in the EmulatorPkg.
> > > >
> > > >Signed-off-by: Bob Feng 
> > > >Cc: Liming Gao 
> > > >Cc: Michael D Kinney 
> > > >---
> > > > BaseTools/Source/Python/build/build.py | 4 
> > > > 1 file changed, 4 deletions(-)
> > > >
> > > >diff --git
> a/BaseTools/Source/Python/build/build.py
> > > >b/BaseTools/Source/Python/build/build.py
> > > >index 7271570d29..04f266abf5 100644
> > > >--- a/BaseTools/Source/Python/build/build.py
> > > >+++ b/BaseTools/Source/Python/build/build.py
> > > >@@ -1225,14 +1225,10 @@ class Build():
> > > >
> > > > makefile =
> > >
> >
> >GenMake.BuildFile(AutoGenObject)._FILE_NAME_[GenMake.g
> > MakeType]
> > > >
> > > > # run
> > > > if Target == 'run':
> > > >-RunDir =
> > os.path.normpath(os.path.join(AutoGenObject.BuildDir,
> > > >GlobalData.gGlobalDefines['ARCH']))
> > > >-Command = '.\SecMain'
> > > >-os.chdir(RunDir)
> > > >-LaunchCommand(Command, RunDir)
> > > > return True
> > > >
> > > > # build modules
> > > > if BuildModule:
> > > > BuildCommand = BuildCommand +
> [Target]
> > > >--
> > > >2.20.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41251): https://edk2.groups.io/g/devel/message/41251
Mute This Topic: https://groups.io/mt/31574316/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] iSCSI and iBFT

2019-05-22 Thread Michael Brown

On 22/05/2019 11:40, Tomas Pilar (tpilar) wrote:

Yeah, I just AllocateCopyPool the static struct on heap for each device. I can 
honestly see how one would assume that a protocol instance would never be 
installed on more than one handle, same as I assumed that using a statically 
allocated struct containing nothing but boilerplate info would also be fine.

The whole NII and UNDI drivers vs. SNP drivers compatibility across OEMs/IBVs and 
IHVs is a painful trash fire and this is just the last problem in a very long line of 
annoyances. 


Thanks for writing up the end result.  I can't immediately see any more 
viable way for iPXE to determine the NII corresponding to the user's 
concept of "the NIC from which I booted", but I'm open to suggestions.


Thanks again,

Michael

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41250): https://edk2.groups.io/g/devel/message/41250
Mute This Topic: https://groups.io/mt/31686860/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms] [PATCH v2 5/5] Intel/Readme.md: Updated readme with linux build instructions

2019-05-22 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Agyeman, Prince
Sent: Monday, May 20, 2019 8:08 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Agyeman, Prince 

Subject: [edk2-devel] [edk2-platforms] [PATCH v2 5/5] Intel/Readme.md: Updated 
readme with linux build instructions

From: Prince Agyeman 

Signed-off-by: Prince Agyeman 
---
 Platform/Intel/Readme.md | 42 --
 1 file changed, 24 insertions(+), 18 deletions(-)

diff --git a/Platform/Intel/Readme.md b/Platform/Intel/Readme.md index 
1da5d0a..443fb40 100644
--- a/Platform/Intel/Readme.md
+++ b/Platform/Intel/Readme.md
@@ -107,9 +107,13 @@ return back to the minimum platform caller.
 
 **Building with the python script**
 
-1. Open command window, go to the workspace directory, e.g. c:\Kabylake.
-2. Type "cd edk2-platforms\Platform\Intel -3. Type "python build_bios.py -p 
REPLACE_WITH_BOARD_NAME"
+1. Open command window, go to the workspace directory, e.g. c:\Kabylake 
+or ~/Kabylake in the case of a linux OS 2. If using a linux OS
+   * Type "cd edk2"
+   * Type "source edksetup.sh"
+   * Type "cd ../" to go back to the workspace directory 3. Type "cd 
+edk2-platforms/Platform/Intel 4. Type "python build_bios.py -p 
+REPLACE_WITH_BOARD_NAME"
 
 * build_bios.py arguments:
 
@@ -132,18 +136,19 @@ return back to the minimum platform caller.
   | |
 
 * For more information on build options
-  * ``Type "python build_bios.py -h"``
+  * Type "python build_bios.py -h"
 
 * Note
-  * ``Python 2.7.16 and Python 3.7.3 compatible``
-  * ``These python build scripts have been tested on Windows due to`` 
[cross-platform limitations](#Known-limitations)
+  * Python 2.7.16 and Python 3.7.3 compatible
+  * This python build script has been tested on Windows 10 and Ubuntu 
+ 16.04.5 LTS
+  * See [cross-platform limitations](#Known-limitations)
 
 * Configuration Files
-  * ``The edk2-platforms\Platform\Intel\build.cfg file contains the default 
settings used by build_bios.py``
-  * ``The default settings are under the DEFAULT_CONFIG section``
-  * ``Each board can have a settings file that will override the 
edk2-platforms\Platform\Intel\build.cfg settings``
-  * ``An example of a board specific settings:``
-* 
``edk2-platforms\Platform\Intel\KabylakeOpenBoardPkg\KabylakeRvp3\build_config.cfg``
+  * The edk2-platforms\Platform\Intel\build.cfg file contains the 
+ default settings used by build_bios.py
+  * The default settings are under the DEFAULT_CONFIG section
+  * Each board can have a settings file that will override the 
+ edk2-platforms\Platform\Intel\build.cfg settings
+  * An example of a board specific settings:
+* 
+ edk2-platforms\Platform\Intel\KabylakeOpenBoardPkg\KabylakeRvp3\build_
+ config.cfg
 
 * Workspace view of the build scripts
   * 
@@ -212,14 +217,13 @@ Users can also flash the UEFI firmware image to the 
highest area of the flash re
 
 ### **Known limitations**
 
-* All firmware projects can only build on Windows with the validated 
configuration below.
-  * Cross-platform build support is work-in-progress.
-
 **KabylakeOpenBoardPkg**
 1. This firmware project has only been tested on the Intel KabylakeRvp3 board.
 2. This firmware project has only been tested booting to Microsoft Windows 10 
x64 with AHCI mode and Integrated Graphic
   Device.
-3. This firmware project build has only been tested using the Microsoft Visual 
Studio 2015 compiler.
+3. The Windows build was tested on Windows 10 with Microsoft Visual Studio 
2015.
+4. The Linux build was tested on Ubuntu 16.04.5 LTS with GCC version 5.4.0.
+5. The build was tested with NASM version 2.11.08.
 
 **PurleyOpenBoardPkg**
 1. This firmware project has only been tested on the Microsoft MtOlympus board.
@@ -228,9 +232,11 @@ Users can also flash the UEFI firmware image to the 
highest area of the flash re
 
 **ClevoOpenBoardPkg**
 1. Currently, support is only being added for the N1xxWU series of boards.
-2. The firmware project build has only been tested using the Microsoft Visual 
Studio 2015 compiler.
-3. The firmware project has not been tested on an actual board, it *should 
not* be expected to boot.
-4. The firmware project applies to all Clevo supported board configurations 
but is only being tested on System 76 Galago
+2. The Windows build was tested on Windows 10 with Microsoft Visual Studio 
2015 compiler.
+3. The Linux build was tested on Ubuntu 16.04.5 LTS with GCC version 5.4.0.
+4. The build was tested with NASM version 2.11.08.
+5. The firmware project has not been tested on an actual board, it *should 
not* be expected to boot.
+6. The firmware project applies to all Clevo supported board 
+configurations but is only being tested on System 76 Galago
   Pro devices.
 
 ### **Planned Activities**
--
2.7.4





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online 

Re: [edk2-devel] [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build support

2019-05-22 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: Agyeman, Prince 
Sent: Monday, May 20, 2019 8:08 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Agyeman, Prince 
; Kubacki, Michael A ; 
Kinney, Michael D ; Desimone, Nathaniel L 
; Gao, Liming ; Sinha, 
Ankit 
Subject: [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build 
support

From: Prince Agyeman 

Fixes:
* Replacing .asm and .S with nasm in SecFspWrapperPlatformSecLib for 
cross-platform build support
* Modified RuleInclude.fdf
* Modified python files to be OS independent

Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm version 
2.11.08

Cc: Michael Kubacki 
Cc: Michael D Kinney 
Cc: Nate DeSimone 
Cc: Liming Gao 
Cc: Ankit Sinha 

Signed-off-by: Prince Agyeman 
---
 .../Ia32/PeiCoreEntry.S| 117 ---
 .../Ia32/{PeiCoreEntry.asm => PeiCoreEntry.nasm}   |  46 +--
 .../SecFspWrapperPlatformSecLib/Ia32/SecEntry.S| 342 -
 .../Ia32/{SecEntry.asm => SecEntry.nasm}   | 132 
 .../SecFspWrapperPlatformSecLib/Ia32/Stack.S   |  67 
 .../Ia32/{Stack.asm => Stack.nasm} |  39 ++-
 .../SecFspWrapperPlatformSecLib.inf|  12 +-
 .../MinPlatformPkg/Include/Fdf/RuleInclude.fdf |   6 +-
 .../Tools/Fsp/RebaseAndPatchFspBinBaseAddress.py   |   2 +-
 .../MinPlatformPkg/Tools/PatchFv/PatchBinFv.py |   8 +-
 .../MinPlatformPkg/Tools/PatchFv/RebaseBinFv.py|  15 +-
 Platform/Intel/build_bios.py   |  28 +-
 12 files changed, 143 insertions(+), 671 deletions(-)  delete mode 100644 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/PeiCoreEntry.S
 rename 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/{PeiCoreEntry.asm
 => PeiCoreEntry.nasm} (66%)  delete mode 100644 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/SecEntry.S
 rename 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/{SecEntry.asm
 => SecEntry.nasm} (72%)  delete mode 100644 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/Stack.S
 rename 
Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/{Stack.asm
 => Stack.nasm} (59%)

diff --git 
a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/PeiCoreEntry.S
 
b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/PeiCoreEntry.S
deleted file mode 100644
index 8c8356f..000
--- 
a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/PeiCoreEntry.S
+++ /dev/null
@@ -1,117 +0,0 @@
-## @file
-# Find and call SecStartup
-#
-# Copyright (c) 2017, Intel Corporation. All rights reserved. -# 
SPDX-License-Identifier: BSD-2-Clause-Patent -# -##
-
-ASM_GLOBAL ASM_PFX(CallPeiCoreEntryPoint)
-ASM_PFX(CallPeiCoreEntryPoint):
-  #
-  # Obtain the hob list pointer
-  #
-  movl0x4(%esp), %eax
-  #
-  # Obtain the stack information
-  #   ECX: start of range
-  #   EDX: end of range
-  #
-  movl0x8(%esp), %ecx
-  movl0xC(%esp), %edx
-
-  #
-  # Platform init
-  #
-  pushal
-  pushl %edx
-  pushl %ecx
-  pushl %eax
-  call  ASM_PFX(PlatformInit)
-  popl  %eax
-  popl  %eax
-  popl  %eax
-  popal
-
-  #
-  # Set stack top pointer
-  #
-  movl%edx, %esp
-
-  #
-  # Push the hob list pointer
-  #
-  pushl   %eax
-
-  #
-  # Save the value
-  #   ECX: start of range
-  #   EDX: end of range
-  #
-  movl%esp, %ebp
-  pushl   %ecx
-  pushl   %edx
-
-  #
-  # Push processor count to stack first, then BIST status (AP then BSP)
-  #
-  movl$1, %eax
-  cpuid
-  shr $16, %ebx
-  andl$0x00FF, %ebx
-  cmp $1, %bl
-  jae PushProcessorCount
-
-  #
-  # Some processors report 0 logical processors.  Effectively 0 = 1.
-  # So we fix up the processor count
-  #
-  inc %ebx
-
-PushProcessorCount:
-  pushl   %ebx
-
-  #
-  # We need to implement a long-term solution for BIST capture.  For now, we 
just copy BSP BIST
-  # for all processor threads
-  #
-  xorl%ecx, %ecx
-  movb%bl, %cl
-PushBist:
-  movd%mm0, %eax
-  pushl   %eax
-  loopPushBist
-
-  # Save Time-Stamp Counter
-  movd  %mm5, %eax
-  pushl %eax
-
-  movd  %mm6, %eax
-  pushl %eax
-
-  #
-  # Pass entry point of the PEI core
-  #
-  movl$0xFFE0, %edi
-  pushl   %ds:(%edi)
-
-  #
-  # Pass BFV into the PEI Core
-  #
-  movl$0xFFFC, %edi
-  pushl   %ds:(%edi)
-
-  #
-  # Pass stack size into the PEI Core
-  #
-  movl-4(%ebp), %ecx
-  movl-8(%ebp), %edx
-  pushl   %ecx   # RamBase
-
-  subl%ecx, %edx
-  pushl   %edx   # RamSize
-
-  #
-  # Pass Control into the PEI Core
-  #
-  call ASM_PFX(SecStartup)
diff --git 
a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatformSecLib/Ia32/PeiCoreEntry.asm
 

Re: [edk2-devel] [edk2-platforms] [PATCH v2 3/5] KabylakeOpenBoardPkg: Added GCC5 build support

2019-05-22 Thread Nate DeSimone
Reviewed-by: Nate DeSimone 

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Agyeman, Prince
Sent: Monday, May 20, 2019 8:08 PM
To: devel@edk2.groups.io
Cc: Chiu, Chasel ; Agyeman, Prince 

Subject: [edk2-devel] [edk2-platforms] [PATCH v2 3/5] KabylakeOpenBoardPkg: 
Added GCC5 build support

From: Prince Agyeman 

Fixed:
* Include file paths in dec
* Gcc build options

Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm version 
2.11.08

Signed-off-by: Prince Agyeman 
---
 .../KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildOption.dsc   | 4 +++-
 Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec| 6 +++---
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git 
a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildOption.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildOption.dsc
index 04c5786..8e885cc 100644
--- 
a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuildOption.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgBuild
+++ Option.dsc
@@ -1,7 +1,7 @@
 ## @file
 # platform build option configuration file.
 #
-# Copyright (c) 2017, Intel Corporation. All rights reserved.
+# Copyright (c) 2017 - 2019, Intel Corporation. All rights 
+reserved.
 #
 # SPDX-License-Identifier: BSD-2-Clause-Patent  # @@ -102,6 +102,7 @@ DEFINE 
DSC_PLTPKG_FEATURE_BUILD_OPTIONS = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(  # 
For IA32 Specific Build Flag  #
 GCC:   *_*_IA32_PP_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
+GCC:   *_*_IA32_CC_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) -D 
PI_SPECIFICATION_VERSION=0x00010015 -DASF_PEI -Wno-unused 
-Wl,--allow-multiple-definition
 MSFT:  *_*_IA32_ASM_FLAGS = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
 MSFT:  *_*_IA32_CC_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) 
$(OPTIMIZE_DISABLE_OPTIONS) -D PI_SPECIFICATION_VERSION=0x00010015 -DASF_PEI
 MSFT:  *_*_IA32_VFRPP_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) 
$(OPTIMIZE_DISABLE_OPTIONS)
@@ -124,6 +125,7 @@ MSFT:  *_*_IA32_ASLCC_FLAGS   = 
$(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) $(OPTIMIZE_D
 # For X64 Specific Build Flag
 #
 GCC:   *_*_X64_PP_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
+GCC:   *_*_X64_CC_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) -D 
PI_SPECIFICATION_VERSION=0x00010015 -Wno-unused -Wl,--allow-multiple-definition
 MSFT:  *_*_X64_ASM_FLAGS  = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS)
 MSFT:  *_*_X64_CC_FLAGS   = $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) 
$(OPTIMIZE_DISABLE_OPTIONS) -D PI_SPECIFICATION_VERSION=0x00010015
 MSFT:  *_*_X64_VFRPP_FLAGS= $(DSC_PLTPKG_FEATURE_BUILD_OPTIONS) 
$(OPTIMIZE_DISABLE_OPTIONS)
diff --git a/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec 
b/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
index e326598..68977d0 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
+++ b/Platform/Intel/KabylakeOpenBoardPkg/OpenBoardPkg.dec
@@ -5,7 +5,7 @@
 # INF files to generate AutoGen.c and AutoGen.h files  # for the build 
infrastructure.
 #
-# Copyright (c) 2017, Intel Corporation. All rights reserved.
+# Copyright (c) 2017 - 2019, Intel Corporation. All rights 
+reserved.
 #
 # SPDX-License-Identifier: BSD-2-Clause-Patent  # @@ -20,8 +20,8 @@ 
PACKAGE_GUID = 0A8BA6E8-C8AC-4AC1-87AC-52772FA6AE5E
 
 [Includes]
 Include
-KabylakeRvp3\Include
-Features\Tbt\Include
+KabylakeRvp3/Include
+Features/Tbt/Include
 
 [Guids]
 
--
2.7.4





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41247): https://edk2.groups.io/g/devel/message/41247
Mute This Topic: https://groups.io/mt/31693034/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build support

2019-05-22 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: Agyeman, Prince
> Sent: Monday, May 20, 2019 8:08 PM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> ; Kubacki, Michael A
> ; Kinney, Michael D
> ; Desimone, Nathaniel L
> ; Gao, Liming ;
> Sinha, Ankit 
> Subject: [edk2-platforms] [PATCH v2 1/5] MinPlatformPkg: Added GCC5 build
> support
> 
> From: Prince Agyeman 
> 
> Fixes:
> * Replacing .asm and .S with nasm in SecFspWrapperPlatformSecLib for
> cross-platform build support
> * Modified RuleInclude.fdf
> * Modified python files to be OS independent
> 
> Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm
> version 2.11.08
> 
> Cc: Michael Kubacki 
> Cc: Michael D Kinney 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> Cc: Ankit Sinha 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  .../Ia32/PeiCoreEntry.S| 117 ---
>  .../Ia32/{PeiCoreEntry.asm => PeiCoreEntry.nasm}   |  46 +--
>  .../SecFspWrapperPlatformSecLib/Ia32/SecEntry.S| 342 
> -
>  .../Ia32/{SecEntry.asm => SecEntry.nasm}   | 132 
>  .../SecFspWrapperPlatformSecLib/Ia32/Stack.S   |  67 
>  .../Ia32/{Stack.asm => Stack.nasm} |  39 ++-
>  .../SecFspWrapperPlatformSecLib.inf|  12 +-
>  .../MinPlatformPkg/Include/Fdf/RuleInclude.fdf |   6 +-
>  .../Tools/Fsp/RebaseAndPatchFspBinBaseAddress.py   |   2 +-
>  .../MinPlatformPkg/Tools/PatchFv/PatchBinFv.py |   8 +-
>  .../MinPlatformPkg/Tools/PatchFv/RebaseBinFv.py|  15 +-
>  Platform/Intel/build_bios.py   |  28 +-
>  12 files changed, 143 insertions(+), 671 deletions(-)  delete mode 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/PeiCoreEntry.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/{PeiCoreEntry.asm => PeiCoreEntry.nasm} (66%)  delete mode
> 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/SecEntry.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/{SecEntry.asm => SecEntry.nasm} (72%)  delete mode 100644
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/Stack.S
>  rename
> Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfor
> mSecLib/Ia32/{Stack.asm => Stack.nasm} (59%)
> 
> diff --git
> a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfo
> rmSecLib/Ia32/PeiCoreEntry.S
> b/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfo
> rmSecLib/Ia32/PeiCoreEntry.S
> deleted file mode 100644
> index 8c8356f..000
> ---
> a/Platform/Intel/MinPlatformPkg/FspWrapper/Library/SecFspWrapperPlatfo
> rmSecLib/Ia32/PeiCoreEntry.S
> +++ /dev/null
> @@ -1,117 +0,0 @@
> -## @file
> -# Find and call SecStartup
> -#
> -# Copyright (c) 2017, Intel Corporation. All rights reserved. -# SPDX-
> License-Identifier: BSD-2-Clause-Patent -# -##
> -
> -ASM_GLOBAL ASM_PFX(CallPeiCoreEntryPoint)
> -ASM_PFX(CallPeiCoreEntryPoint):
> -  #
> -  # Obtain the hob list pointer
> -  #
> -  movl0x4(%esp), %eax
> -  #
> -  # Obtain the stack information
> -  #   ECX: start of range
> -  #   EDX: end of range
> -  #
> -  movl0x8(%esp), %ecx
> -  movl0xC(%esp), %edx
> -
> -  #
> -  # Platform init
> -  #
> -  pushal
> -  pushl %edx
> -  pushl %ecx
> -  pushl %eax
> -  call  ASM_PFX(PlatformInit)
> -  popl  %eax
> -  popl  %eax
> -  popl  %eax
> -  popal
> -
> -  #
> -  # Set stack top pointer
> -  #
> -  movl%edx, %esp
> -
> -  #
> -  # Push the hob list pointer
> -  #
> -  pushl   %eax
> -
> -  #
> -  # Save the value
> -  #   ECX: start of range
> -  #   EDX: end of range
> -  #
> -  movl%esp, %ebp
> -  pushl   %ecx
> -  pushl   %edx
> -
> -  #
> -  # Push processor count to stack first, then BIST status (AP then BSP)
> -  #
> -  movl$1, %eax
> -  cpuid
> -  shr $16, %ebx
> -  andl$0x00FF, %ebx
> -  cmp $1, %bl
> -  jae PushProcessorCount
> -
> -  #
> -  # Some processors report 0 logical processors.  Effectively 0 = 1.
> -  # So we fix up the processor count
> -  #
> -  inc %ebx
> -
> -PushProcessorCount:
> -  pushl   %ebx
> -
> -  #
> -  # We need to implement a long-term solution for BIST capture.  For now,
> we just copy BSP BIST
> -  # for all processor threads
> -  #
> -  xorl%ecx, %ecx
> -  movb%bl, %cl
> -PushBist:
> -  movd%mm0, %eax
> -  pushl   %eax
> -  loopPushBist
> -
> -  # Save Time-Stamp Counter
> -  movd  %mm5, %eax
> -  pushl %eax
> -
> -  movd  %mm6, %eax
> -  pushl %eax
> -
> -  #
> -  # Pass entry point of the PEI core
> -  #
> -  movl$0xFFE0, %edi
> -  pushl   %ds:(%edi)
> -
> -  #
> -  # Pass BFV into the PEI Core
> -  #
> -  movl$0xFFFC, %edi
> -  pushl   %ds:(%edi)
> -
> -  #
> -  # Pass stack size into the PEI Core
> -  #
> -  movl-4(%ebp), %ecx
> -  movl

Re: [edk2-devel] [edk2-platforms] [PATCH v2 2/5] KabylakeSiliconPkg: Casting functions to EFIAPI

2019-05-22 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Agyeman, Prince
> Sent: Monday, May 20, 2019 8:08 PM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> ; Kubacki, Michael A
> ; Kinney, Michael D
> ; Desimone, Nathaniel L
> ; Gao, Liming ;
> Sinha, Ankit 
> Subject: [edk2-devel] [edk2-platforms] [PATCH v2 2/5] KabylakeSiliconPkg:
> Casting functions to EFIAPI
> 
> From: Prince Agyeman 
> 
> This fixes the calling convension issues in gcc
> 
> Gcc build was tested on Ubuntu 16.04.5 LTS with gcc version 5.4.0, nasm
> version 2.11.08
> 
> Cc: Michael Kubacki 
> Cc: Michael D Kinney 
> Cc: Nate DeSimone 
> Cc: Liming Gao 
> Cc: Ankit Sinha 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h | 3 ++-
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c | 3 ++-
>  Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h|
> 4 +++-
>  .../Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore.c|
> 4 +++-
>  4 files changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> index 44f151c..666340e 100644
> --- a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> +++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchInitSmm.h
> @@ -1,7 +1,7 @@
>  /** @file
>Header file for PCH Init SMM Handler
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -205,6 +205,7 @@ PchPcieLinkEqHandlerFunction (
> 
>  **/
>  VOID
> +EFIAPI
>  PchPcieIoTrapSmiCallback (
>IN EFI_HANDLE DispatchHandle,
>IN EFI_SMM_IO_TRAP_CONTEXT*CallbackContext,
> diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> index aed33bb..847fbfb 100644
> --- a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> +++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchInit/Smm/PchPcieSmm.c
> @@ -1,7 +1,7 @@
>  /** @file
>PCH Pcie SMM Driver Entry
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -238,6 +238,7 @@ PchPciePmIoTrapSmiCallback (
> 
>  **/
>  VOID
> +EFIAPI
>  PchPcieIoTrapSmiCallback (
>IN  EFI_HANDLEDispatchHandle,
>IN  EFI_SMM_IO_TRAP_CONTEXT*CallbackContext,
> diff --git
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> index 508832e..a9f0664 100644
> ---
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> +++
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmm.h
> @@ -1,7 +1,7 @@
>  /** @file
>Prototypes and defines for the PCH SMM Dispatcher.
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -510,6 +510,7 @@ typedef struct {
>registered and the SMI source has been 
> enabled.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL  *This,
>IN  EFI_SMM_HANDLER_ENTRY_POINT2  DispatchFunction,
> @@ -530,6 +531,7 @@ PchSmmCoreRegister (
>@retval EFI_INVALID_PARAMETER   Handle is invalid.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreUnRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL *This,
>IN  EFI_HANDLE   *DispatchHandle
> diff --git
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore
> .c
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCor
> e.c
> index 0c494bf..cb3bfba 100644
> ---
> a/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCore
> .c
> +++
> b/Silicon/Intel/KabylakeSiliconPkg/Pch/PchSmiDispatcher/Smm/PchSmmCo
> +++ re.c
> @@ -2,7 +2,7 @@
>This driver is responsible for the registration of child drivers
>and the abstraction of the PCH SMI sources.
> 
> -Copyright (c) 2017, Intel Corporation. All rights reserved.
> +Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
>  SPDX-License-Identifier: BSD-2-Clause-Patent
> 
>  **/
> @@ -325,6 +325,7 @@ SmiInputValueDuplicateCheck (
>registered and the SMI source has been 
> enabled.
>  **/
>  EFI_STATUS
> +EFIAPI
>  PchSmmCoreRegister (
>IN  PCH_SMM_GENERIC_PROTOCOL  

Re: [edk2-devel] [edk2-platforms] [PATCH v2 5/5] Intel/Readme.md: Updated readme with linux build instructions

2019-05-22 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Agyeman, Prince
> Sent: Monday, May 20, 2019 8:08 PM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel ; Agyeman, Prince
> 
> Subject: [edk2-devel] [edk2-platforms] [PATCH v2 5/5] Intel/Readme.md:
> Updated readme with linux build instructions
> 
> From: Prince Agyeman 
> 
> Signed-off-by: Prince Agyeman 
> ---
>  Platform/Intel/Readme.md | 42 --
>  1 file changed, 24 insertions(+), 18 deletions(-)
> 
> diff --git a/Platform/Intel/Readme.md b/Platform/Intel/Readme.md index
> 1da5d0a..443fb40 100644
> --- a/Platform/Intel/Readme.md
> +++ b/Platform/Intel/Readme.md
> @@ -107,9 +107,13 @@ return back to the minimum platform caller.
> 
>  **Building with the python script**
> 
> -1. Open command window, go to the workspace directory, e.g. c:\Kabylake.
> -2. Type "cd edk2-platforms\Platform\Intel -3. Type "python build_bios.py -p
> REPLACE_WITH_BOARD_NAME"
> +1. Open command window, go to the workspace directory, e.g. c:\Kabylake
> +or ~/Kabylake in the case of a linux OS 2. If using a linux OS
> +   * Type "cd edk2"
> +   * Type "source edksetup.sh"
> +   * Type "cd ../" to go back to the workspace directory 3. Type "cd
> +edk2-platforms/Platform/Intel 4. Type "python build_bios.py -p
> +REPLACE_WITH_BOARD_NAME"
> 
>  * build_bios.py arguments:
> 
> @@ -132,18 +136,19 @@ return back to the minimum platform caller.
>| |
> 
>  * For more information on build options
> -  * ``Type "python build_bios.py -h"``
> +  * Type "python build_bios.py -h"
> 
>  * Note
> -  * ``Python 2.7.16 and Python 3.7.3 compatible``
> -  * ``These python build scripts have been tested on Windows due to``
> [cross-platform limitations](#Known-limitations)
> +  * Python 2.7.16 and Python 3.7.3 compatible
> +  * This python build script has been tested on Windows 10 and Ubuntu
> + 16.04.5 LTS
> +  * See [cross-platform limitations](#Known-limitations)
> 
>  * Configuration Files
> -  * ``The edk2-platforms\Platform\Intel\build.cfg file contains the default
> settings used by build_bios.py``
> -  * ``The default settings are under the DEFAULT_CONFIG section``
> -  * ``Each board can have a settings file that will override the edk2-
> platforms\Platform\Intel\build.cfg settings``
> -  * ``An example of a board specific settings:``
> -* ``edk2-
> platforms\Platform\Intel\KabylakeOpenBoardPkg\KabylakeRvp3\build_confi
> g.cfg``
> +  * The edk2-platforms\Platform\Intel\build.cfg file contains the
> + default settings used by build_bios.py
> +  * The default settings are under the DEFAULT_CONFIG section
> +  * Each board can have a settings file that will override the
> + edk2-platforms\Platform\Intel\build.cfg settings
> +  * An example of a board specific settings:
> +*
> + edk2-
> platforms\Platform\Intel\KabylakeOpenBoardPkg\KabylakeRvp3\build_
> + config.cfg
> 
>  * Workspace view of the build scripts
>* 
> @@ -212,14 +217,13 @@ Users can also flash the UEFI firmware image to
> the highest area of the flash re
> 
>  ### **Known limitations**
> 
> -* All firmware projects can only build on Windows with the validated
> configuration below.
> -  * Cross-platform build support is work-in-progress.
> -
>  **KabylakeOpenBoardPkg**
>  1. This firmware project has only been tested on the Intel KabylakeRvp3
> board.
>  2. This firmware project has only been tested booting to Microsoft Windows
> 10 x64 with AHCI mode and Integrated Graphic
>Device.
> -3. This firmware project build has only been tested using the Microsoft
> Visual Studio 2015 compiler.
> +3. The Windows build was tested on Windows 10 with Microsoft Visual
> Studio 2015.
> +4. The Linux build was tested on Ubuntu 16.04.5 LTS with GCC version 5.4.0.
> +5. The build was tested with NASM version 2.11.08.
> 
>  **PurleyOpenBoardPkg**
>  1. This firmware project has only been tested on the Microsoft MtOlympus
> board.
> @@ -228,9 +232,11 @@ Users can also flash the UEFI firmware image to the
> highest area of the flash re
> 
>  **ClevoOpenBoardPkg**
>  1. Currently, support is only being added for the N1xxWU series of boards.
> -2. The firmware project build has only been tested using the Microsoft
> Visual Studio 2015 compiler.
> -3. The firmware project has not been tested on an actual board, it *should
> not* be expected to boot.
> -4. The firmware project applies to all Clevo supported board configurations
> but is only being tested on System 76 Galago
> +2. The Windows build was tested on Windows 10 with Microsoft Visual
> Studio 2015 compiler.
> +3. The Linux build was tested on Ubuntu 16.04.5 LTS with GCC version 5.4.0.
> +4. The build was tested with NASM version 2.11.08.
> +5. The firmware project has not been tested on an actual board, it *should
> not* be expected to boot.
> +6. The firmware project applies to all Clevo supported 

Re: [edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Laszlo Ersek
On 05/22/19 17:58, Andrew Fish via Groups.Io wrote:
> Tom,
> 
> Looks like the mailing list stripped your attachment. 

I got the attachment OK, and I also see it in both mail archives:

https://edk2.groups.io/g/devel/message/41228

ed4cfca6710b43f78ea5d6d05a87b676@ukex01.SolarFlarecom.com">http://mid.mail-archive.com/ed4cfca6710b43f78ea5d6d05a87b676@ukex01.SolarFlarecom.com

Thanks,
Laszlo

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41240): https://edk2.groups.io/g/devel/message/41240
Mute This Topic: https://groups.io/mt/31718606/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [edk2-platforms][PATCH V2] Maintainers.txt: Add maintainers

2019-05-22 Thread Nate DeSimone
Add maintainers for MinPlatformPkg, ClevoOpenBoardPkg,
and KabylakeSiliconPkg

Cc: Michael Kubacki 
Cc: Sai Chaganty 
Signed-off-by: Nate DeSimone 
---
 Maintainers.txt | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Maintainers.txt b/Maintainers.txt
index 927cd5ed93..e900523eee 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -68,10 +68,12 @@ R: Nate DeSimone 
 Platform/Intel/KabylakeOpenBoardPkg
 M: Chasel Chiu 
 M: Michael Kubacki 
+M: Nate DeSimone 
 
 Platform/Intel/MinPlatformPkg
 M: Michael Kubacki 
 M: Chasel Chiu 
+M: Nate DeSimone 
 R: Liming Gao 
 
 Platform/Intel/PurleyOpenBoardPkg
@@ -95,6 +97,7 @@ M: Yi Qian 
 Silicon/Intel/KabylakeSiliconPkg
 M: Chasel Chiu 
 M: Michael A Kubacki 
+M: Sai Chaganty 
 
 Silicon/Intel/LewisburgPkg
 M: Piwko, Maciej 
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41239): https://edk2.groups.io/g/devel/message/41239
Mute This Topic: https://groups.io/mt/31723265/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] Maintainers.txt: Add maintainer for ClevoOpenBoardPkg

2019-05-22 Thread Kubacki, Michael A
Reviewed-by: Michael Kubacki 

> -Original Message-
> From: Desimone, Nathaniel L
> Sent: Monday, May 20, 2019 11:28 AM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A 
> Subject: [PATCH] Maintainers.txt: Add maintainer for ClevoOpenBoardPkg
> 
> Signed-off-by: Nate DeSimone 
> Cc: Michael Kubacki 
> ---
>  Maintainers.txt | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Maintainers.txt b/Maintainers.txt index cf3ede7f0a..781edc079f
> 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -63,7 +63,7 @@ R: Liming Gao 
> Platform/Intel/ClevoOpenBoardPkg
>  M: Michael Kubacki 
>  M: Ankit Sinha 
> -R: Nate DeSimone 
> +M: Nate DeSimone 
> 
>  Platform/Intel/KabylakeOpenBoardPkg
>  M: Chasel Chiu 
> --
> 2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41238): https://edk2.groups.io/g/devel/message/41238
Mute This Topic: https://groups.io/mt/31688469/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Andrew Fish via Groups.Io
It should work Stephano is going to take a look. 

Thanks,

Andrew Fish

> On May 22, 2019, at 9:57 AM, Tomas Pilar (tpilar)  
> wrote:
> 
> Thanks Andrew,
> 
> I thought that groups.io is supposed to allow attachments?
> 
> Anyway snippet below:
> 
> 
> 
> 
>   Qemu Test
>   6a92c8c3-c6b4-4b57-a164-0a9917eeaf19
>   2097152
>   2097152
>   2
>   
> /machine
>   
>   
> hvm
> 
>  type='pflash'>/tmp/ovmf-test/OVMF_CODE.fd
>  template='/tmp/ovmf-test/OVMF_VARS.fd'>/tmp/ovmf-test/OVMF_VARS2.fd
>   
>   
> 
> 
>   
>   
> 
> 
> 
>   
>   preserve
>   restart
>   preserve
>   
> 
> 
>   
>   
> /usr/libexec/qemu-kvm
> 
>   
> 
> 
>   
> [ADDRESS]
>   
> 
> 
>   
>   
>   
> 
> 
>   
>   
>   
> 
> 
>   
> 
> 
>   
> 
> 
>   
>   
> 
> 
>primary='yes'/>
>   
>function='0x0'/>
> 
> 
>   /dev/urandom
>   
>function='0x0'/>
> 
>   
> 
> 
> --
> 
> On 22/05/2019 16:58, Andrew Fish via Groups.Io wrote:
>> Tom,
>> 
>> Looks like the mailing list stripped your attachment. 
>> 
>> Thanks,
>> 
>> Andrew Fish
>> 
>>> On May 22, 2019, at 4:19 AM, Tomas Pilar (tpilar) >> > wrote:
>>> 
>>> Hi Pavan,
>>>
>>> I am currently playing around with setting up a OVMF based test framework 
>>> myself. You likely need to tell qemu to use OVMF as it’s firmware. I attach 
>>> my current working libvirt XML file for creating UEFI VMs (diskless) – note 
>>> the  and the  elements within the  element.
>>>
>>> You want to add a disk sourced from the qcow image and that should work.
>>>
>>> Cheers,
>>> Tom
>>>
>>> From: devel@edk2.groups.io  
>>> mailto:devel@edk2.groups.io>> On Behalf Of Pavan 
>>> Kumar Aravapalli
>>> Sent: 22 May 2019 12:02
>>> To: Devel EDK2 mailto:devel@edk2.groups.io>>
>>> Subject: [edk2-devel] Help needed in building UEFI qcow2 images
>>>
>>> Hi, 
>>> 
>>>
>>> 
>>> [re-posting the question]
>>> 
>>>
>>> 
>>> I am looking for information/documentation which helps me in enabling UEFI 
>>> boot to the existing (KVM)VM template. I am trying for CentOS 6.5(64-bit) 
>>> no GUI 64-bit (KVM) template. 
>>> 
>>>
>>> 
>>>
>>> 
>>> I found some images available over https://www.kraxel.org/repos/images/ 
>>> 
>>>  with fedora os, but I am looking for uefi enabled Cent OS template. It 
>>> would be helpfull if any documentation or steps provided for the same.
>>> 
>>>
>>>
>>> 
>>> Regards, 
>>> 
>>> Pavan.
>>> 
>>> DISCLAIMER
>>> ==
>>> This e-mail may contain privileged and confidential information which is 
>>> the property of Accelerite, a Persistent Systems business. It is intended 
>>> only for the use of the individual or entity to which it is addressed. If 
>>> you are not the intended recipient, you are not authorized to read, retain, 
>>> copy, print, distribute or use this message. If you have received this 
>>> communication in error, please notify the sender and delete all copies of 
>>> this message. Accelerite, a Persistent Systems business does not accept any 
>>> liability for virus infected mails.
>>> 
>> 
>> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41237): https://edk2.groups.io/g/devel/message/41237
Mute This Topic: https://groups.io/mt/31718606/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [RFC][edk2-platform][Add new packages in Platform\Intel directory]

2019-05-22 Thread Oram, Isaac W
I am concerned that BoardSupportPkg is misleading.  My understanding is that 
many people are familiar with board support files, board support packages, and 
similar concepts explicitly using the words board and support.  And in my 
experience, they have always had the board specific details.  Our package does 
not, it has code supporting board specific code.

Basically, I think that this is likely to be misleading to a lot of people.  
And I don’t particularly understand that common, generic, and universal are 
common, but support is not.  I don’t really have a better suggestion, not 
having more specific details on the content handy, all names are “common”.  
Maybe we need to think more about what goes in here longer term so we have more 
coherence and thus a more specific name is possible.

Regards,
Isaac

From: devel@edk2.groups.io  On Behalf Of Kubacki, Michael 
A
Sent: Tuesday, May 21, 2019 9:17 PM
To: Gao, Liming ; devel@edk2.groups.io
Subject: Re: [edk2-devel] [RFC][edk2-platform][Add new packages in 
Platform\Intel directory]

In that case, I’d like to move the proposed name to BoardSupportPkg.

Thanks,
Michael

From: Gao, Liming
Sent: Tuesday, May 21, 2019 9:00 PM
To: Kubacki, Michael A 
mailto:michael.a.kuba...@intel.com>>; 
devel@edk2.groups.io
Subject: RE: [edk2-devel] [RFC][edk2-platform][Add new packages in 
Platform\Intel directory]

Michael:
 I am OK for both name. I think they have same meaning. To avoid the common 
word in Package name, such as Generic or Universal, BoardSupportPkg name may be 
better.

Thanks
Liming
From: Kubacki, Michael A [mailto:michael.a.kuba...@intel.com]
Sent: Monday, May 20, 2019 1:30 PM
To: Gao; Gao, Liming mailto:liming@intel.com>>; 
devel@edk2.groups.io
Subject: Re: [edk2-devel] [RFC][edk2-platform][Add new packages in 
Platform\Intel directory]


Hi Liming,

I agree with the need for both packages. We should wait at least another day 
for any additional feedback on the package name GenericBoardPkg. That name may 
give the impression the package can generically be used on various boards 
whereas the intent here is a package containing common or supporting board 
functionality. An alternative name to consider is BoardSupportPkg.

As a reminder, ensure the separation of content follows 8.1 (or update the 
document if necessary):

https://edk2-docs.gitbooks.io/edk-ii-minimum-platform-specification/8_stage_6_advanced_feature_selection/

Thanks,

Michael


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41236): https://edk2.groups.io/g/devel/message/41236
Mute This Topic: https://groups.io/mt/31629687/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Tomas Pilar (tpilar)

  
  
Thanks Andrew,
  
  I thought that groups.io is supposed to allow attachments?
  
  Anyway snippet below:
  
  
  
  
    Qemu Test
    6a92c8c3-c6b4-4b57-a164-0a9917eeaf19
    2097152
    2097152
    2
    
      /machine
    
    
      hvm
      
      /tmp/ovmf-test/OVMF_CODE.fd
      /tmp/ovmf-test/OVMF_VARS2.fd
    
    
      
      
    
    
      
      
      
    
    preserve
    restart
    preserve
    
      
      
    
    
      /usr/libexec/qemu-kvm
      
    
      
      
    
      [ADDRESS]
    
      
      
    
    
    
      
      
    
    
    
      
      
    
      
      
    
      
      
    
    
      
      
    
    
    
      
      
    /dev/urandom
    
    
      
    
  
  
--

On 22/05/2019 16:58, Andrew Fish via
  Groups.Io wrote:


  
  Tom,
  
  
  Looks like the mailing list stripped your
attachment. 
  
  
  Thanks,
  
  
  Andrew Fish

  
On May 22, 2019, at 4:19 AM, Tomas Pilar
  (tpilar) 
  wrote:


  
Hi Pavan,
 
I am currently playing around with setting
up a OVMF based test framework myself. You likely
need to tell qemu to use OVMF as it’s firmware. I
attach my current working libvirt XML file for
creating UEFI VMs (diskless) – note the
 and the  elements within
the  element.
 
You want to add a disk sourced from the
qcow image and that should work.
 
Cheers,
Tom
 

  
From: devel@edk2.groups.io  On Behalf Of Pavan
Kumar Aravapalli
Sent: 22 May
2019 12:02
To: Devel
EDK2 
Subject: [edk2-devel]
Help needed in building UEFI qcow2 images
  

 

  Hi, 
   
  [re-posting
  the question]
   
  I
  am looking for information/documentation which
  helps me in enabling UEFI boot to the existing
  (KVM)VM template. I am trying for CentOS
  6.5(64-bit) no GUI 64-bit (KVM) template. 
   
   
  I
  found some images available over https://www.kraxel.org/repos/images/ with
  fedora os, but I am looking for uefi enabled Cent
  OS template. It would be helpfull if any
  documentation or steps provided for the same.
   
   
  Regards, 
  Pavan.

DISCLAIMER
  ==
  This e-mail may contain privileged and confidential
  information which is the property of Accelerite, a
  Persistent Systems business. It is intended only for
  the use of the individual or entity to which it is
  addressed. If you are not the intended recipient, you
  are not authorized to read, retain, copy, print,
  distribute or use this message. If you have received
  this communication in error, please notify the sender
  and delete all copies of this message. Accelerite, a
  Persistent Systems business does not accept any
  liability for virus infected mails.
  
  
  


  



  


_._,_._,_

Groups.io Links:

You receive all messages sent to this group.




View/Reply Online (#41235) |





|



Mute This Topic


| New Topic





Your Subscription |
Contact Group Owner |

Unsubscribe

 [arch...@mail-archive.com]
_._,_._,_



Re: [edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Andrew Fish via Groups.Io
Tom,

Looks like the mailing list stripped your attachment. 

Thanks,

Andrew Fish

> On May 22, 2019, at 4:19 AM, Tomas Pilar (tpilar)  
> wrote:
> 
> Hi Pavan,
>
> I am currently playing around with setting up a OVMF based test framework 
> myself. You likely need to tell qemu to use OVMF as it’s firmware. I attach 
> my current working libvirt XML file for creating UEFI VMs (diskless) – note 
> the  and the  elements within the  element.
>
> You want to add a disk sourced from the qcow image and that should work.
>
> Cheers,
> Tom
>
> From: devel@edk2.groups.io  
> mailto:devel@edk2.groups.io>> On Behalf Of Pavan Kumar 
> Aravapalli
> Sent: 22 May 2019 12:02
> To: Devel EDK2 mailto:devel@edk2.groups.io>>
> Subject: [edk2-devel] Help needed in building UEFI qcow2 images
>
> Hi, 
> 
>
> 
> [re-posting the question]
> 
>
> 
> I am looking for information/documentation which helps me in enabling UEFI 
> boot to the existing (KVM)VM template. I am trying for CentOS 6.5(64-bit) no 
> GUI 64-bit (KVM) template. 
> 
>
> 
>
> 
> I found some images available over https://www.kraxel.org/repos/images/ 
> 
>  with fedora os, but I am looking for uefi enabled Cent OS template. It would 
> be helpfull if any documentation or steps provided for the same.
> 
>
>
> 
> Regards, 
> 
> Pavan.
> 
> DISCLAIMER
> ==
> This e-mail may contain privileged and confidential information which is the 
> property of Accelerite, a Persistent Systems business. It is intended only 
> for the use of the individual or entity to which it is addressed. If you are 
> not the intended recipient, you are not authorized to read, retain, copy, 
> print, distribute or use this message. If you have received this 
> communication in error, please notify the sender and delete all copies of 
> this message. Accelerite, a Persistent Systems business does not accept any 
> liability for virus infected mails.
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41234): https://edk2.groups.io/g/devel/message/41234
Mute This Topic: https://groups.io/mt/31718606/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to remove Network related modules

2019-05-22 Thread Leif Lindholm
On Wed, May 22, 2019 at 11:41:03AM +, Gao, Liming wrote:
> > -Original Message-
> > From: Laszlo Ersek [mailto:ler...@redhat.com]
> > Sent: Wednesday, May 22, 2019 5:11 PM
> > To: Gao, Liming ; Wu, Hao A ; 
> > devel@edk2.groups.io
> > Cc: leif.lindh...@linaro.org; Kinney, Michael D 
> > ; af...@apple.com
> > Subject: Re: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to 
> > remove Network related modules
> > 
> > On 05/22/19 03:50, Gao, Liming wrote:
> > > This is a bug. Because NetworkPkg dsc has included all network modules, 
> > > the ones in MdeModule are duplicated.
> > 
> > I'm not sure I'm convinced -- if this patch is not applied, what
> > precisely is the functionality that breaks? What are the symptoms?
> > 
> The problem is that NetworkPkg.dsc and MdeModulePkg.dsc both builds those 
> network drivers. 
> I am OK to get more feedback from stewards.

I think I agree with Laszlo, then.
Unless it causes issues with the generated images, the fix can wait
until after the stable tag. A very minor regression in build
performance does not to me justify added churn during freeze period.

Mike, Andrew, what's your take?

Best Regards,

Leif

> > Either way, I'll let the other stewards decide about this.
> > 
> > Thanks
> > Laszlo
> > 
> > > This change is to remove the duplicated one.
> > >
> > > Thanks
> > > Liming
> > >> -Original Message-
> > >> From: Wu, Hao A
> > >> Sent: Wednesday, May 22, 2019 9:44 AM
> > >> To: devel@edk2.groups.io; Gao, Liming 
> > >> Subject: RE: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc 
> > >> to remove Network related modules
> > >>
> > >>> -Original Message-
> > >>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> > >>> Liming Gao
> > >>> Sent: Tuesday, May 21, 2019 11:22 PM
> > >>> To: devel@edk2.groups.io
> > >>> Cc: Wu, Hao A
> > >>> Subject: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc
> > >>> to remove Network related modules
> > >>>
> > >>> Network related modules have been included in NetworkPkg.dsc.
> > >>> They can be removed from MdeModulePkg.dsc.
> > >>>
> > >>> Signed-off-by: Liming Gao 
> > >>> Cc: Hao A Wu 
> > >>> ---
> > >>>  MdeModulePkg/MdeModulePkg.dsc | 19 ---
> > >>>  1 file changed, 19 deletions(-)
> > >>>
> > >>> diff --git a/MdeModulePkg/MdeModulePkg.dsc
> > >>> b/MdeModulePkg/MdeModulePkg.dsc
> > >>> index ac7111dea1..995fd805e1 100644
> > >>> --- a/MdeModulePkg/MdeModulePkg.dsc
> > >>> +++ b/MdeModulePkg/MdeModulePkg.dsc
> > >>> @@ -63,11 +63,6 @@
> > >>>#
> > >>>UefiUsbLib|MdePkg/Library/UefiUsbLib/UefiUsbLib.inf
> > >>>UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf
> > >>> -  NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> > >>> -  IpIoLib|MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
> > >>> -  UdpIoLib|MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
> > >>> -  TcpIoLib|MdeModulePkg/Library/DxeTcpIoLib/DxeTcpIoLib.inf
> > >>> -  DpcLib|MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
> > >>>
> > >>> SecurityManagementLib|MdeModulePkg/Library/DxeSecurityManagementL
> > >>> ib/DxeSecurityManagementLib.inf
> > >>>
> > >>> TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTimerLibNullTem
> > >>> plate.inf
> > >>>
> > >>> SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.in
> > >>> f
> > >>> @@ -263,12 +258,8 @@
> > >>>
> > >>> MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllo
> > >>> cationProfileLib.inf
> > >>>
> > >>> MdeModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.i
> > >>> nf
> > >>>
> > >>> MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32Guided
> > >>> SectionExtractLib.inf
> > >>> -  MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
> > >>> -  MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
> > >>> -  MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> > >>>MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf
> > >>>MdeModulePkg/Library/DxeResetSystemLib/DxeResetSystemLib.inf
> > >>> -  MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
> > >>>
> > >>> MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protoco
> > >>> l.inf
> > >>>
> > >>> MdeModulePkg/Library/PeiCrc32GuidedSectionExtractLib/PeiCrc32GuidedS
> > >>> ectionExtractLib.inf
> > >>>MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf
> > >>> @@ -357,16 +348,6 @@
> > >>>MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
> > >>>
> > >>> MdeModulePkg/Universal/SmbiosMeasurementDxe/SmbiosMeasurement
> > >>> Dxe.inf
> > >>>
> > >>> -  MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
> > >>> -  MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
> > >>> -  MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
> > >>> -  MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
> > >>> -  MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
> > >>> -  MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
> > >>> -  

Re: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in [Sources] section of .INFs

2019-05-22 Thread Christian Rodriguez
Thanks for the feedback. I will move it forward into the next patch.

I also agree with Laszlo's comment on the first patch: " I'd request that we 
please hold this patch for now. (Comments in disagreement are welcome of 
course.) If we agree, I'd suggest marking TianoCore#1821 dependent on 
TianoCore#1089".

Both due to the soft feature freeze and the OpenSSL update.

Thanks,
Christian

>-Original Message-
>From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>Laszlo Ersek
>Sent: Wednesday, May 22, 2019 2:50 AM
>To: devel@edk2.groups.io; Lu, XiaoyuX ; Rodriguez,
>Christian 
>Cc: Wang, Jian J ; Ye, Ting ; Zhu,
>Yonghong 
>Subject: Re: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in
>[Sources] section of .INFs
>
>On 05/22/19 11:40, Xiaoyu Lu wrote:
>> Hi Christian,
>>
>> (1) We use OpenSSL configure script disabled some OpenSSL feature.
>>But I saw you include all .h files from OpenSSL(only excluded some).
>>Even some header files we don't need (In openssl/crypto/).
>>Can you rule them out?
>>I found OpenSSl use configdata.pm to store configure result.
>>
>>use configdata qw/%config/;
>>foreach my $enabledcryptomodule (@{config{"%sdirs"}})
>>}
>>
>>Is it possible? If this is difficult, then I have no problem.
>>
>> (2) see blow.
>>
>> (3) I think it's better to separate this patch into two.
>>Patch1.  process_files.pl
>>Patch2.  OpensslLib[Crypto].conf
>>
>>> -Original Message-
>>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>>> Christian Rodriguez
>>> Sent: Wednesday, May 22, 2019 5:12 AM
>>> To: devel@edk2.groups.io
>>> Cc: Wang, Jian J ; Ye, Ting
>>> ; Zhu, Yonghong 
>>> Subject: [edk2-devel] [Patch V3] OpensslLib: Missing local header
>>> files in [Sources] section of .INFs
>>>
>>> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1821
>>>
>>> In V2: Remove opensslconf.h because it is a script generated header.
>>> Update OpenSSL autogeneration script for .INFs because some OpenSSL
>>> local headers are missing from [Sources] section of OpensslLib.inf
>>> and OpensslLibCrypto.inf. Update OpensslLib.inf and
>>> OpensslLibCrypto.inf using the updated script. Enforce compilance of
>>> Edk2 INF Spec 3.9, which states, All HII Unicode format files must be
>>> listed in [Sources] section. Not functional issue, just compilance.
>>>
>>> Signed-off-by: Christian Rodriguez 
>>> Cc: Jian Wang 
>>> Cc: Ting Ye 
>>> Cc: Yonghong Zhu 
>>> ---
>>>  CryptoPkg/Library/OpensslLib/OpensslLib.inf   | 173
>>>
>+++
>>>
>+++
>>> +++
>>>  CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf | 167
>>>
>+++
>>>
>+++
>>> +
>>>  CryptoPkg/Library/OpensslLib/process_files.pl |  50
>>> --
>>>  3 files changed, 388 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/CryptoPkg/Library/OpensslLib/process_files.pl
>>> b/CryptoPkg/Library/OpensslLib/process_files.pl
>>> index f6e1f43641..9cad6d3ebd 100755
>>> --- a/CryptoPkg/Library/OpensslLib/process_files.pl
>>> +++ b/CryptoPkg/Library/OpensslLib/process_files.pl
>>> @@ -115,12 +115,18 @@ BEGIN {
>>>  # Retrieve file lists from OpenSSL configdata  #  use configdata
>>> qw/%unified_info/;
>>> +use Cwd qw(cwd getcwd);
>>> +use Cwd;
>>>
>>>  my @cryptofilelist = ();
>>>  my @sslfilelist = ();
>>> +my %includedirset = ();
>>>  foreach my $product ((@{$unified_info{libraries}},
>>>@{$unified_info{engines}})) {
>>>  foreach my $o (@{$unified_info{sources}->{$product}}) {
>>> +foreach my $inc (@{%{$unified_info{includes}}{$o}}) {
>>> +$includedirset{$inc} = 1;
>>> +}
>>>  foreach my $s (@{$unified_info{sources}->{$o}}) {
>>>  next if ($unified_info{generate}->{$s});
>>>  next if $s =~ "crypto/bio/b_print.c"; @@ -133,6 +139,46
>>> @@ foreach my $product ((@{$unified_info{libraries}},
>>>  }
>>>  }
>>>
>>> +my $fullpathcwd = getcwd . '/' . $OPENSSL_PATH . '/'; my $cwdpath =
>>> +getcwd . '/'; my @sslincludefilelist = (); my @cryptoincludefilelist
>>> += (); # Current working directory header files foreach my $file
>>> +(split (/\n/,  `find . -maxdepth 1 -name "*.h"`)) {
>>> +# Normalize path
>>> +my @filearray = split("$cwdpath", Cwd::realpath($file));
>>> +my $pathstring = $filearray[1];
>>> +my $path = '  ' . $pathstring . "\r\n";
>>> +push @cryptoincludefilelist, $path; } # Header files below
>>> +$OPENSSL_PATH foreach my $dir (keys %includedirset) {
>>
>> (2)  If run process_files.pl twice, it possible generate different *.inf
>> files(*.h files is disordered). "keys %includedirset" is 

Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-stable201905

2019-05-22 Thread Laszlo Ersek
On 05/22/19 14:09, Liming Gao wrote:

> Here, I don't want to argue whether they are feature or bug. I just
> want to share my thinking, and collect feedback, then work out the
> clear rule so that all developers can follow.

Good question. Assume we push a series that adds a feature, but then we
realize it was not complete. Do we consider the rest of the work feature
enablement, or bugfix for an earlier (already existing) feature?

Maybe it helps if we try to determine the scope of the feature
precisely, up-front, in the BZ. If a patch falls under that scope (and
under nothing else, e.g. it is not a standalone fix for another bug in
its own right), then we could consider it "feature addition /
enablement".

In that regard, the ShellPkg & EmulatorPkg patches would be feature
enablement, not bug fixes.

But I'm worried that this approach would only push the problem to a
different location, namely, to determining the scope as precisely as
possible in the TianoCore BZ. Sometimes we don't know that a module or
package is affected in the scope, until we try something in practice.

Laszlo

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41231): https://edk2.groups.io/g/devel/message/41231
Mute This Topic: https://groups.io/mt/31653140/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-stable201905

2019-05-22 Thread Liming Gao
Laszlo:
> -Original Message-
> From: Laszlo Ersek [mailto:ler...@redhat.com]
> Sent: Wednesday, May 22, 2019 5:01 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming ; Kinney, Michael D 
> ; Cetola, Stephano
> ; Andrew Fish ; Leif Lindholm 
> 
> Subject: Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for 
> edk2-stable201905
> 
> Hi,
> 
> On 05/17/19 10:56, Liming Gao wrote:
> > Hi, all
> >   
> > https://github.com/tianocore/tianocore.github.io/wiki/EDK-II-Release-Planning
> > lists edk2-stable201905 tag planning. Now, we enter into Soft Feature
> > Freeze phase. In this phase, the feature without Reviewed-by or
> > Acked-by tags will be delayed after the upcoming stable tag. The patch
> > review can continue without break. Below is edk2-stable201905 tag
> > planning.
> >
> > Date (00:00:00 UTC-8) Description
> > 2018-03-08 (12PM) Beginning of development
> > 2019-05-17 Soft Feature Freeze
> > 2019-05-24 Hard Feature Freeze
> > 2019-05-31 Release
> 
> We need to establish better enforcement for the soft feature freeze, or
> else, we need to redefine what the soft feature freeze means.
> 
> According to the current definition, and schedule, a patch that is not a
> bugfix may be committed after 2019-05-17 08:00 UTC only if it has
> received sufficient Acked-by / Reviewed-by tags on the list before the
> exact same timestamp (2019-05-17 08:00 UTC).
> 
>   
> https://github.com/lersek/edk2/wiki/SoftFeatureFreeze#what-is-the-soft-feature-freeze
> 
> > The soft feature freeze is the beginning of the stabilization phase of
> > edk2's development process. By the date of the soft feature freeze,
> > developers must have sent their patches to the mailing list *and*
> > received positive maintainer reviews (Reviewed-by or Acked-by tags).
> > This means that features, and in particular non-trivial ones, must
> > have been accepted by maintainers before the soft freeze date.
> >
> > Between the soft feature freeze and the hard feature freeze,
> > previously reviewed and unit-tested features may be applied (or
> > merged) to the master branch, for integration testing. Feature
> > addition or enablement patches posted *or* reviewed after the soft
> > feature freeze will be delayed until after the upcoming stable tag.
> 
> So let's check the recent commit history...
> 
> git log --oneline --reverse --since='2019-05-17T08:00:00+00:00'
> 
> > 8da8daafc905 ShellPkg: acpiview: Add GT Frame Number validation to GTDT 
> > parser
> 
> Reviewed on 2019-05-17, at 00:08 UTC:
> 
>   
> 3CE959C139B4C44DBEA1810E3AA6F9000B7D374D@SHSMSX101.ccr.corp.intel.com">http://mid.mail-archive.com/3CE959C139B4C44DBEA1810E3AA6F9000B7D374D@SHSMSX101.ccr.corp.intel.com
> 
> Valid commit.
> 
> 
> > 1887b995a359 ShellPkg/UefiShellAcpiViewCommandLib: Fix PPTT cache 
> > attributes validation
> 
> This patch received multiple R-b's, in time, including one from a
> designated ShellPkg Reviewer:
> 
>   
> DB6PR0802MB237582494362A29FEBE0DD3E84330@DB6PR0802MB2375.eurprd08.prod.outlook.com">http://mid.mail-archive.com/DB6PR0802MB237582494362A29FEBE0DD3E84330@DB6PR0802MB2375.eurprd08.prod.outlook.com
>   
> 3C0D5C461C9E904E8F62152F6274C0BB40BD4110@SHSMSX104.ccr.corp.intel.com">http://mid.mail-archive.com/3C0D5C461C9E904E8F62152F6274C0BB40BD4110@SHSMSX104.ccr.corp.intel.com
>   
> 3CE959C139B4C44DBEA1810E3AA6F9000B7D3832@SHSMSX101.ccr.corp.intel.com">http://mid.mail-archive.com/3CE959C139B4C44DBEA1810E3AA6F9000B7D3832@SHSMSX101.ccr.corp.intel.com
> 
> Valid commit. (This patch is a bugfix, even.)
> 
> 
> > 41ac2076a7c6 UefiCpuPkg CpuCommonFeaturesLib: Remove CPU generation check
> 
> This is an invalid commit during the soft feature freeze. The change is
> *not* a bugfix (it is a change that helps with the future use of a
> function). And sufficient review was given only *after* the deadline, at
> 13:10 UTC:
> 
>   
> 734D49CCEBEEF84792F5B80ED585239D5C1476E8@SHSMSX104.ccr.corp.intel.com">http://mid.mail-archive.com/734D49CCEBEEF84792F5B80ED585239D5C1476E8@SHSMSX104.ccr.corp.intel.com
> 

I don't see this is in edk2 feature planning. We may need to give some 
guideline to define what change is a feature or a bug.

> 
> > 59f20e8d7100 ShellPkg: Update DSC to use NetworkPkg's include fragment file
> 
> Invalid commit. This is not a bugfix but a feature patch. (The commit
> message should have referenced
> .) The one R-b that
> it received was posted *way* after the deadline, on 2019-05-20, at 00:28
> UTC:
> 
>   
> 3CE959C139B4C44DBEA1810E3AA6F9000B7D3DB1@SHSMSX101.ccr.corp.intel.com">http://mid.mail-archive.com/3CE959C139B4C44DBEA1810E3AA6F9000B7D3DB1@SHSMSX101.ccr.corp.intel.com
> 
> 
> > 48f43c2c56ee EmbeddedPkg: Update DSC to use NetworkPkg's include fragment 
> > file
> 
> Invalid commit. This is a feature patch (and it should have referenced
> ). The Reviewed-by
> was posted after the deadline, at 09:00 UTC.
> 
>   
> 

Re: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to remove Network related modules

2019-05-22 Thread Liming Gao
> -Original Message-
> From: Laszlo Ersek [mailto:ler...@redhat.com]
> Sent: Wednesday, May 22, 2019 5:11 PM
> To: Gao, Liming ; Wu, Hao A ; 
> devel@edk2.groups.io
> Cc: leif.lindh...@linaro.org; Kinney, Michael D ; 
> af...@apple.com
> Subject: Re: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to 
> remove Network related modules
> 
> On 05/22/19 03:50, Gao, Liming wrote:
> > This is a bug. Because NetworkPkg dsc has included all network modules, the 
> > ones in MdeModule are duplicated.
> 
> I'm not sure I'm convinced -- if this patch is not applied, what
> precisely is the functionality that breaks? What are the symptoms?
> 
The problem is that NetworkPkg.dsc and MdeModulePkg.dsc both builds those 
network drivers. 
I am OK to get more feedback from stewards.

> Either way, I'll let the other stewards decide about this.
> 
> Thanks
> Laszlo
> 
> > This change is to remove the duplicated one.
> >
> > Thanks
> > Liming
> >> -Original Message-
> >> From: Wu, Hao A
> >> Sent: Wednesday, May 22, 2019 9:44 AM
> >> To: devel@edk2.groups.io; Gao, Liming 
> >> Subject: RE: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to 
> >> remove Network related modules
> >>
> >>> -Original Message-
> >>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> >>> Liming Gao
> >>> Sent: Tuesday, May 21, 2019 11:22 PM
> >>> To: devel@edk2.groups.io
> >>> Cc: Wu, Hao A
> >>> Subject: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc
> >>> to remove Network related modules
> >>>
> >>> Network related modules have been included in NetworkPkg.dsc.
> >>> They can be removed from MdeModulePkg.dsc.
> >>>
> >>> Signed-off-by: Liming Gao 
> >>> Cc: Hao A Wu 
> >>> ---
> >>>  MdeModulePkg/MdeModulePkg.dsc | 19 ---
> >>>  1 file changed, 19 deletions(-)
> >>>
> >>> diff --git a/MdeModulePkg/MdeModulePkg.dsc
> >>> b/MdeModulePkg/MdeModulePkg.dsc
> >>> index ac7111dea1..995fd805e1 100644
> >>> --- a/MdeModulePkg/MdeModulePkg.dsc
> >>> +++ b/MdeModulePkg/MdeModulePkg.dsc
> >>> @@ -63,11 +63,6 @@
> >>>#
> >>>UefiUsbLib|MdePkg/Library/UefiUsbLib/UefiUsbLib.inf
> >>>UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf
> >>> -  NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> >>> -  IpIoLib|MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
> >>> -  UdpIoLib|MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
> >>> -  TcpIoLib|MdeModulePkg/Library/DxeTcpIoLib/DxeTcpIoLib.inf
> >>> -  DpcLib|MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
> >>>
> >>> SecurityManagementLib|MdeModulePkg/Library/DxeSecurityManagementL
> >>> ib/DxeSecurityManagementLib.inf
> >>>
> >>> TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTimerLibNullTem
> >>> plate.inf
> >>>
> >>> SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.in
> >>> f
> >>> @@ -263,12 +258,8 @@
> >>>
> >>> MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllo
> >>> cationProfileLib.inf
> >>>
> >>> MdeModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.i
> >>> nf
> >>>
> >>> MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32Guided
> >>> SectionExtractLib.inf
> >>> -  MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
> >>> -  MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
> >>> -  MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> >>>MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf
> >>>MdeModulePkg/Library/DxeResetSystemLib/DxeResetSystemLib.inf
> >>> -  MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
> >>>
> >>> MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protoco
> >>> l.inf
> >>>
> >>> MdeModulePkg/Library/PeiCrc32GuidedSectionExtractLib/PeiCrc32GuidedS
> >>> ectionExtractLib.inf
> >>>MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf
> >>> @@ -357,16 +348,6 @@
> >>>MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
> >>>
> >>> MdeModulePkg/Universal/SmbiosMeasurementDxe/SmbiosMeasurement
> >>> Dxe.inf
> >>>
> >>> -  MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
> >>> -  MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
> >>> -  MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
> >>> -  MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
> >>> -  MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
> >>> -  MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
> >>> -  MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
> >>> -  MdeModulePkg/Universal/Network/SnpDxe/SnpDxe.inf
> >>> -  MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
> >>> -
> >>
> >> Reviewed-by: Hao A Wu 
> >> I will let the stewards to decide whether this can be pushed at this 
> >> moment.
> >>
> >> Best Regards,
> >> Hao Wu
> >>
> >>>
> >>> MdeModulePkg/Universal/PcatSingleSegmentPciCfg2Pei/PcatSingleSegmen
> >>> tPciCfg2Pei.inf
> >>>MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
> >>>MdeModulePkg/Universal/PCD/Pei/Pcd.inf
> >>> --
> >>> 2.13.0.windows.1
> >>>
> >>>
> >>> 
> >


-=-=-=-=-=-=-=-=-=-=-=-

Re: [edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Tomas Pilar (tpilar)
Hi Pavan,

I am currently playing around with setting up a OVMF based test framework 
myself. You likely need to tell qemu to use OVMF as it's firmware. I attach my 
current working libvirt XML file for creating UEFI VMs (diskless) - note the 
 and the  elements within the  element.

You want to add a disk sourced from the qcow image and that should work.

Cheers,
Tom

From: devel@edk2.groups.io  On Behalf Of Pavan Kumar 
Aravapalli
Sent: 22 May 2019 12:02
To: Devel EDK2 
Subject: [edk2-devel] Help needed in building UEFI qcow2 images


Hi,



[re-posting the question]



I am looking for information/documentation which helps me in enabling UEFI boot 
to the existing (KVM)VM template. I am trying for CentOS 6.5(64-bit) no GUI 
64-bit (KVM) template.





I found some images available over 
https://www.kraxel.org/repos/images/
 with fedora os, but I am looking for uefi enabled Cent OS template. It would 
be helpfull if any documentation or steps provided for the same.




Regards,

Pavan.
DISCLAIMER
==
This e-mail may contain privileged and confidential information which is the 
property of Accelerite, a Persistent Systems business. It is intended only for 
the use of the individual or entity to which it is addressed. If you are not 
the intended recipient, you are not authorized to read, retain, copy, print, 
distribute or use this message. If you have received this communication in 
error, please notify the sender and delete all copies of this message. 
Accelerite, a Persistent Systems business does not accept any liability for 
virus infected mails.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41228): https://edk2.groups.io/g/devel/message/41228
Mute This Topic: https://groups.io/mt/31718606/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


  Qemu Test
  6a92c8c3-c6b4-4b57-a164-0a9917eeaf19
  2097152
  2097152
  2
  
/machine
  
  
hvm

/tmp/ovmf-test/OVMF_CODE.fd
/tmp/ovmf-test/OVMF_VARS2.fd
  
  


  
  
Skylake-Server-IBRS


  
  



  
  preserve
  restart
  preserve
  


  
  
/usr/libexec/qemu-kvm

  


  
[ADDRESS]
  


  
  
  


  
  
  


  


  


  
  


  
  
  


  /dev/urandom
  
  

  
  
+107:+107
+107:+107
  




Re: [edk2-devel] [edk2-platforms] [PATCH] Maintainers.txt: Add maintainers

2019-05-22 Thread Chiu, Chasel


Reviewed-by: Chasel Chiu 

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Nate
> DeSimone
> Sent: Wednesday, May 22, 2019 2:17 AM
> To: devel@edk2.groups.io
> Cc: Kubacki, Michael A ; Chaganty, Rangasai V
> 
> Subject: [edk2-devel] [edk2-platforms] [PATCH] Maintainers.txt: Add
> maintainers
> 
> Add maintainers for MinPlatformPkg, ClevoOpenBoardPkg, and
> KabylakeSiliconPkg
> 
> Cc: Michael Kubacki 
> Cc: Sai Chaganty 
> Signed-off-by: Nate DeSimone 
> ---
>  Maintainers.txt | 4 
>  1 file changed, 4 insertions(+)
> 
> diff --git a/Maintainers.txt b/Maintainers.txt index 927cd5ed93..2fac4a4c30
> 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -68,10 +68,12 @@ R: Nate DeSimone 
> Platform/Intel/KabylakeOpenBoardPkg
>  M: Chasel Chiu 
>  M: Michael Kubacki 
> +M: Nate DeSimone 
> 
>  Platform/Intel/MinPlatformPkg
>  M: Michael Kubacki 
>  M: Chasel Chiu 
> +M: Nate DeSimone 
>  R: Liming Gao 
> 
>  Platform/Intel/PurleyOpenBoardPkg
> @@ -95,6 +97,8 @@ M: Yi Qian 
> Silicon/Intel/KabylakeSiliconPkg
>  M: Chasel Chiu 
>  M: Michael A Kubacki 
> +M: Sai Chaganty 
> +R: Nate DeSimone 
> 
>  Silicon/Intel/LewisburgPkg
>  M: Piwko, Maciej 
> --
> 2.16.2.windows.1
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41227): https://edk2.groups.io/g/devel/message/41227
Mute This Topic: https://groups.io/mt/31699825/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] Help needed in building UEFI qcow2 images

2019-05-22 Thread Pavan Kumar Aravapalli
Hi,


[re-posting the question]


I am looking for information/documentation which helps me in enabling UEFI boot 
to the existing (KVM)VM template. I am trying for CentOS 6.5(64-bit) no GUI 
64-bit (KVM) template.



I found some images available over https://www.kraxel.org/repos/images/ with 
fedora os, but I am looking for uefi enabled Cent OS template. It would be 
helpfull if any documentation or steps provided for the same.



Regards,

Pavan.
DISCLAIMER
==
This e-mail may contain privileged and confidential information which is the 
property of Accelerite, a Persistent Systems business. It is intended only for 
the use of the individual or entity to which it is addressed. If you are not 
the intended recipient, you are not authorized to read, retain, copy, print, 
distribute or use this message. If you have received this communication in 
error, please notify the sender and delete all copies of this message. 
Accelerite, a Persistent Systems business does not accept any liability for 
virus infected mails.

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41226): https://edk2.groups.io/g/devel/message/41226
Mute This Topic: https://groups.io/mt/31718606/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] iSCSI and iBFT

2019-05-22 Thread Tomas Pilar (tpilar)
Yeah, I just AllocateCopyPool the static struct on heap for each device. I can 
honestly see how one would assume that a protocol instance would never be 
installed on more than one handle, same as I assumed that using a statically 
allocated struct containing nothing but boilerplate info would also be fine.

The whole NII and UNDI drivers vs. SNP drivers compatibility across OEMs/IBVs 
and IHVs is a painful trash fire and this is just the last problem in a very 
long line of annoyances. 

On 22/05/2019 11:19, Laszlo Ersek wrote:
> On 05/22/19 11:55, Tomas Pilar wrote:
>> iPXE identifies the device it was pxe booted from by searching parents of 
>> the LoadedImage which support SNP and NII and uses the address of the 
>> installed NII and SNP as a discriminant to see if a device is in fact the 
>> one it was pxe booted from. This convoluted process is done to shoehorn 
>> chainload drivers into the ipxe driver api.
>>
>> Then it will chainload NII or SNP drivers on all devices if they pass the 
>> above check. My driver used a global static NII struct and installed that as 
>> NII on all ports so ipxe then tried to bind its NIIONLY driver on all ports 
>> on the adapter, not just the one it was pxebooted with. Thus it kicked off 
>> the network stack including the iSCSI connection on the second port even 
>> though it was pxe booted into using the first port.
>>
>> Ugh.
> Thanks for the description!
>
> What is the solution to the problem? Per-port NII structs? (I don't have
> any experience with EFI_NETWORK_INTERFACE_IDENTIFIER_PROTOCOL.)
>
> Thanks
> Laszlo
>
>
>
>> -Original Message-
>> From: devel@edk2.groups.io  On Behalf Of Laszlo Ersek
>> Sent: 21 May 2019 20:48
>> To: Devel EDK2 ; Tomas Pilar 
>> Subject: Re: [edk2-devel] iSCSI and iBFT
>>
>> On 05/21/19 16:54, Tomas Pilar (tpilar) wrote:
>>> I am going to commit the cardinal sin of online dev support.
>> heh :)
>>
>>> 'Never mind, found the problem'
>> What was it?
>>
>> I didn't ignore your original email -- I looked at iPXE briefly, but 
>> couldn't blame anything at once, and then I quickly ran out of steam.
>> There wasn't anything I could have added to the thread.
>>
>> Thanks,
>> Laszlo
>>
>>> From: Tomas Pilar
>>> Sent: 20 May 2019 16:57
>>> To: 'devel@edk2.groups.io' 
>>> Subject: iSCSI and iBFT
>>>
>>> Hi,
>>>
>>> I have a bit of an esoteric problem. When I configure the software iscsi 
>>> intiator that is part of EDK2 platform network stack, the platform network 
>>> stack with install iBFT table into the ACPI tables so that the 
>>> configuration can be picked up by further boot loaders and the OS. So far 
>>> so good.
>>>
>>> Problem: When I PXE boot into iPXE using my adapter, exit back into boot 
>>> manager, the iBFT has disappeared. Alternatively, if I use iPXE to then 
>>> boot WDS, the software initiator in WinPE won't find the iBFT table and 
>>> therefore won't hook the network drive.
>>>
>>> Observations:
>>> * When I boot into UEFI shell on disk and exit back into boot manager, the 
>>> iBFT is preserved.
>>>
>>> * When I PXE boot into UEFI shell and exit, the iBFT is preserved.
>>>
>>> * When I boot into iPXE on disk and exit, the iBFT is preserved.
>>>
>>> * When I use a different adapter (Intel) to pxe boot into iBFT and exit 
>>> back to boot manager, the iBFT has moved from the penultimate position to 
>>> the last position in the ACPI tables. Almost as if something uninstalled 
>>> the iBFT and reinstalled it.
>>>
>>> Any ideas?
>>>
>>> Cheers
>>> Tom
>>>
>>>
>>>
>>>
>>
>> 
>>


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41225): https://edk2.groups.io/g/devel/message/41225
Mute This Topic: https://groups.io/mt/31686860/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH V2] UefiCpuPkg CpuCommFeaturesLib: Fix ASSERT if LMCE is supported

2019-05-22 Thread Laszlo Ersek
On 05/22/19 12:17, Zeng, Star wrote:
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1829
> 
> There will be ASSERT if LMCE is supported as below.
> DXE_ASSERT!: [CpuFeaturesDxe]
>   XXX\UefiCpuPkg\Library\CpuCommonFeaturesLib\MachineCheck.c (342):
> ConfigData != ((void *) 0)
> 
> The code should get Config Data and FeatureControlGetConfigData
> could be used.
> 
> This issue is there since the code was added at the commit below.
> 
> Revision: 3d6275c1137c9633ce24e31522b71105367bd6a0
> Date: 2017/8/4 8:46:41
> UefiCpuPkg CpuCommonFeaturesLib: Enable LMCE feature.
> 
> The commits below are also related to move the code.
> 
> Revision: 023387144299741d727521b425ef443438aecc1f
> Date: 2017/9/1 10:12:38
> UefiCpuPkg/Lmce.c Remove useless file.
> 
> Revision: 306a5bcc6b0170d28b0db10bd359817bb4b1db9f
> Date: 2017/8/17 11:40:38
> UefiCpuPkg/CpuCommonFeaturesLib: Merge machine check code to same file.
> 
> So, the code should not be tested at all on a platform
> that supports LMCE.
> 
> BTW: A typo in LmceInitialize is also fixed.
> The typo is introduced by the commit below.
> 
> Revision: d28daaddb3e732468e930a809d3d3943a5de9558
> Date: 2018/10/17 9:24:05
> UefiCpuPkg/CpuCommonFeaturesLib: Register MSR base on scope Info.
> 
> Cc: Laszlo Ersek 
> Cc: Eric Dong 
> Cc: Ray Ni 
> Cc: Chandana Kumar 
> Cc: Kevin Li 
> Signed-off-by: Star Zeng 
> 
> Notes:
> v2: Based on Laszlo's great feedback.
> - Update Ray's name and email address to match Maintainers.txt.
> - Remove "Change-Id" line that was added unintended.
> - Add more code history.
> 
> ---

[*]

>  UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c | 2 +-
>  UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)

Thanks for the update. Just one more quick note:

- if you want to include the v2 changes in the commit message, then
please describe them above your Signed-off-by (in the normal commit
message body).

- If you don't want the v2 notes to be present in the final commit
message, then please add them between the "---" mark, and the diffstat.
I marked the location above with [*]. Then "git am" will automatically
ignore the notes.

No need to resubmit now, it's just a hint for the future.

Thanks
Laszlo

> diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c 
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> index 738b57dc87f9..9ddc6ce9d476 100644
> --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> @@ -214,7 +214,7 @@ CpuCommonFeaturesLibConstructor (
>if (IsCpuFeatureSupported (CPU_FEATURE_LMCE)) {
>  Status = RegisterCpuFeature (
> "LMCE",
> -   NULL,
> +   FeatureControlGetConfigData,
> LmceSupport,
> LmceInitialize,
> CPU_FEATURE_LMCE,
> diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c 
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> index 9ee559130080..2528e0044ecb 100644
> --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> @@ -322,7 +322,7 @@ LmceInitialize (
>MSR_IA32_FEATURE_CONTROL_REGISTER*MsrRegister;
>  
>//
> -  // The scope of FastStrings bit in the MSR_IA32_MISC_ENABLE is core for 
> below processor type, only program
> +  // The scope of LcmeOn bit in the MSR_IA32_MISC_ENABLE is core for below 
> processor type, only program
>// MSR_IA32_MISC_ENABLE for thread 0 in each core.
>//
>if (IS_SILVERMONT_PROCESSOR (CpuInfo->DisplayFamily, 
> CpuInfo->DisplayModel) ||
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41224): https://edk2.groups.io/g/devel/message/41224
Mute This Topic: https://groups.io/mt/31718348/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] iSCSI and iBFT

2019-05-22 Thread Laszlo Ersek
On 05/22/19 11:55, Tomas Pilar wrote:
> iPXE identifies the device it was pxe booted from by searching parents of the 
> LoadedImage which support SNP and NII and uses the address of the installed 
> NII and SNP as a discriminant to see if a device is in fact the one it was 
> pxe booted from. This convoluted process is done to shoehorn chainload 
> drivers into the ipxe driver api.
> 
> Then it will chainload NII or SNP drivers on all devices if they pass the 
> above check. My driver used a global static NII struct and installed that as 
> NII on all ports so ipxe then tried to bind its NIIONLY driver on all ports 
> on the adapter, not just the one it was pxebooted with. Thus it kicked off 
> the network stack including the iSCSI connection on the second port even 
> though it was pxe booted into using the first port.
> 
> Ugh.

Thanks for the description!

What is the solution to the problem? Per-port NII structs? (I don't have
any experience with EFI_NETWORK_INTERFACE_IDENTIFIER_PROTOCOL.)

Thanks
Laszlo



> -Original Message-
> From: devel@edk2.groups.io  On Behalf Of Laszlo Ersek
> Sent: 21 May 2019 20:48
> To: Devel EDK2 ; Tomas Pilar 
> Subject: Re: [edk2-devel] iSCSI and iBFT
> 
> On 05/21/19 16:54, Tomas Pilar (tpilar) wrote:
>> I am going to commit the cardinal sin of online dev support.
> 
> heh :)
> 
>> 'Never mind, found the problem'
> 
> What was it?
> 
> I didn't ignore your original email -- I looked at iPXE briefly, but couldn't 
> blame anything at once, and then I quickly ran out of steam.
> There wasn't anything I could have added to the thread.
> 
> Thanks,
> Laszlo
> 
>> From: Tomas Pilar
>> Sent: 20 May 2019 16:57
>> To: 'devel@edk2.groups.io' 
>> Subject: iSCSI and iBFT
>>
>> Hi,
>>
>> I have a bit of an esoteric problem. When I configure the software iscsi 
>> intiator that is part of EDK2 platform network stack, the platform network 
>> stack with install iBFT table into the ACPI tables so that the configuration 
>> can be picked up by further boot loaders and the OS. So far so good.
>>
>> Problem: When I PXE boot into iPXE using my adapter, exit back into boot 
>> manager, the iBFT has disappeared. Alternatively, if I use iPXE to then boot 
>> WDS, the software initiator in WinPE won't find the iBFT table and therefore 
>> won't hook the network drive.
>>
>> Observations:
>> * When I boot into UEFI shell on disk and exit back into boot manager, the 
>> iBFT is preserved.
>>
>> * When I PXE boot into UEFI shell and exit, the iBFT is preserved.
>>
>> * When I boot into iPXE on disk and exit, the iBFT is preserved.
>>
>> * When I use a different adapter (Intel) to pxe boot into iBFT and exit back 
>> to boot manager, the iBFT has moved from the penultimate position to the 
>> last position in the ACPI tables. Almost as if something uninstalled the 
>> iBFT and reinstalled it.
>>
>> Any ideas?
>>
>> Cheers
>> Tom
>>
>>
>>
>>
> 
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41223): https://edk2.groups.io/g/devel/message/41223
Mute This Topic: https://groups.io/mt/31686860/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH V2] UefiCpuPkg CpuCommFeaturesLib: Fix ASSERT if LMCE is supported

2019-05-22 Thread Zeng, Star
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1829

There will be ASSERT if LMCE is supported as below.
DXE_ASSERT!: [CpuFeaturesDxe]
  XXX\UefiCpuPkg\Library\CpuCommonFeaturesLib\MachineCheck.c (342):
ConfigData != ((void *) 0)

The code should get Config Data and FeatureControlGetConfigData
could be used.

This issue is there since the code was added at the commit below.

Revision: 3d6275c1137c9633ce24e31522b71105367bd6a0
Date: 2017/8/4 8:46:41
UefiCpuPkg CpuCommonFeaturesLib: Enable LMCE feature.

The commits below are also related to move the code.

Revision: 023387144299741d727521b425ef443438aecc1f
Date: 2017/9/1 10:12:38
UefiCpuPkg/Lmce.c Remove useless file.

Revision: 306a5bcc6b0170d28b0db10bd359817bb4b1db9f
Date: 2017/8/17 11:40:38
UefiCpuPkg/CpuCommonFeaturesLib: Merge machine check code to same file.

So, the code should not be tested at all on a platform
that supports LMCE.

BTW: A typo in LmceInitialize is also fixed.
The typo is introduced by the commit below.

Revision: d28daaddb3e732468e930a809d3d3943a5de9558
Date: 2018/10/17 9:24:05
UefiCpuPkg/CpuCommonFeaturesLib: Register MSR base on scope Info.

Cc: Laszlo Ersek 
Cc: Eric Dong 
Cc: Ray Ni 
Cc: Chandana Kumar 
Cc: Kevin Li 
Signed-off-by: Star Zeng 

Notes:
v2: Based on Laszlo's great feedback.
- Update Ray's name and email address to match Maintainers.txt.
- Remove "Change-Id" line that was added unintended.
- Add more code history.

---
 UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c | 2 +-
 UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c 
b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
index 738b57dc87f9..9ddc6ce9d476 100644
--- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
+++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
@@ -214,7 +214,7 @@ CpuCommonFeaturesLibConstructor (
   if (IsCpuFeatureSupported (CPU_FEATURE_LMCE)) {
 Status = RegisterCpuFeature (
"LMCE",
-   NULL,
+   FeatureControlGetConfigData,
LmceSupport,
LmceInitialize,
CPU_FEATURE_LMCE,
diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c 
b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
index 9ee559130080..2528e0044ecb 100644
--- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
+++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
@@ -322,7 +322,7 @@ LmceInitialize (
   MSR_IA32_FEATURE_CONTROL_REGISTER*MsrRegister;
 
   //
-  // The scope of FastStrings bit in the MSR_IA32_MISC_ENABLE is core for 
below processor type, only program
+  // The scope of LcmeOn bit in the MSR_IA32_MISC_ENABLE is core for below 
processor type, only program
   // MSR_IA32_MISC_ENABLE for thread 0 in each core.
   //
   if (IS_SILVERMONT_PROCESSOR (CpuInfo->DisplayFamily, CpuInfo->DisplayModel) 
||
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41222): https://edk2.groups.io/g/devel/message/41222
Mute This Topic: https://groups.io/mt/31718348/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] iSCSI and iBFT

2019-05-22 Thread Tomas Pilar (tpilar)
iPXE identifies the device it was pxe booted from by searching parents of the 
LoadedImage which support SNP and NII and uses the address of the installed NII 
and SNP as a discriminant to see if a device is in fact the one it was pxe 
booted from. This convoluted process is done to shoehorn chainload drivers into 
the ipxe driver api.

Then it will chainload NII or SNP drivers on all devices if they pass the above 
check. My driver used a global static NII struct and installed that as NII on 
all ports so ipxe then tried to bind its NIIONLY driver on all ports on the 
adapter, not just the one it was pxebooted with. Thus it kicked off the network 
stack including the iSCSI connection on the second port even though it was pxe 
booted into using the first port.

Ugh.

-Original Message-
From: devel@edk2.groups.io  On Behalf Of Laszlo Ersek
Sent: 21 May 2019 20:48
To: Devel EDK2 ; Tomas Pilar 
Subject: Re: [edk2-devel] iSCSI and iBFT

On 05/21/19 16:54, Tomas Pilar (tpilar) wrote:
> I am going to commit the cardinal sin of online dev support.

heh :)

> 'Never mind, found the problem'

What was it?

I didn't ignore your original email -- I looked at iPXE briefly, but couldn't 
blame anything at once, and then I quickly ran out of steam.
There wasn't anything I could have added to the thread.

Thanks,
Laszlo

> From: Tomas Pilar
> Sent: 20 May 2019 16:57
> To: 'devel@edk2.groups.io' 
> Subject: iSCSI and iBFT
> 
> Hi,
> 
> I have a bit of an esoteric problem. When I configure the software iscsi 
> intiator that is part of EDK2 platform network stack, the platform network 
> stack with install iBFT table into the ACPI tables so that the configuration 
> can be picked up by further boot loaders and the OS. So far so good.
> 
> Problem: When I PXE boot into iPXE using my adapter, exit back into boot 
> manager, the iBFT has disappeared. Alternatively, if I use iPXE to then boot 
> WDS, the software initiator in WinPE won't find the iBFT table and therefore 
> won't hook the network drive.
> 
> Observations:
> * When I boot into UEFI shell on disk and exit back into boot manager, the 
> iBFT is preserved.
> 
> * When I PXE boot into UEFI shell and exit, the iBFT is preserved.
> 
> * When I boot into iPXE on disk and exit, the iBFT is preserved.
> 
> * When I use a different adapter (Intel) to pxe boot into iBFT and exit back 
> to boot manager, the iBFT has moved from the penultimate position to the last 
> position in the ACPI tables. Almost as if something uninstalled the iBFT and 
> reinstalled it.
> 
> Any ideas?
> 
> Cheers
> Tom
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41221): https://edk2.groups.io/g/devel/message/41221
Mute This Topic: https://groups.io/mt/31686860/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in [Sources] section of .INFs

2019-05-22 Thread Laszlo Ersek
On 05/22/19 11:40, Xiaoyu Lu wrote:
> Hi Christian, 
> 
> (1) We use OpenSSL configure script disabled some OpenSSL feature.
>But I saw you include all .h files from OpenSSL(only excluded some). 
>Even some header files we don't need (In openssl/crypto/). 
>Can you rule them out? 
>I found OpenSSl use configdata.pm to store configure result.
> 
>use configdata qw/%config/;
>foreach my $enabledcryptomodule (@{config{"%sdirs"}}) 
>}
> 
>Is it possible? If this is difficult, then I have no problem.
> 
> (2) see blow.
> 
> (3) I think it's better to separate this patch into two.
>Patch1.  process_files.pl
>Patch2.  OpensslLib[Crypto].conf
> 
>> -Original Message-
>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>> Christian Rodriguez
>> Sent: Wednesday, May 22, 2019 5:12 AM
>> To: devel@edk2.groups.io
>> Cc: Wang, Jian J ; Ye, Ting ; Zhu,
>> Yonghong 
>> Subject: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in
>> [Sources] section of .INFs
>>
>> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1821
>>
>> In V2: Remove opensslconf.h because it is a script generated header.
>> Update OpenSSL autogeneration script for .INFs because some
>> OpenSSL local headers are missing from [Sources] section of
>> OpensslLib.inf and OpensslLibCrypto.inf. Update OpensslLib.inf and
>> OpensslLibCrypto.inf using the updated script. Enforce compilance
>> of Edk2 INF Spec 3.9, which states, All HII Unicode format files
>> must be listed in [Sources] section. Not functional issue, just compilance.
>>
>> Signed-off-by: Christian Rodriguez 
>> Cc: Jian Wang 
>> Cc: Ting Ye 
>> Cc: Yonghong Zhu 
>> ---
>>  CryptoPkg/Library/OpensslLib/OpensslLib.inf   | 173
>> +++
>> +++
>> +++
>>  CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf | 167
>> +++
>> +++
>> +
>>  CryptoPkg/Library/OpensslLib/process_files.pl |  50
>> --
>>  3 files changed, 388 insertions(+), 2 deletions(-)
>>
>> diff --git a/CryptoPkg/Library/OpensslLib/process_files.pl
>> b/CryptoPkg/Library/OpensslLib/process_files.pl
>> index f6e1f43641..9cad6d3ebd 100755
>> --- a/CryptoPkg/Library/OpensslLib/process_files.pl
>> +++ b/CryptoPkg/Library/OpensslLib/process_files.pl
>> @@ -115,12 +115,18 @@ BEGIN {
>>  # Retrieve file lists from OpenSSL configdata
>>  #
>>  use configdata qw/%unified_info/;
>> +use Cwd qw(cwd getcwd);
>> +use Cwd;
>>
>>  my @cryptofilelist = ();
>>  my @sslfilelist = ();
>> +my %includedirset = ();
>>  foreach my $product ((@{$unified_info{libraries}},
>>@{$unified_info{engines}})) {
>>  foreach my $o (@{$unified_info{sources}->{$product}}) {
>> +foreach my $inc (@{%{$unified_info{includes}}{$o}}) {
>> +$includedirset{$inc} = 1;
>> +}
>>  foreach my $s (@{$unified_info{sources}->{$o}}) {
>>  next if ($unified_info{generate}->{$s});
>>  next if $s =~ "crypto/bio/b_print.c";
>> @@ -133,6 +139,46 @@ foreach my $product ((@{$unified_info{libraries}},
>>  }
>>  }
>>
>> +my $fullpathcwd = getcwd . '/' . $OPENSSL_PATH . '/';
>> +my $cwdpath = getcwd . '/';
>> +my @sslincludefilelist = ();
>> +my @cryptoincludefilelist = ();
>> +# Current working directory header files
>> +foreach my $file (split (/\n/,  `find . -maxdepth 1 -name "*.h"`)) {
>> +# Normalize path
>> +my @filearray = split("$cwdpath", Cwd::realpath($file));
>> +my $pathstring = $filearray[1];
>> +my $path = '  ' . $pathstring . "\r\n";
>> +push @cryptoincludefilelist, $path;
>> +}
>> +# Header files below $OPENSSL_PATH
>> +foreach my $dir (keys %includedirset) {
> 
> (2)  If run process_files.pl twice, it possible generate different *.inf 
> files(*.h files is disordered). "keys %includedirset" is disordered.
> I don't know whether this is a problem.

Sounds like a good point to me -- in particular if the current file list
generation for the INF files is "stable", then it should stay so even if
we generate more files for those sources sections.

Thanks,
Laszlo

> 
>> +foreach my $file (split (/\n/,  `find $OPENSSL_PATH/$dir/ -name
>> "*.h"`)) {
>> +# Normalize path
>> +my @filearray = split("$fullpathcwd", Cwd::realpath($file));
>> +my $pathstring = $filearray[1];
>> +my $path = '  $(OPENSSL_PATH)/' . $pathstring . "\r\n";
>> +# Don't reuse duplicates
>> +next if ( $path ~~ @cryptoincludefilelist );
>> +next if ( $path ~~ @sslincludefilelist );
>> +# Ignore these types
>> +next if ( $path =~ "test" );
>> +next if ( $path =~ "apps" );

Re: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in [Sources] section of .INFs

2019-05-22 Thread Xiaoyu Lu
Hi Christian, 

(1) We use OpenSSL configure script disabled some OpenSSL feature.
   But I saw you include all .h files from OpenSSL(only excluded some). 
   Even some header files we don't need (In openssl/crypto/). 
   Can you rule them out? 
   I found OpenSSl use configdata.pm to store configure result.

   use configdata qw/%config/;
   foreach my $enabledcryptomodule (@{config{"%sdirs"}}) 
   }

   Is it possible? If this is difficult, then I have no problem.

(2) see blow.

(3) I think it's better to separate this patch into two.
   Patch1.  process_files.pl
   Patch2.  OpensslLib[Crypto].conf

> -Original Message-
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Christian Rodriguez
> Sent: Wednesday, May 22, 2019 5:12 AM
> To: devel@edk2.groups.io
> Cc: Wang, Jian J ; Ye, Ting ; Zhu,
> Yonghong 
> Subject: [edk2-devel] [Patch V3] OpensslLib: Missing local header files in
> [Sources] section of .INFs
> 
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1821
> 
> In V2: Remove opensslconf.h because it is a script generated header.
> Update OpenSSL autogeneration script for .INFs because some
> OpenSSL local headers are missing from [Sources] section of
> OpensslLib.inf and OpensslLibCrypto.inf. Update OpensslLib.inf and
> OpensslLibCrypto.inf using the updated script. Enforce compilance
> of Edk2 INF Spec 3.9, which states, All HII Unicode format files
> must be listed in [Sources] section. Not functional issue, just compilance.
> 
> Signed-off-by: Christian Rodriguez 
> Cc: Jian Wang 
> Cc: Ting Ye 
> Cc: Yonghong Zhu 
> ---
>  CryptoPkg/Library/OpensslLib/OpensslLib.inf   | 173
> +++
> +++
> +++
>  CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf | 167
> +++
> +++
> +
>  CryptoPkg/Library/OpensslLib/process_files.pl |  50
> --
>  3 files changed, 388 insertions(+), 2 deletions(-)
> 
> diff --git a/CryptoPkg/Library/OpensslLib/process_files.pl
> b/CryptoPkg/Library/OpensslLib/process_files.pl
> index f6e1f43641..9cad6d3ebd 100755
> --- a/CryptoPkg/Library/OpensslLib/process_files.pl
> +++ b/CryptoPkg/Library/OpensslLib/process_files.pl
> @@ -115,12 +115,18 @@ BEGIN {
>  # Retrieve file lists from OpenSSL configdata
>  #
>  use configdata qw/%unified_info/;
> +use Cwd qw(cwd getcwd);
> +use Cwd;
> 
>  my @cryptofilelist = ();
>  my @sslfilelist = ();
> +my %includedirset = ();
>  foreach my $product ((@{$unified_info{libraries}},
>@{$unified_info{engines}})) {
>  foreach my $o (@{$unified_info{sources}->{$product}}) {
> +foreach my $inc (@{%{$unified_info{includes}}{$o}}) {
> +$includedirset{$inc} = 1;
> +}
>  foreach my $s (@{$unified_info{sources}->{$o}}) {
>  next if ($unified_info{generate}->{$s});
>  next if $s =~ "crypto/bio/b_print.c";
> @@ -133,6 +139,46 @@ foreach my $product ((@{$unified_info{libraries}},
>  }
>  }
> 
> +my $fullpathcwd = getcwd . '/' . $OPENSSL_PATH . '/';
> +my $cwdpath = getcwd . '/';
> +my @sslincludefilelist = ();
> +my @cryptoincludefilelist = ();
> +# Current working directory header files
> +foreach my $file (split (/\n/,  `find . -maxdepth 1 -name "*.h"`)) {
> +# Normalize path
> +my @filearray = split("$cwdpath", Cwd::realpath($file));
> +my $pathstring = $filearray[1];
> +my $path = '  ' . $pathstring . "\r\n";
> +push @cryptoincludefilelist, $path;
> +}
> +# Header files below $OPENSSL_PATH
> +foreach my $dir (keys %includedirset) {

(2)  If run process_files.pl twice, it possible generate different *.inf 
files(*.h files is disordered). "keys %includedirset" is disordered.
I don't know whether this is a problem.

> +foreach my $file (split (/\n/,  `find $OPENSSL_PATH/$dir/ -name
> "*.h"`)) {
> +# Normalize path
> +my @filearray = split("$fullpathcwd", Cwd::realpath($file));
> +my $pathstring = $filearray[1];
> +my $path = '  $(OPENSSL_PATH)/' . $pathstring . "\r\n";
> +# Don't reuse duplicates
> +next if ( $path ~~ @cryptoincludefilelist );
> +next if ( $path ~~ @sslincludefilelist );
> +# Ignore these types
> +next if ( $path =~ "test" );
> +next if ( $path =~ "apps" );
> +next if ( $path =~ "engines" );
> +next if ( $path =~ "fuzz" );
> +next if ( $path =~ "os-dep" );
> +next if ( $path =~ "e_os.h" );
> +next if ( $path =~ "opensslconf.h");
> +# Seperate Ssl only headers
> +if ( $path =~ "/ssl/" ) {
> +push @sslincludefilelist, $path;
> +next;
> +}
> +

Re: [edk2-devel] [edk2-platforms] [PATCH] Maintainers.txt: Add maintainers

2019-05-22 Thread Chaganty, Rangasai V
Reviewed-by: Sai Chaganty  

-Original Message-
From: Desimone, Nathaniel L 
Sent: Tuesday, May 21, 2019 11:17 AM
To: devel@edk2.groups.io
Cc: Kubacki, Michael A ; Chaganty, Rangasai V 

Subject: [edk2-platforms] [PATCH] Maintainers.txt: Add maintainers

Add maintainers for MinPlatformPkg, ClevoOpenBoardPkg, and KabylakeSiliconPkg

Cc: Michael Kubacki 
Cc: Sai Chaganty 
Signed-off-by: Nate DeSimone 
---
 Maintainers.txt | 4 
 1 file changed, 4 insertions(+)

diff --git a/Maintainers.txt b/Maintainers.txt index 927cd5ed93..2fac4a4c30 
100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -68,10 +68,12 @@ R: Nate DeSimone   
Platform/Intel/KabylakeOpenBoardPkg
 M: Chasel Chiu 
 M: Michael Kubacki 
+M: Nate DeSimone 
 
 Platform/Intel/MinPlatformPkg
 M: Michael Kubacki 
 M: Chasel Chiu 
+M: Nate DeSimone 
 R: Liming Gao 
 
 Platform/Intel/PurleyOpenBoardPkg
@@ -95,6 +97,8 @@ M: Yi Qian   
Silicon/Intel/KabylakeSiliconPkg
 M: Chasel Chiu 
 M: Michael A Kubacki 
+M: Sai Chaganty 
+R: Nate DeSimone 
 
 Silicon/Intel/LewisburgPkg
 M: Piwko, Maciej 
--
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41217): https://edk2.groups.io/g/devel/message/41217
Mute This Topic: https://groups.io/mt/31699825/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [RFC] Proposal to move IntelSiliconPkg from edk2 repo to edk2-platforms repo

2019-05-22 Thread Chaganty, Rangasai V
Hello Everyone,
As we are noticing, there are some activities in progress to reduce edk2 repo.

I would like to propose to move IntelSiliconPkg from edk2 repo to 
edk2-platforms repo.
There is no dependency on this package from any other module in edk2 repo so it 
should be safe to move to edk2-platforms repo.

Regards,
Sai


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41215): https://edk2.groups.io/g/devel/message/41215
Mute This Topic: https://groups.io/mt/31718107/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Enable measured boot with SM3 digest algorithm 0/4]

2019-05-22 Thread Desai, Imran
Hello Jiewen,

I tested SM3 PCR extensions on the OvmfPkg using swTPM (and TPM2 simulator).
The validation was done comparing PCR extensions from the TCG2 EventLog and SM3 
PCR Bank data from the simulator at every extension.
Additionally each SM3 extension and resulting values were compared and 
contrasted against OpenSSL_1_1_1b on a linux dev machine to ensure the accuracy 
of the digest values being produced, extended and realized as a final value in 
the PCR.

Thanks and Regards,

Imran Desai

From: Yao, Jiewen
Sent: Monday, May 20, 2019 9:30 AM
To: devel@edk2.groups.io; Desai, Imran
Subject: Re: [edk2-devel] [Enable measured boot with SM3 digest algorithm 0/4]

hi
thanks for this contribution
Besides the comment from Laszlo, would you please also share your unit test 
result?
What test you have done for this patch?

thank you!
Yao, Jiewen


> 在 2019年5月17日,下午2:43,Imran Desai  写道:
>
> https://github.com/idesai/edk2/tree/enable_sm3_measured_boot
>
> Support for SM3 digest algorithm is needed for TPM with SM3 PCR banks. This 
> digest algorithm is part of the China Crypto algorithm suite. Support for 
> these algorithms is needed to enable platforms for the PRC market.
> This integration has dependency on the openssl_1_1_1b integration into edk2.
>
> Imran Desai (4):
>  sm3_enabling: Augment crypt interface with calls into openssl to
>calculate sm3 digest prior to exercising TPM2 calls for PCR extend
>  sm3-enabling: Add SM3 TCG algorithm registry value to the
>PcdTpm2HashMask
>  sm3-enabling: Add SM3 guid reference in the TPM2 hash mask  structure
>in HashLibBaseCryptoRouterCommon.c
>  sm3-enabling: Add SM3 hashinstance library information to all OvmfPkg
>and SecurityPkg
>
> SecurityPkg/SecurityPkg.dec   |   5 +-
> OvmfPkg/OvmfPkgIa32.dsc   |   2 +
> OvmfPkg/OvmfPkgIa32X64.dsc|   2 +
> OvmfPkg/OvmfPkgX64.dsc|   2 +
> SecurityPkg/SecurityPkg.dsc   |   3 +
> .../HashInstanceLibSm3/HashInstanceLibSm3.inf |  46 ++
> MdePkg/Include/Protocol/Hash.h|   5 +
> SecurityPkg/Include/Library/HashLib.h |   1 +
> .../HashInstanceLibSm3/HashInstanceLibSm3.c   | 155 ++
> .../HashLibBaseCryptoRouterCommon.c   |   1 +
> .../HashInstanceLibSm3/HashInstanceLibSm3.uni |  21 +++
> 11 files changed, 241 insertions(+), 2 deletions(-)
> create mode 100644 
> SecurityPkg/Library/HashInstanceLibSm3/HashInstanceLibSm3.inf
> create mode 100644 SecurityPkg/Library/HashInstanceLibSm3/HashInstanceLibSm3.c
> create mode 100644 
> SecurityPkg/Library/HashInstanceLibSm3/HashInstanceLibSm3.uni
>
> --
> 2.17.0
>
>
> 
>

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41216): https://edk2.groups.io/g/devel/message/41216
Mute This Topic: https://groups.io/mt/31659817/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] why does RAND_add() take "randomness" as a "double"?

2019-05-22 Thread Paul Dale
Double makes sense.  Entropy is often estimated as a real value.

E.g. we have the aforementioned coin flipper feeding data serially.
Adding each bit sequentially means 0.125 bytes of entropy per call.

Not the best example

Pauli
-- 
Oracle
Dr Paul Dale | Cryptographer | Network Security & Encryption 
Phone +61 7 3031 7217
Oracle Australia


-Original Message-
From: Laszlo Ersek [mailto:ler...@redhat.com] 
Sent: Wednesday, 22 May 2019 12:15 AM
To: openssl-us...@openssl.org
Cc: Jian J Wang ; edk2-devel-groups-io 
; Lu, XiaoyuX ; Ard Biesheuvel 

Subject: why does RAND_add() take "randomness" as a "double"?

(resending, with my subscription to  completed)

Hi OpenSSL Developers,

(cross-posting  and ,)

OpenSSL commit [1] changed the representation of the "entropy amount" -- later 
renamed to "randomess" in [2] -- from "int" to "double". I've read the commit 
message:

commit 853f757ecea74a271a7c5cdee3f3b5fe0d3ae863
Author: Bodo Möller 
Date:   Sat Feb 19 15:22:53 2000 +

Allow for higher granularity of entropy estimates by using 'double'
instead of 'unsigned' counters.
Seed PRNG in MacOS/GetHTTPS.src/GetHTTPS.cpp.

Partially submitted by Yoram Meroz .

and also checked "MacOS/GetHTTPS.src/GetHTTPS.cpp" at the same commit.
But, I'm none the wiser.

Can someone please explain what is gained by using a floating point type here?

Is it really a relevant use case that entropy is fed from an external source to 
OpenSSL such that truncating the amount to a whole number of bits would cause 
significant lossage? (Admittedly, it could be relevant if the individual 
randomness bit counts were in the (0, 1) interval, both boundaries exclusive.)

Using floating point for randomness representation is a problem for 
environments that prefer to avoid floating point altogether, such as
edk2 ("UEFI") firmware

Thanks,
Laszlo

[1] https://github.com/openssl/openssl/commit/853f757ecea7
[2] https://github.com/openssl/openssl/commit/f367ac2b2664

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41218): https://edk2.groups.io/g/devel/message/41218
Mute This Topic: https://groups.io/mt/31696120/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH] OpensslLib: Missing local header files in [Sources] section of .INFs

2019-05-22 Thread Laszlo Ersek
On 05/21/19 21:03, Christian Rodriguez wrote:
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1821
> 
> Update OpenSSL autogeneration script for .INFs because some
> OpenSSL local headers are missing from [Sources] section of
> OpensslLib.inf and OpensslLibCrypto.inf. Update OpensslLib.inf and
> OpensslLibCrypto.inf using the updated script. Enforce compilance
> of Edk2 INF Spec 3.9, which states, All HII Unicode format files
> must be listed in [Sources] section. Not functional issue, just compilance.
> 
> Signed-off-by: Christian Rodriguez 
> Cc: Jian Wang 
> Cc: Ting Ye 
> Cc: Yonghong Zhu 
> ---
>  CryptoPkg/Library/OpensslLib/OpensslLib.inf   | 174 
> ++
>  CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf | 168 
> 
>  CryptoPkg/Library/OpensslLib/process_files.pl |  49 
> +++--
>  3 files changed, 389 insertions(+), 2 deletions(-)

Side comment: when formatting patches for edk2, I recommend the
following options:

  --stat=1000 --stat-graph-width=20

That prevents any pathname from being truncated, while keeping the stat
lines reasonably short.

On topic: this change conflicts with the on-going OpenSSL 1.1.1b rebase.
I suggest that we postpone this bugfix until OpenSSL 1.1.1b is consumed
-- especially because we're now considering delaying the upcoming stable
tag until OpenSSL 1.1.1b is ready (and perhaps we'll even change the
organizing principle behind releases from "time" to "features").

I'd request that we please hold this patch for now. (Comments in
disagreement are welcome of course.) If we agree, I'd suggest marking
TianoCore#1821 dependent on TianoCore#1089.

Thanks!
Laszlo

> diff --git a/CryptoPkg/Library/OpensslLib/OpensslLib.inf 
> b/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> index 530ac5f110..359c22a09f 100644
> --- a/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> +++ b/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> @@ -513,6 +513,180 @@
>$(OPENSSL_PATH)/ssl/t1_reneg.c
>$(OPENSSL_PATH)/ssl/t1_trce.c
>$(OPENSSL_PATH)/ssl/tls_srp.c
> +  buildinf.h
> +  $(OPENSSL_PATH)/include/internal/asn1t.h
> +  $(OPENSSL_PATH)/include/internal/bio.h
> +  $(OPENSSL_PATH)/include/internal/comp.h
> +  $(OPENSSL_PATH)/include/internal/conf.h
> +  $(OPENSSL_PATH)/include/internal/constant_time_locl.h
> +  $(OPENSSL_PATH)/include/internal/dane.h
> +  $(OPENSSL_PATH)/include/internal/dso.h
> +  $(OPENSSL_PATH)/include/internal/err.h
> +  $(OPENSSL_PATH)/include/internal/numbers.h
> +  $(OPENSSL_PATH)/include/internal/o_dir.h
> +  $(OPENSSL_PATH)/include/internal/o_str.h
> +  $(OPENSSL_PATH)/include/internal/sslconf.h
> +  $(OPENSSL_PATH)/include/internal/thread_once.h
> +  $(OPENSSL_PATH)/include/openssl/aes.h
> +  $(OPENSSL_PATH)/include/openssl/asn1.h
> +  $(OPENSSL_PATH)/include/openssl/asn1t.h
> +  $(OPENSSL_PATH)/include/openssl/asn1_mac.h
> +  $(OPENSSL_PATH)/include/openssl/async.h
> +  $(OPENSSL_PATH)/include/openssl/bio.h
> +  $(OPENSSL_PATH)/include/openssl/blowfish.h
> +  $(OPENSSL_PATH)/include/openssl/bn.h
> +  $(OPENSSL_PATH)/include/openssl/buffer.h
> +  $(OPENSSL_PATH)/include/openssl/camellia.h
> +  $(OPENSSL_PATH)/include/openssl/cast.h
> +  $(OPENSSL_PATH)/include/openssl/cmac.h
> +  $(OPENSSL_PATH)/include/openssl/cms.h
> +  $(OPENSSL_PATH)/include/openssl/comp.h
> +  $(OPENSSL_PATH)/include/openssl/conf.h
> +  $(OPENSSL_PATH)/include/openssl/conf_api.h
> +  $(OPENSSL_PATH)/include/openssl/crypto.h
> +  $(OPENSSL_PATH)/include/openssl/ct.h
> +  $(OPENSSL_PATH)/include/openssl/des.h
> +  $(OPENSSL_PATH)/include/openssl/dh.h
> +  $(OPENSSL_PATH)/include/openssl/dsa.h
> +  $(OPENSSL_PATH)/include/openssl/dtls1.h
> +  $(OPENSSL_PATH)/include/openssl/ebcdic.h
> +  $(OPENSSL_PATH)/include/openssl/ec.h
> +  $(OPENSSL_PATH)/include/openssl/ecdh.h
> +  $(OPENSSL_PATH)/include/openssl/ecdsa.h
> +  $(OPENSSL_PATH)/include/openssl/engine.h
> +  $(OPENSSL_PATH)/include/openssl/err.h
> +  $(OPENSSL_PATH)/include/openssl/evp.h
> +  $(OPENSSL_PATH)/include/openssl/e_os2.h
> +  $(OPENSSL_PATH)/include/openssl/hmac.h
> +  $(OPENSSL_PATH)/include/openssl/idea.h
> +  $(OPENSSL_PATH)/include/openssl/kdf.h
> +  $(OPENSSL_PATH)/include/openssl/lhash.h
> +  $(OPENSSL_PATH)/include/openssl/md2.h
> +  $(OPENSSL_PATH)/include/openssl/md4.h
> +  $(OPENSSL_PATH)/include/openssl/md5.h
> +  $(OPENSSL_PATH)/include/openssl/mdc2.h
> +  $(OPENSSL_PATH)/include/openssl/modes.h
> +  $(OPENSSL_PATH)/include/openssl/objects.h
> +  $(OPENSSL_PATH)/include/openssl/obj_mac.h
> +  $(OPENSSL_PATH)/include/openssl/ocsp.h
> +  $(OPENSSL_PATH)/include/openssl/opensslconf.h
> +  $(OPENSSL_PATH)/include/openssl/opensslv.h
> +  

Re: [edk2-devel] [PATCH] UefiCpuPkg CpuCommFeaturesLib: Fix ASSERT if LMCE is supported

2019-05-22 Thread Laszlo Ersek
On 05/22/19 05:26, Star Zeng wrote:
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1829
> 
> There will be ASSERT if LMCE is supported as below.
> DXE_ASSERT!: [CpuFeaturesDxe]
>   XXX\UefiCpuPkg\Library\CpuCommonFeaturesLib\MachineCheck.c (342):
> ConfigData != ((void *) 0)
> 
> The code should get Config Data and FeatureControlGetConfigData
> could be used.
> 
> BTW: A typo in LmceInitialize is also fixed.
> 
> Change-Id: I32b63ba649fc2977e155181a6263009e359742ed
> Cc: Laszlo Ersek 
> Cc: Eric Dong 
> Cc: Ruiyu Ni 
> Cc: Chandana Kumar 
> Cc: Kevin Li 
> Signed-off-by: Star Zeng 
> ---
>  UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c | 2 +-
>  UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)

(1) Please drop the "Change-Id" line from the commit message.

(2) Please update Ray's name and email address in the commit message.
(See Maintainers.txt.)

(3) This looks like a clear bugfix to me, so I'm fine if it's pushed,
after Eric or Ray ACK it.

(4) It would be really nice if you could identify in either the commit
message or the bugzilla the commit that introduced the issue.

If this is a regression fix, then I also suggest adding the Keyword
"regression" to TianoCore#1829.

Thanks
Laszlo


> diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c 
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> index 738b57dc87f9..9ddc6ce9d476 100644
> --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c
> @@ -214,7 +214,7 @@ CpuCommonFeaturesLibConstructor (
>if (IsCpuFeatureSupported (CPU_FEATURE_LMCE)) {
>  Status = RegisterCpuFeature (
> "LMCE",
> -   NULL,
> +   FeatureControlGetConfigData,
> LmceSupport,
> LmceInitialize,
> CPU_FEATURE_LMCE,
> diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c 
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> index 9ee559130080..2528e0044ecb 100644
> --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/MachineCheck.c
> @@ -322,7 +322,7 @@ LmceInitialize (
>MSR_IA32_FEATURE_CONTROL_REGISTER*MsrRegister;
>  
>//
> -  // The scope of FastStrings bit in the MSR_IA32_MISC_ENABLE is core for 
> below processor type, only program
> +  // The scope of LcmeOn bit in the MSR_IA32_MISC_ENABLE is core for below 
> processor type, only program
>// MSR_IA32_MISC_ENABLE for thread 0 in each core.
>//
>if (IS_SILVERMONT_PROCESSOR (CpuInfo->DisplayFamily, 
> CpuInfo->DisplayModel) ||
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41213): https://edk2.groups.io/g/devel/message/41213
Mute This Topic: https://groups.io/mt/31716359/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to remove Network related modules

2019-05-22 Thread Laszlo Ersek
On 05/22/19 03:50, Gao, Liming wrote:
> This is a bug. Because NetworkPkg dsc has included all network modules, the 
> ones in MdeModule are duplicated. 

I'm not sure I'm convinced -- if this patch is not applied, what
precisely is the functionality that breaks? What are the symptoms?

Either way, I'll let the other stewards decide about this.

Thanks
Laszlo

> This change is to remove the duplicated one. 
> 
> Thanks
> Liming
>> -Original Message-
>> From: Wu, Hao A
>> Sent: Wednesday, May 22, 2019 9:44 AM
>> To: devel@edk2.groups.io; Gao, Liming 
>> Subject: RE: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc to 
>> remove Network related modules
>>
>>> -Original Message-
>>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
>>> Liming Gao
>>> Sent: Tuesday, May 21, 2019 11:22 PM
>>> To: devel@edk2.groups.io
>>> Cc: Wu, Hao A
>>> Subject: [edk2-devel] [Patch] MdeModulePkg: Update MdeModulePkg.dsc
>>> to remove Network related modules
>>>
>>> Network related modules have been included in NetworkPkg.dsc.
>>> They can be removed from MdeModulePkg.dsc.
>>>
>>> Signed-off-by: Liming Gao 
>>> Cc: Hao A Wu 
>>> ---
>>>  MdeModulePkg/MdeModulePkg.dsc | 19 ---
>>>  1 file changed, 19 deletions(-)
>>>
>>> diff --git a/MdeModulePkg/MdeModulePkg.dsc
>>> b/MdeModulePkg/MdeModulePkg.dsc
>>> index ac7111dea1..995fd805e1 100644
>>> --- a/MdeModulePkg/MdeModulePkg.dsc
>>> +++ b/MdeModulePkg/MdeModulePkg.dsc
>>> @@ -63,11 +63,6 @@
>>>#
>>>UefiUsbLib|MdePkg/Library/UefiUsbLib/UefiUsbLib.inf
>>>UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf
>>> -  NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
>>> -  IpIoLib|MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
>>> -  UdpIoLib|MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
>>> -  TcpIoLib|MdeModulePkg/Library/DxeTcpIoLib/DxeTcpIoLib.inf
>>> -  DpcLib|MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
>>>
>>> SecurityManagementLib|MdeModulePkg/Library/DxeSecurityManagementL
>>> ib/DxeSecurityManagementLib.inf
>>>
>>> TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTimerLibNullTem
>>> plate.inf
>>>
>>> SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.in
>>> f
>>> @@ -263,12 +258,8 @@
>>>
>>> MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllo
>>> cationProfileLib.inf
>>>
>>> MdeModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.i
>>> nf
>>>
>>> MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32Guided
>>> SectionExtractLib.inf
>>> -  MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
>>> -  MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
>>> -  MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
>>>MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf
>>>MdeModulePkg/Library/DxeResetSystemLib/DxeResetSystemLib.inf
>>> -  MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
>>>
>>> MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protoco
>>> l.inf
>>>
>>> MdeModulePkg/Library/PeiCrc32GuidedSectionExtractLib/PeiCrc32GuidedS
>>> ectionExtractLib.inf
>>>MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf
>>> @@ -357,16 +348,6 @@
>>>MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
>>>
>>> MdeModulePkg/Universal/SmbiosMeasurementDxe/SmbiosMeasurement
>>> Dxe.inf
>>>
>>> -  MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
>>> -  MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
>>> -  MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
>>> -  MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
>>> -  MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
>>> -  MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
>>> -  MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
>>> -  MdeModulePkg/Universal/Network/SnpDxe/SnpDxe.inf
>>> -  MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
>>> -
>>
>> Reviewed-by: Hao A Wu 
>> I will let the stewards to decide whether this can be pushed at this moment.
>>
>> Best Regards,
>> Hao Wu
>>
>>>
>>> MdeModulePkg/Universal/PcatSingleSegmentPciCfg2Pei/PcatSingleSegmen
>>> tPciCfg2Pei.inf
>>>MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
>>>MdeModulePkg/Universal/PCD/Pei/Pcd.inf
>>> --
>>> 2.13.0.windows.1
>>>
>>>
>>> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41212): https://edk2.groups.io/g/devel/message/41212
Mute This Topic: https://groups.io/mt/31697980/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg: Upgrade OpenSSL to 1.1.1b

2019-05-22 Thread Laszlo Ersek
On 05/22/19 02:10, Kinney, Michael D wrote:
> Hi Laszlo,
> 
> Another option we can consider is delaying the
> freeze windows and release date (if required) to
> accommodate the OpenSSL 1.1.1b feature.

Yes, that's reasonable.

And, the same argument could apply to
.

As I just wrote in another email, we might want to generally switch to a
feature-oriented release schedule, from a purely time-based one. It
solves some issues, and raises some others (such as: feature creep,
indefinite slips, and debates about what features are critical). I'm
open to such a workflow change.

Thanks!
Laszlo

> The following page shows that the current branch
> being used by EDK II (1.1.0j) with EOL on 9/11/2019.
> 
> https://www.openssl.org/policies/releasestrat.html
> 
> Best regards,
> 
> Mike
> 
>> -Original Message-
>> From: devel@edk2.groups.io
>> [mailto:devel@edk2.groups.io] On Behalf Of Laszlo Ersek
>> Sent: Tuesday, May 21, 2019 2:15 PM
>> To: devel@edk2.groups.io; Lu, XiaoyuX
>> 
>> Cc: Wang, Jian J ; Ye, Ting
>> 
>> Subject: Re: [edk2-devel] [PATCH v4 0/7] CryptoPkg:
>> Upgrade OpenSSL to 1.1.1b
>>
>> On 05/16/19 09:54, Xiaoyu lu wrote:
>>> This series is also available at:
>>>
>> https://github.com/xiaoyuxlu/edk2/tree/bz_1089_upgrade_
>> to_openssl_1_1_1b_v4
>>>
>>> Changes:
>>>
>>> (1) CryptoPkgOpensslLib: Modify process_files.pl for
>> upgrading OpenSSL
>>>
>>> (2) CryptoPkg/OpensslLib: Exclude unnecessary files
>> in process_files.pl
>>> crypto/store/* are excluded.
>>> crypto/rand/randfile.c is excluded.
>>>
>>> (3) CryptoPkg/IntrinsicLib: Fix possible unresolved
>> external symbol issue
>>>
>>> (4) CryptoPkg/OpensslLib: Prepare for upgrading
>> OpenSSL
>>> Disable warnings for buiding OpenSSL_1_1_1b
>>>
>>> (5) CryptoPkg/OpensslLib: Fix cross-build problem for
>> AARCH64
>>>
>>> (6) CryptoPkg: Upgrade OpenSSL to 1.1.1b
>>> The biggest change is use TSC as entropy source
>>> If TSC isn't avaiable, fallback to
>> TimerLib(PerformanceCounter).
>>>
>>> (7) CryptoPkg/BaseCryptLib: Make HMAC_CTX size
>> backward compatible
>>>
>>>
>>> Verification done for this series:
>>> * Https boot in OvmfPkg.
>>> * BaseCrypt Library test. (Ovmf, EmulatorPkg)
>>>
>>> Important notice:
>>> Nt32Pkg doesn't support TimerLib

>> TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTi
>> merLibNullTemplate.inf
>>> So it will failed in Nt32Pkg.
>>>
>>> Cc: Jian J Wang 
>>> Cc: Ting Ye 
>>
>> This feature has missed edk2-stable201905.
>>
>> Please postpone the following BZ reference:
>>
>>   https://bugzilla.tianocore.org/show_bug.cgi?id=1089
>>
>> from
>>
>>
>> https://github.com/tianocore/tianocore.github.io/wiki/E
>> DK-II-Release-Planning#edk2-stable201905-tag-planning
>>
>> to
>>
>>
>> https://github.com/tianocore/tianocore.github.io/wiki/E
>> DK-II-Release-Planning#edk2-stable201908-tag-planning
>>
>> Thanks,
>> Laszlo
>>
>> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41211): https://edk2.groups.io/g/devel/message/41211
Mute This Topic: https://groups.io/mt/31638503/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-stable201905

2019-05-22 Thread Laszlo Ersek
On 05/22/19 10:28, Ni, Ray wrote:
>>> 110d4729b58e EmulatorPkg: Add NetworkPkg/NetworkPkg.dec as the
>> package
>>> dependency
>>
>> Invalid, same as commit 911efe279ec3 above.
>>
>> ... No, wait, this is worse: this patch had not received *any* review 
>> feedback
>> on the list:
>>
>>   20190520130920.9464-3-liming.gao@intel.com">http://mid.mail-archive.com/20190520130920.9464-3-liming.gao@intel.com
>>
>> but it was committed with Ray's R-b. I don't understand.
>>
> 
> Laszlo,
> The "R-b" thing is my fault. When Liming reminded me to review the patch, I 
> replied "directly"
> to Liming's mail but forgot to add "devel@edk2.groups.io" to the CC address 
> line.
> And I just noticed that when I saw Liming forwarded my reply mail out to the 
> public.
> 
> Maybe we need to set edk2 repo read-only to ordinary developers after 
> soft-freeze starts.
> Only stewards have the rights to push the changes.

This is one mitigation that crossed my mind, yes (not necessarily a
restriction to stewards, but some kind of restriction).

OTOH, I certainly want to highlight the other option, namely reworking
the feature freeze definitions. I had originally created / suggested
those as a customization of the similar QEMU definitions (= soft and
hard feature freeze), and our initial variants were never meant as
"final" -- we should consider them "work in progress", like many other
aspects of our workflow.

It's plausible that the current SFF / HFF definitions are not a good fit
for the edk2 community. Personally, I'm open to re-investigating them.
The community should please suggest changes.

Some projects adopt a release policy that says, "it's done whenever it's
done", and they don't make a release until a handful of critical
features are completed. Maybe that's a better fit for edk2 -- I don't know.


> But I am not sure whether github supports this feature.

I think push rights can be managed individually, by project owners. So
technically I think push rights for most maintainers could be revoked
*temporarily* by the edk2 project owner, when the SFF is entered. Once
the stable tag is dropped, the push rights could be re-instated.

(Just this technical possibility doesn't imply of course that it would
be a *good* idea. For example, if push rights can indeed only be managed
at the individual level, it's quite easy to make mistakes for the
project owner -- revoke too many rights, revoke too few rights, restore
too few rights, or even grant a push right as part of "restoration" that
has never existed before).

Some other projects implement this with subsystem maintainer trees, and
pull requests (*NOT* necessarily *GITHUB* pull requests!), and merges.
Namely, only a really small group of people have push rights to the
central repo. Those people merge branches from subsystem maintainers,
and push the merge commits to the central repo's master branch. In turn,
the subsystem maintainers collect and organize relevant patches from the
mailing list into "queue" branches in their personal subsystem
repositories. Once a "queue" branch is reasonable in size, and is
smoke-tested, the subsys maintainer submits a pull request to a "chief"
maintainer. During the feature freeze(s), the "chief" maintainers would
only merge such a pull request if the subject "queue" branch contained
only eligible patches.


> Or maybe we could create a branch when soft-freeze starts, and every push on 
> the master
> will be audited and cherry-picked by stewards. On the date of release, the 
> master branch
> will be discarded and the branch created before becomes master.

Technically this could work, but I see too much potential for confusion
(for consumers too). People that pull from the central edk2 repo would
have to stay up-to-date on the "current" master branch. Or else, we'd
have to rename branches, but that's even worse: it would cause
non-fast-forwardable HEAD movements on the local master branches of
consumers.

Thanks,
Laszlo

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41210): https://edk2.groups.io/g/devel/message/41210
Mute This Topic: https://groups.io/mt/31653140/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 0/2] Add FSP Dispatch mode switch

2019-05-22 Thread Chiu, Chasel
Boot loader (FspWrapper/Platform code) now can switch to Dispatch mode
defined by FSP 2.1 spec using PcdFspModeSelection.
For backward compatibility different FspBinPkg may be consumed in each mode.

To support this switch, below are required changes
in KabylakeOpenBoardPkg and KabylakeSiliconPkg:
1. In Dispatch mode AmberLakeFspBinPkg will be consumed and
   KabylakeFspBinPkg is for API mode for backward compatible.

2. Temporary memory arrangement will be different between each mode because
   in Dispatch mode FSP will share the same stack with boot loader.

3. For now default mode is still API before all implementation completed.

Cc: Nate DeSimone 
Cc: Michael Kubacki 
Signed-off-by: Chasel Chiu 

Chasel, Chiu (2):
  KabylakeSiliconPkg: Add FSP Dispatch switch.
  KabylakeOpenBoardPkg: Add FSP Dispatch switch.

 Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf
   |   8 
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc  
   |  33 +
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc   
   |  29 +
 
Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf
 | 146 
++
 4 files changed, 208 insertions(+), 8 deletions(-)
 create mode 100644 
Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf

-- 
2.13.3.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41207): https://edk2.groups.io/g/devel/message/41207
Mute This Topic: https://groups.io/mt/31717894/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 2/2] KabylakeOpenBoardPkg: Add FSP Dispatch switch.

2019-05-22 Thread Chiu, Chasel
From: "Chasel, Chiu" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1832

Basing on PcdFspModeSelection setting either KabylakeFspBinPkg
or AmberLakeFspBinPkg will be used and temporary memory
arrangement will be different as AmberLakeFspBinPkg will share
the same stack with boot loader. Also enlarged FSP-T size to
support future larger FSP binary.

Test: Booted Kabylake RVP3 to Windows successfully.

Cc: Nate DeSimone 
Cc: Michael Kubacki 
Signed-off-by: Chasel Chiu 
---
 Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf  |  8 

 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc| 33 
+
 Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkgPcd.dsc | 29 
+
 3 files changed, 62 insertions(+), 8 deletions(-)

diff --git 
a/Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf 
b/Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf
index 3a28bd4109..6cb49c941c 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf
+++ b/Platform/Intel/KabylakeOpenBoardPkg/Include/Fdf/FlashMapInclude.fdf
@@ -1,7 +1,7 @@
 ## @file
 #  FDF file of Platform.
 #
-# Copyright (c) 2017, Intel Corporation. All rights reserved.
+# Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-2-Clause-Patent
 #
@@ -41,6 +41,6 @@ SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspSSize  
  = 0x0006
 SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspMOffset  = 
0x0060  # Flash addr (0xFFE0)
 SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspMSize= 
0x000BC000  #
 SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspTOffset  = 
0x006BC000  # Flash addr (0xFFEBC000)
-SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspTSize= 
0x4000  #
-SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvPreMemoryOffset = 
0x006C  # Flash addr (0xFFEC)
-SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvPreMemorySize   = 
0x0014  #
+SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvFspTSize= 
0x00014000  #
+SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvPreMemoryOffset = 
0x006D  # Flash addr (0xFFED)
+SET gMinPlatformPkgTokenSpaceGuid.PcdFlashFvPreMemorySize   = 
0x0013  #
diff --git a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc 
b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
index 7f19ad1eed..1dfe49a7ad 100644
--- a/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
+++ b/Platform/Intel/KabylakeOpenBoardPkg/KabylakeRvp3/OpenBoardPkg.dsc
@@ -15,7 +15,7 @@
   DEFINE  PLATFORM_PACKAGE= MinPlatformPkg
   DEFINE  PLATFORM_SI_PACKAGE = KabylakeSiliconPkg
   DEFINE  PLATFORM_SI_BIN_PACKAGE = KabylakeSiliconBinPkg
-  DEFINE  PLATFORM_FSP_BIN_PACKAGE= KabylakeFspBinPkg
+  DEFINE  PLATFORM_FSP_BIN_PACKAGE= AmberLakeFspBinPkg
   DEFINE  PLATFORM_BOARD_PACKAGE  = KabylakeOpenBoardPkg
   DEFINE  BOARD   = KabylakeRvp3
   DEFINE  PROJECT = 
$(PLATFORM_BOARD_PACKAGE)/$(BOARD)
@@ -24,6 +24,21 @@
   # Platform On/Off features are defined here
   #
   !include OpenBoardPkgConfig.dsc
+  !include OpenBoardPkgPcd.dsc
+
+[Defines]
+!if gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection == 1
+  #
+  # For backward compatibility API mode will use KabylakeFspBinPkg.
+  # KabylakeFspBinPkg only supports API mode.
+  #
+  DEFINE  PLATFORM_FSP_BIN_PACKAGE= KabylakeFspBinPkg
+!else
+  #
+  # AmberLakeFspBinPkg supports both API and Dispatch modes
+  #
+  DEFINE  PLATFORM_FSP_BIN_PACKAGE= AmberLakeFspBinPkg
+!endif
 
 

 #
@@ -92,8 +107,20 @@
   
FspWrapperApiTestLib|IntelFsp2WrapperPkg/Library/PeiFspWrapperApiTestLib/PeiFspWrapperApiTestLib.inf
 
   
FspWrapperPlatformLib|$(PLATFORM_PACKAGE)/FspWrapper/Library/PeiFspWrapperPlatformLib/PeiFspWrapperPlatformLib.inf
-  
SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFsp.inf
+
+!if gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection == 1
+  #
+  # Below library are used by FSP API mode
+  #
   
SiliconPolicyUpdateLib|$(PLATFORM_BOARD_PACKAGE)/FspWrapper/Library/PeiSiliconPolicyUpdateLibFsp/PeiSiliconPolicyUpdateLibFsp.inf
+  
SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFsp.inf
+!else
+  #
+  # Below library are used by FSP Dispatch mode and non-FSP build (EDK2 build)
+  #
+  
SiliconPolicyUpdateLib|$(PLATFORM_BOARD_PACKAGE)/Policy/Library/PeiSiliconPolicyUpdateLib/PeiSiliconPolicyUpdateLib.inf
+  
SiliconPolicyInitLib|$(PLATFORM_SI_PACKAGE)/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf

[edk2-devel] [PATCH 1/2] KabylakeSiliconPkg: Add FSP Dispatch switch.

2019-05-22 Thread Chiu, Chasel
From: "Chasel, Chiu" 

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1832

PcdFspModeSelection is used as switch for boot loader to
consume FSP in API mode or Dispatch mode. For backward
compatibility, if boot loader running in FSP API mode the
KabylakeFspBinPkg will be used which does not have FSP 2.1
changes. For FSP Dispatch mode AmberLakeFspBinPkg will be
used with FSP 2.1 support.
One INF was duplicate to include different DEC file in
each build type.

Test: Booted Kabylake RVP3 to Windows successfully.

Cc: Nate DeSimone 
Cc: Michael Kubacki 
Signed-off-by: Chasel Chiu 
---
 
Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf
 | 146 
++
 1 file changed, 146 insertions(+)

diff --git 
a/Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf
 
b/Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf
new file mode 100644
index 00..aebd3583bc
--- /dev/null
+++ 
b/Silicon/Intel/KabylakeSiliconPkg/Library/PeiSiliconPolicyInitLibFsp/PeiSiliconPolicyInitLibFspAml.inf
@@ -0,0 +1,146 @@
+### @file
+# Library functions for Fsp Policy Initialization Library.
+#
+# Copyright (c) 2019, Intel Corporation. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+
+#
+# Defines Section - statements that will be processed to create a Makefile.
+#
+
+[Defines]
+  INF_VERSION= 0x00010005
+  BASE_NAME  = PeiSiliconPolicyInitLibFspAml
+  FILE_GUID  = 930816C4-D182-4A23-BF21-9AED635AF06C
+  MODULE_TYPE= BASE
+  VERSION_STRING = 1.0
+  LIBRARY_CLASS  = SiliconPolicyInitLib
+
+#
+# The following information is for reference only and not required by the 
build tools.
+#
+#  VALID_ARCHITECTURES   = IA32
+#
+
+
+#
+# Sources Section - list of files that are required for the build to succeed.
+#
+
+
+[Sources]
+  PeiFspPolicyInitLib.c
+  PeiFspSiPolicyInitLib.c
+  PeiFspPchPolicyInitLib.c
+  PeiFspCpuPolicyInitLib.c
+  PeiFspMePolicyInitLib.c
+  PeiFspSaPolicyInitLib.c
+  PeiFspMiscUpdInitLib.c
+
+  PeiPolicyInitPreMem.c
+  PeiPolicyInit.c
+  PeiPolicyInit.h
+
+
+#
+# Package Dependency Section - list of Package files that are required for
+#  this module.
+#
+
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IntelFsp2Pkg/IntelFsp2Pkg.dec
+  IntelFsp2WrapperPkg/IntelFsp2WrapperPkg.dec
+  KabylakeSiliconPkg/SiPkg.dec
+  AmberLakeFspBinPkg/AmberLakeFspBinPkg.dec
+
+[LibraryClasses]
+  BaseMemoryLib
+  DebugLib
+  IoLib
+  PeiServicesLib
+  PcdLib
+  SmbusLib
+  MmPciLib
+  ConfigBlockLib
+  MemoryAllocationLib
+  DebugPrintErrorLevelLib
+  FspWrapperApiLib
+
+[Pcd]
+  gSiPkgTokenSpaceGuid.PcdTsegSize## CONSUMES
+  gSiPkgTokenSpaceGuid.PcdSmbusBaseAddress## CONSUMES
+  gIntelFsp2PkgTokenSpaceGuid.PcdTemporaryRamBase  ## CONSUMES
+  gIntelFsp2PkgTokenSpaceGuid.PcdTemporaryRamSize  ## CONSUMES
+  gIntelFsp2PkgTokenSpaceGuid.PcdFspTemporaryRamSize   ## CONSUMES
+  gIntelFsp2PkgTokenSpaceGuid.PcdFspReservedBufferSize ## CONSUMES
+  gIntelFsp2WrapperTokenSpaceGuid.PcdFspmUpdDataAddress ## CONSUMES
+  gIntelFsp2WrapperTokenSpaceGuid.PcdFspmBaseAddress## CONSUMES
+  gIntelFsp2WrapperTokenSpaceGuid.PcdFspsUpdDataAddress ## CONSUMES
+  gIntelFsp2WrapperTokenSpaceGuid.PcdFspsBaseAddress## CONSUMES
+
+[Ppis]
+  gSiPolicyPpiGuid  ## CONSUMES
+  gSiPreMemPolicyPpiGuid## CONSUMES
+
+[Guids]
+  gTraceHubPreMemConfigGuid ## CONSUMES
+  gSmbusPreMemConfigGuid## CONSUMES
+  gDciPreMemConfigGuid  ## CONSUMES
+  gHpetPreMemConfigGuid ## CONSUMES
+  gHsioPciePreMemConfigGuid ## CONSUMES
+  gHsioSataPreMemConfigGuid ## CONSUMES
+  gHsioPreMemConfigGuid ## CONSUMES
+  gPcieRpPreMemConfigGuid   ## CONSUMES
+  gLpcPreMemConfigGuid  ## CONSUMES
+  gPchGeneralPreMemConfigGuid   ## CONSUMES
+  gWatchDogPreMemConfigGuid ## CONSUMES
+  gLanConfigGuid   

Re: [edk2-devel] [edk2] Soft Feature Freeze starts today for edk2-stable201905

2019-05-22 Thread Ni, Ray
> > 110d4729b58e EmulatorPkg: Add NetworkPkg/NetworkPkg.dec as the
> package
> > dependency
> 
> Invalid, same as commit 911efe279ec3 above.
> 
> ... No, wait, this is worse: this patch had not received *any* review feedback
> on the list:
> 
>   20190520130920.9464-3-liming.gao@intel.com">http://mid.mail-archive.com/20190520130920.9464-3-liming.gao@intel.com
> 
> but it was committed with Ray's R-b. I don't understand.
> 

Laszlo,
The "R-b" thing is my fault. When Liming reminded me to review the patch, I 
replied "directly"
to Liming's mail but forgot to add "devel@edk2.groups.io" to the CC address 
line.
And I just noticed that when I saw Liming forwarded my reply mail out to the 
public.

Maybe we need to set edk2 repo read-only to ordinary developers after 
soft-freeze starts.
Only stewards have the rights to push the changes.

But I am not sure whether github supports this feature.

Or maybe we could create a branch when soft-freeze starts, and every push on 
the master
will be audited and cherry-picked by stewards. On the date of release, the 
master branch
will be discarded and the branch created before becomes master.

Thanks,
Ray



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41206): https://edk2.groups.io/g/devel/message/41206
Mute This Topic: https://groups.io/mt/31653140/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH 2/4] EmbeddedPkg: Fix response check flag

2019-05-22 Thread Loh, Tien Hock
Hi Ard, Leif,

Can you help review this?

Thanks!

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41204): https://edk2.groups.io/g/devel/message/41204
Mute This Topic: https://groups.io/mt/31552954/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH v2] EmbeddedPkg: Clear CTYPE on initialization

2019-05-22 Thread Loh, Tien Hock
Hi Ard, Leif,

Can you help review this?

Thanks!

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41205): https://edk2.groups.io/g/devel/message/41205
Mute This Topic: https://groups.io/mt/31552976/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 1/2] [staging/HBFA PATCH]: UefiHostUnitTestCasePkg: Remove PcdFrameworkCompatibilitySupport

2019-05-22 Thread Sun, Tengfen
To be consistent with edk2, remove PcdFrameworkCompatibilitySupport

Signed-off-by: Tengfen Sun 
---
 .../TestCase/FatPkg/FatPei/Override/FatPei.inf  | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git 
a/HBFA/UefiHostUnitTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf 
b/HBFA/UefiHostUnitTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
index 515648ec6ed3..636a267a068f 100644
--- a/HBFA/UefiHostUnitTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
+++ b/HBFA/UefiHostUnitTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
@@ -60,15 +60,11 @@
   gEfiPeiVirtualBlockIo2PpiGuid ## SOMETIMES_CONSUMES 
PPI_NOTIFY
   gEfiPeiDeviceRecoveryModulePpiGuid## SOMETIMES_PRODUCES
 
-
-[FeaturePcd]
-  gEfiMdeModulePkgTokenSpaceGuid.PcdFrameworkCompatibilitySupport ## 
CONSUMES
-
 [Pcd]
   gEfiMdeModulePkgTokenSpaceGuid.PcdRecoveryFileName ## CONSUMES
 
 [Depex]
-  gEfiPeiMemoryDiscoveredPpiGuid AND gEfiPeiBootInRecoveryModePpiGuid
+  gEfiPeiMemoryDiscoveredPpiGuid
 
 [UserExtensions.TianoCore."ExtraFiles"]
   FatPeiExtra.uni
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41202): https://edk2.groups.io/g/devel/message/41202
Mute This Topic: https://groups.io/mt/31717687/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 0/2] [staging/HBFA PATCH]: Remove PcdFrameworkCompatibilitySupport

2019-05-22 Thread Sun, Tengfen
To be consistent with edk2, remove PcdFrameworkCompatibilitySupport

tengfens (2):
  [staging/HBFA PATCH]: UefiHostUnitTestCasePkg: Remove
PcdFrameworkCompatibilitySupport
  [staging/HBFA PATCH]: UefiHostFuzzTestCasePkg: Remove
PcdFrameworkCompatibilitySupport

 .../TestCase/FatPkg/FatPei/Override/FatPei.inf  | 6 +-
 .../TestCase/FatPkg/FatPei/Override/FatPei.inf  | 6 +-
 2 files changed, 2 insertions(+), 10 deletions(-)

-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41201): https://edk2.groups.io/g/devel/message/41201
Mute This Topic: https://groups.io/mt/31717685/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 2/2] [staging/HBFA PATCH]: UefiHostFuzzTestCasePkg: Remove PcdFrameworkCompatibilitySupport

2019-05-22 Thread Sun, Tengfen
To be consistent with edk2, remove PcdFrameworkCompatibilitySupport

Signed-off-by: Tengfen Sun 
---
 .../TestCase/FatPkg/FatPei/Override/FatPei.inf  | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git 
a/HBFA/UefiHostFuzzTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf 
b/HBFA/UefiHostFuzzTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
index 515648ec6ed3..636a267a068f 100644
--- a/HBFA/UefiHostFuzzTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
+++ b/HBFA/UefiHostFuzzTestCasePkg/TestCase/FatPkg/FatPei/Override/FatPei.inf
@@ -60,15 +60,11 @@
   gEfiPeiVirtualBlockIo2PpiGuid ## SOMETIMES_CONSUMES 
PPI_NOTIFY
   gEfiPeiDeviceRecoveryModulePpiGuid## SOMETIMES_PRODUCES
 
-
-[FeaturePcd]
-  gEfiMdeModulePkgTokenSpaceGuid.PcdFrameworkCompatibilitySupport ## 
CONSUMES
-
 [Pcd]
   gEfiMdeModulePkgTokenSpaceGuid.PcdRecoveryFileName ## CONSUMES
 
 [Depex]
-  gEfiPeiMemoryDiscoveredPpiGuid AND gEfiPeiBootInRecoveryModePpiGuid
+  gEfiPeiMemoryDiscoveredPpiGuid
 
 [UserExtensions.TianoCore."ExtraFiles"]
   FatPeiExtra.uni
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41203): https://edk2.groups.io/g/devel/message/41203
Mute This Topic: https://groups.io/mt/31717688/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [edk2-devel] [PATCH v4 edk2-platforms 1/1] Silicon/DesignWare/Driver: DwEmacSnpDxe: Add DesignWare EMAC driver

2019-05-22 Thread Ard Biesheuvel
On Wed, 22 May 2019 at 03:37, Ooi, Tzy Way  wrote:
>
> Hi Maintainers,
>
> Please could you help to review this patch? Thanks.
>

I already did, but my email response got rejected twice

https://edk2.groups.io/g/devel/message/40829?p=,,,20,0,0,0::Created,,emac,20,2,0,31541649

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41200): https://edk2.groups.io/g/devel/message/41200
Mute This Topic: https://groups.io/mt/31541649/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 4/4] [staging/HBFA PATCH]: UefiHostUnitTestPkg: Enable cmocka unit test build with CmockaHostUnitTestPkg

2019-05-22 Thread Sun, Tengfen
In order to improve the current build process, enable cmocka unit test build 
with CmockaHostUnitTestPkg.
REF: https://edk2.groups.io/g/devel/message/39893

Signed-off-by: Tengfen Sun 
---
 .../UnitTestAssertLibcmocka.inf   |  4 +-
 .../UnitTestLibcmocka/UnitTestLibcmocka.inf   |  2 +
 HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt| 85 ---
 .../SampleUnitTestcmocka.inf  |  2 +
 .../UefiHostUnitTestBuildOption.dsc   | 40 +++--
 .../UefiHostUnitTestPkg.dsc   |  8 ++
 6 files changed, 44 insertions(+), 97 deletions(-)

diff --git 
a/HBFA/UefiHostUnitTestPkg/Library/UnitTestAssertLibcmocka/UnitTestAssertLibcmocka.inf
 
b/HBFA/UefiHostUnitTestPkg/Library/UnitTestAssertLibcmocka/UnitTestAssertLibcmocka.inf
index ef780e1fb0db..fd6098a3136b 100644
--- 
a/HBFA/UefiHostUnitTestPkg/Library/UnitTestAssertLibcmocka/UnitTestAssertLibcmocka.inf
+++ 
b/HBFA/UefiHostUnitTestPkg/Library/UnitTestAssertLibcmocka/UnitTestAssertLibcmocka.inf
@@ -15,11 +15,13 @@
 
 [LibraryClasses]
   BaseMemoryLib
+  CmockaLib
 
 [Packages]
   MdePkg/MdePkg.dec
   UnitTestPkg/UnitTestPkg.dec
   UefiHostUnitTestPkg/UefiHostUnitTestPkg.dec
-
+  CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
+  
 [Sources]
   UnitTestAssertLib.c
diff --git 
a/HBFA/UefiHostUnitTestPkg/Library/UnitTestLibcmocka/UnitTestLibcmocka.inf 
b/HBFA/UefiHostUnitTestPkg/Library/UnitTestLibcmocka/UnitTestLibcmocka.inf
index 376c57d33fac..68bd26c4b7db 100644
--- a/HBFA/UefiHostUnitTestPkg/Library/UnitTestLibcmocka/UnitTestLibcmocka.inf
+++ b/HBFA/UefiHostUnitTestPkg/Library/UnitTestLibcmocka/UnitTestLibcmocka.inf
@@ -17,12 +17,14 @@
   BaseLib
   MemoryAllocationLib
   OsServiceLib
+  CmockaLib
 
 [Packages]
   MdePkg/MdePkg.dec
   UnitTestPkg/UnitTestPkg.dec
   UefiHostTestPkg/UefiHostTestPkg.dec
   UefiHostUnitTestPkg/UefiHostUnitTestPkg.dec
+  CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
 
 [Sources]
   UnitTestLib.c
diff --git a/HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt 
b/HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt
index b1d3781ba5fc..f4b8d51f3058 100644
--- a/HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt
+++ b/HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt
@@ -1,77 +1,26 @@
 How to run cmocka for UEFI code.
 =
-0) download CMake (http://www.cmake.org/)
-
-1) install cmocka-1.1.5
-Part A: Install cmocka in linux
-1.1 download cmocka-1.1.5.tar.xz (https://cmocka.org/) and unzip it ($tar xJvf 
cmocka-1.1.5.tar.xz)
-1.2 build
-  $ cd cmocka-1.1.5
-  $ mkdir build
-  $ cd build
-  $ export CFLAGS=-m32
-  $ export CXXFLAGS=-m32
-  $ cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug -D 
WITH_STATIC_LIB=ON ..
-  $ make
-  $ sudo sh -c "echo '<...>/cmocka-1.1.5/build/src' >> /etc/ld.so.conf"
-  $ sudo ldconfig 
-  $ cd ..
-  $ mkdir build64
-  $ cd build64
-  $ export CFLAGS=-m64
-  $ export CXXFLAGS=-m64
-  $ cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug -D 
WITH_STATIC_LIB=ON ..
-  $ make
-  $ sudo sh -c "echo '<...>/cmocka-1.1.5/build64/src' >> /etc/ld.so.conf"
-  $ sudo ldconfig 
-
-  the lib is at ./src/libcmocka-static.a, ./src/libcmocka.so
-
-1.3 export CMOCKA_INC_PATH=<...>/cmocka-1.1.5/include
-export CMOCKA_LIB_PATH=<...>/cmocka-1.1.5/build/src
-export CMOCKA_LIB_PATH_64=<...>/cmocka-1.1.5/build64/src
-export CMOCKA_LIB_NAME=cmocka[-static]
-export CMOCKA_LIB_NAME_64=cmocka[-static]
-
-Part B: Install cmocka in windows
-1.1 download cmocka-1.1.5 from https://cmocka.org/, and unzip 
cmocka-1.1.5.tar.xz
-1.2 open visual studio dev command prompt, to go 
-cd <...>\cmocka-1.1.5\
-mkdir build
-cd build
-cmake -G "Visual Studio 14 2015" -D WITH_STATIC_LIB=ON ..
-
-mkdir build64
-cd build64
-cmake -G "Visual Studio 14 2015 Win64" -D WITH_STATIC_LIB=ON ..
-
-1.3 load solution at cmocka.sln, and build the solution.
-or type:
-devenv cmocka.sln /Build [Debug|Release] /Project cmocka[-static]
-
-static lib can be found at:
-cmocka-1.1.5\[build|build64]\src\[Debug|Release]\cmocka-static.lib
-
-dynamic lib can be found at: 
-cmocka-1.1.5\[build|build64]\src\[Debug|Release]\cmocka.[lib|dll]
-
-1.4 set CMOCKA_INC_PATH=<...>\cmocka-1.1.5\include
-set CMOCKA_LIB_PATH=<...>\cmocka-1.1.5\build\src\[Debug|Release]
-set CMOCKA_LIB_PATH_64=<...>\cmocka-1.1.5\build64\src\[Debug|Release]
-set CMOCKA_LIB_NAME=cmocka[-static].lib
-set CMOCKA_LIB_NAME_64=cmocka[-static].lib
-
-1.5 add env path, only for dynamic lib build
-Add %CMOCKA_LIB_PATH% to %PATH%, for IA32 run.
-Add %CMOCKA_LIB_PATH_64% to %PATH%, for X64 run.
+1) install cmocka
+  Cmocka repository was added as one submodule of HBFA project.
+  The user can use the following commands to clone both main HBFA repo and 
Cmocka submodule:
+  Add the "--recursive" flag to the git clone command:
+  $ git clone --recursive 
+or
+  Manually initialize and update the submodules after the clone operation on 
main project:
+  $ git clone 
+  $ 

[edk2-devel] [PATCH 0/4] [staging/HBFA PATCH]: Enable cmocka unit test build with submodule.

2019-05-22 Thread Sun, Tengfen
In order to improve the current build process, add cmocka submodule for unit 
test build.
REF: https://edk2.groups.io/g/devel/message/39893

tengfens (4):
  [staging/HBFA PATCH]: CmockaHostUnitTestPkg: Add cmocka submodule.
  [staging/HBFA PATCH]: CmockaHostUnitTestPkg: Enable
CmockaHostUnitTestPkg build.
  [staging/HBFA PATCH]: UefiHostUnitTestCasePkg: Add CmockaLib
  [staging/HBFA PATCH]: UefiHostUnitTestPkg: Enable cmocka unit test
build with CmockaHostUnitTestPkg

 .gitmodules   |  3 +
 .../CmockaHostUnitTestPkg.dec | 16 
 .../CmockaHostUnitTestPkg.dsc | 22 +
 .../Library/CmockaLib/CmockaLib.inf   | 33 +++
 .../Library/CmockaLib/CmockaLib.uni   | 16 
 .../Library/CmockaLib/cmocka  |  1 +
 .../UefiHostUnitTestCasePkg.dsc   | 11 +++
 .../UnitTestAssertLibcmocka.inf   |  4 +-
 .../UnitTestLibcmocka/UnitTestLibcmocka.inf   |  2 +
 HBFA/UefiHostUnitTestPkg/ReadMe-cmocka.txt| 85 ---
 .../SampleUnitTestcmocka.inf  |  2 +
 .../UefiHostUnitTestBuildOption.dsc   | 40 +++--
 .../UefiHostUnitTestPkg.dsc   |  8 ++
 13 files changed, 146 insertions(+), 97 deletions(-)
 create mode 100644 .gitmodules
 create mode 100644 HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
 create mode 100644 HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dsc
 create mode 100644 HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
 create mode 100644 HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.uni
 create mode 16 HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/cmocka

-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41195): https://edk2.groups.io/g/devel/message/41195
Mute This Topic: https://groups.io/mt/31717506/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[edk2-devel] [PATCH 2/4] [staging/HBFA PATCH]: CmockaHostUnitTestPkg: Enable CmockaHostUnitTestPkg build.

2019-05-22 Thread Sun, Tengfen
Enable build for CmockaHostUnitTestPkg with cmocka submodule.
REF: https://edk2.groups.io/g/devel/message/39893

Signed-off-by: Tengfen Sun 
---
 .../CmockaHostUnitTestPkg.dec | 16 +
 .../CmockaHostUnitTestPkg.dsc | 22 +
 .../Library/CmockaLib/CmockaLib.inf   | 33 +++
 .../Library/CmockaLib/CmockaLib.uni   | 16 +
 4 files changed, 87 insertions(+)
 create mode 100644 HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
 create mode 100644 HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dsc
 create mode 100644 HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
 create mode 100644 HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.uni

diff --git a/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec 
b/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
new file mode 100644
index ..85b41b1165d4
--- /dev/null
+++ b/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
@@ -0,0 +1,16 @@
+## @file  CmockaHostUnitTestPkg.dec
+#
+# Copyright (c) 2019, Intel Corporation. All rights reserved.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  DEC_SPECIFICATION  = 0x00010005
+  PACKAGE_NAME   = CmockaHostUnitTestPkg
+  PACKAGE_GUID   = 09566709-F1CA-4365-BB99-FC7869BE4E1C
+  PACKAGE_VERSION= 0.1
+
+[Includes]
+  Library/CmockaLib/cmocka/include
+  Library/CmockaLib/cmocka/include/cmockery
\ No newline at end of file
diff --git a/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dsc 
b/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dsc
new file mode 100644
index ..27868fc5e050
--- /dev/null
+++ b/HBFA/CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dsc
@@ -0,0 +1,22 @@
+## @file CmockaHostUnitTestPkg.dsc
+# 
+# Copyright (c) 2019, Intel Corporation. All rights reserved.
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  PLATFORM_NAME  = CmockaHostUnitTestPkg
+  PLATFORM_GUID  = AD571B20-0E74-4513-AE17-E557079A9756
+  PLATFORM_VERSION   = 0.1
+  DSC_SPECIFICATION  = 0x00010005
+  OUTPUT_DIRECTORY   = Build/CmockaHostUnitTestPkg
+  SUPPORTED_ARCHITECTURES= IA32|X64
+  BUILD_TARGETS  = DEBUG|RELEASE
+  SKUID_IDENTIFIER   = DEFAULT
+
+[LibraryClasses]
+  CmockaLib|CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
+
+[Components]
+  CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
\ No newline at end of file
diff --git a/HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf 
b/HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
new file mode 100644
index ..dc9f48347625
--- /dev/null
+++ b/HBFA/CmockaHostUnitTestPkg/Library/CmockaLib/CmockaLib.inf
@@ -0,0 +1,33 @@
+## @file
+#  This module provides Cmocka Library implementation.
+#
+#  Copyright (c) 2019, Intel Corporation. All rights reserved.
+#  SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  INF_VERSION= 0x00010005
+  BASE_NAME  = CmockaLib
+  MODULE_UNI_FILE= CmockaLib.uni
+  FILE_GUID  = F1662152-3399-49AC-BE44-CAA97575FACE
+  MODULE_TYPE= BASE
+  VERSION_STRING = 0.1
+  LIBRARY_CLASS  = CmockaLib
+  DEFINE CMOCKA_PATH = cmocka
+
+#
+#  VALID_ARCHITECTURES   = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  $(CMOCKA_PATH)/src/cmocka.c
+  
+[Packages]
+  CmockaHostUnitTestPkg/CmockaHostUnitTestPkg.dec
+  
+[BuildOptions]
+  MSFT:*_*_*_CC_FLAGS  ==  /c /D _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES=1 
/D _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT=1 /D 
_CRT_NONSTDC_NO_WARNINGS=1 /D _CRT_SECURE_NO_WARNINGS=1 -DHAVE_VSNPRINTF 
-DHAVE_SNPRINTF
+
+  GCC:*_*_IA32_CC_FLAGS== -m32 -O0 -g -fprofile-arcs -ftest-coverage 
-std=gnu99 -Wpedantic -Wall -Wshadow -Wmissing-prototypes -Wcast-align 
-Werror=address -Wstrict-prototypes -Werror=strict-prototypes -Wwrite-strings 
-Werror=write-strings -Werror-implicit-function-declaration -Wpointer-arith 
-Werror=pointer-arith -Wdeclaration-after-statement 
-Werror=declaration-after-statement -Wreturn-type -Werror=return-type 
-Wuninitialized -Werror=uninitialized -Werror=strict-overflow 
-Wstrict-overflow=2 -Wno-format-zero-length -Wmissing-field-initializers 
-Wformat-security -Werror=format-security -fno-common -Wformat -fno-common 
-fstack-protector-strong -DHAVE_SIGNAL_H
+  GCC:*_*_X64_CC_FLAGS == -m64 -O0 -g -fprofile-arcs -ftest-coverage 
-std=gnu99 -Wpedantic -Wall -Wshadow -Wmissing-prototypes -Wcast-align 
-Werror=address -Wstrict-prototypes -Werror=strict-prototypes -Wwrite-strings 
-Werror=write-strings -Werror-implicit-function-declaration -Wpointer-arith 
-Werror=pointer-arith -Wdeclaration-after-statement 
-Werror=declaration-after-statement -Wreturn-type -Werror=return-type 
-Wuninitialized 

[edk2-devel] [PATCH] SecurityPkg/OpalPassword: Add PCD to skip password prompt

2019-05-22 Thread Maggie Chu
https://bugzilla.tianocore.org/show_bug.cgi?id=1801
Add a PCD for skipping password prompt in device unlocked status.
Previous change only support if storage device is in locked status.
This change is added to support the case that security status of the
storage device is unlocked.

Signed-off-by: Maggie Chu 
Cc: Eric Dong 
Cc: Chao Zhang 
Cc: Jiewen Yao 
---
 SecurityPkg/SecurityPkg.dec   | 10 +-
 SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c| 16 ++--
 SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf |  2 +-
 3 files changed, 20 insertions(+), 8 deletions(-)

diff --git a/SecurityPkg/SecurityPkg.dec b/SecurityPkg/SecurityPkg.dec
index 3314f1854b..96db80c2d2 100644
--- a/SecurityPkg/SecurityPkg.dec
+++ b/SecurityPkg/SecurityPkg.dec
@@ -422,11 +422,11 @@
   # @Prompt Possible TPM2 Interrupt Number buffer
   gEfiSecurityPkgTokenSpaceGuid.PcdTpm2PossibleIrqNumBuf|{0x00, 0x00, 0x00, 
0x00}|VOID*|0x0001001D
 
-  ## Indicates if Opal DXE driver skip unlock device flow.
-  #   TRUE  - Skip unlock device flow.
-  #   FALSE - Does not skip unlock device flow.
-  # @Prompt Skip Opal DXE driver unlock device flow.
-  gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalDxeUnlock|FALSE|BOOLEAN|0x00010020
+  ## Indicates if Opal DXE driver skip password prompt.
+  #   TRUE  - Skip password prompt.
+  #   FALSE - Does not skip password prompt.
+  # @Prompt Skip Opal DXE driver password prompt.
+  
gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalPasswordPrompt|FALSE|BOOLEAN|0x00010020
 
 [PcdsDynamic, PcdsDynamicEx]
 
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c 
b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
index 965205c0b2..e14fa32354 100644
--- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
+++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
@@ -899,8 +899,20 @@ OpalDriverRequestPassword (
 
 IsLocked = OpalDeviceLocked (>OpalDisk.SupportedAttributes, 
>OpalDisk.LockingFeature);
 
-if (IsLocked && PcdGetBool (PcdSkipOpalDxeUnlock)) {
-  return;
+//
+// Add PcdSkipOpalPasswordPrompt to determin whether to skip password 
prompt.
+// Due to board design, device may not power off during system warm boot, 
which result in
+// security status remain unlocked status, hence we add device security 
status check here.
+//
+// If device is in the locked status, device keeps locked and system 
continues booting.
+// If device is in the unlocked status, system is forced shutdown to 
support security requirement.
+//
+if (PcdGetBool (PcdSkipOpalPasswordPrompt)) {
+  if (IsLocked) {
+return;
+  } else {
+gRT->ResetSystem (EfiResetShutdown, EFI_SUCCESS, 0, NULL);
+  }
 }
 
 while (Count < MAX_PASSWORD_TRY_COUNT) {
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf 
b/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf
index e74f147aaa..87519198c0 100644
--- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf
+++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf
@@ -71,7 +71,7 @@
   gS3StorageDeviceInitListGuid  ## SOMETIMES_PRODUCES ## 
UNDEFINED
 
 [Pcd]
-  gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalDxeUnlock  ## CONSUMES
+  gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalPasswordPrompt  ## CONSUMES
 
 [Depex]
   gEfiHiiStringProtocolGuid AND gEfiHiiDatabaseProtocolGuid
-- 
2.16.2.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#41194): https://edk2.groups.io/g/devel/message/41194
Mute This Topic: https://groups.io/mt/31717459/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-