public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
@ 2016-09-02 14:29 Leif Lindholm
  2016-09-02 14:29 ` [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg Leif Lindholm
                   ` (4 more replies)
  0 siblings, 5 replies; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 14:29 UTC (permalink / raw)
  To: edk2-devel; +Cc: Laszlo Ersek, Michael D Kinney, Liming Gao, Ard Biesheuvel

The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
caused all ARM/AARCH64 platforms to stop building. The oversight was
helped by the ARM implementation residing in ArmPkg rather than in
MdePkg with all of the others.

Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
accidents in future, and add the new functions.

This set resolves the build issue without affecting any non-ARM
platforms, in the interest of getting back to a working master
branch. It would be very nice if it could be approved quickly.

Ard Biesheuvel (2):
  MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
  MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function

Leif Lindholm (1):
  MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg

 ArmPkg/ArmPkg.dsc                                  |  1 -
 ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
 BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
 .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
 .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
 .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
 .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
 .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
 .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
 .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
 .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
 .../Library/BaseMemoryLibStm/CopyMem.c             |  0
 .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
 .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
 .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
 .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
 .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
 .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
 .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
 .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
 .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
 .../Library/BaseMemoryLibStm/SetMem.c              |  0
 .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
 .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
 .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
 .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
 .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
 MdePkg/MdePkg.dsc                                  |  1 +
 28 files changed, 133 insertions(+), 3 deletions(-)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
 create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)

-- 
2.9.3



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
@ 2016-09-02 14:29 ` Leif Lindholm
  2016-09-02 15:02   ` Ard Biesheuvel
  2016-09-02 14:29 ` [PATCH 2/3] MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function Leif Lindholm
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 14:29 UTC (permalink / raw)
  To: edk2-devel; +Cc: Laszlo Ersek, Michael D Kinney, Liming Gao, Ard Biesheuvel

Recent changes to the BaseMemoryLib implementations in MdePkg,
and other changes dependent on these, left all ARM* platforms
unbuildable. To avoid this sort of thing in the future, move
the ARM* BaseMemoryLib implementations to the same locations
as the other ones.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
---
 ArmPkg/ArmPkg.dsc                                                | 1 -
 ArmVirtPkg/ArmVirt.dsc.inc                                       | 2 +-
 BeagleBoardPkg/BeagleBoardPkg.dsc                                | 2 +-
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c     | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S        | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm      | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S         | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm       | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c  | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c            | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c     | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c      | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c         | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c   | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c   | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c   | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c             | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c    | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c      | 0
 {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c     | 0
 MdePkg/MdePkg.dsc                                                | 1 +
 27 files changed, 3 insertions(+), 3 deletions(-)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
 rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)

diff --git a/ArmPkg/ArmPkg.dsc b/ArmPkg/ArmPkg.dsc
index 6f9fc66..09cbb85 100644
--- a/ArmPkg/ArmPkg.dsc
+++ b/ArmPkg/ArmPkg.dsc
@@ -112,7 +112,6 @@ [Components.common]
   ArmPkg/Library/ArmDisassemblerLib/ArmDisassemblerLib.inf
   ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf
   ArmPkg/Library/ArmLib/Null/NullArmLib.inf
-  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
   ArmPkg/Library/BdsLib/BdsLib.inf
   ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
   ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc
index 6c6a52b..338c22c 100644
--- a/ArmVirtPkg/ArmVirt.dsc.inc
+++ b/ArmVirtPkg/ArmVirt.dsc.inc
@@ -69,7 +69,7 @@ [LibraryClasses.common]
 
   # 1/123 faster than Stm or Vstm version
   #BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
-  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
+  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
 
   # Networking Requirements
   NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
diff --git a/BeagleBoardPkg/BeagleBoardPkg.dsc b/BeagleBoardPkg/BeagleBoardPkg.dsc
index b4a645b..7bf7d52 100644
--- a/BeagleBoardPkg/BeagleBoardPkg.dsc
+++ b/BeagleBoardPkg/BeagleBoardPkg.dsc
@@ -55,7 +55,7 @@ [LibraryClasses.common]
   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
 
   BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
-  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
+  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
 
   EfiResetSystemLib|BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf
 
diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
rename to MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
rename to MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S
rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
diff --git a/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf b/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
rename to MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
diff --git a/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/CopyMem.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/CopyMem.c
rename to MdePkg/Library/BaseMemoryLibStm/CopyMem.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c
rename to MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c
rename to MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h b/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h
rename to MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/SetMem.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/SetMem.c
rename to MdePkg/Library/BaseMemoryLibStm/SetMem.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
diff --git a/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
similarity index 100%
rename from ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
rename to MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
diff --git a/MdePkg/MdePkg.dsc b/MdePkg/MdePkg.dsc
index ab57689..75a8f1a 100644
--- a/MdePkg/MdePkg.dsc
+++ b/MdePkg/MdePkg.dsc
@@ -177,6 +177,7 @@ [Components.EBC]
   MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
 
 [Components.ARM, Components.AARCH64]
+  MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
   MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
 
 [BuildOptions]
-- 
2.9.3



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 2/3] MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
  2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
  2016-09-02 14:29 ` [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg Leif Lindholm
@ 2016-09-02 14:29 ` Leif Lindholm
  2016-09-02 14:29 ` [PATCH 3/3] MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() " Leif Lindholm
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 14:29 UTC (permalink / raw)
  To: edk2-devel; +Cc: Laszlo Ersek, Michael D Kinney, Liming Gao, Ard Biesheuvel

From: Ard Biesheuvel <ard.biesheuvel@linaro.org>

BaseMemoryLib has recently been extended with an API function
IsZeroGuid(), so copy the default implementation into BaseMemoryLibStm
as well.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
---
 MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c | 29 ++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
index 2b4ed57..36d42d7 100644
--- a/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
+++ b/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
@@ -130,3 +130,32 @@ ScanGuid (
   }
   return NULL;
 }
+
+/**
+  Checks if the given GUID is a zero GUID.
+
+  This function checks whether the given GUID is a zero GUID. If the GUID is
+  identical to a zero GUID then TRUE is returned. Otherwise, FALSE is returned.
+
+  If Guid is NULL, then ASSERT().
+
+  @param  Guid        The pointer to a 128 bit GUID.
+
+  @retval TRUE        Guid is a zero GUID.
+  @retval FALSE       Guid is not a zero GUID.
+
+**/
+BOOLEAN
+EFIAPI
+IsZeroGuid (
+  IN CONST GUID  *Guid
+  )
+{
+  UINT64  LowPartOfGuid;
+  UINT64  HighPartOfGuid;
+
+  LowPartOfGuid  = ReadUnaligned64 ((CONST UINT64*) Guid);
+  HighPartOfGuid = ReadUnaligned64 ((CONST UINT64*) Guid + 1);
+
+  return (BOOLEAN) (LowPartOfGuid == 0 && HighPartOfGuid == 0);
+}
-- 
2.9.3



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 3/3] MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
  2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
  2016-09-02 14:29 ` [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg Leif Lindholm
  2016-09-02 14:29 ` [PATCH 2/3] MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function Leif Lindholm
@ 2016-09-02 14:29 ` Leif Lindholm
  2016-09-02 14:48 ` [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Laszlo Ersek
  2016-09-02 15:49 ` Kinney, Michael D
  4 siblings, 0 replies; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 14:29 UTC (permalink / raw)
  To: edk2-devel; +Cc: Laszlo Ersek, Michael D Kinney, Liming Gao, Ard Biesheuvel

From: Ard Biesheuvel <ard.biesheuvel@linaro.org>

BaseMemoryLib has recently been extended with an API function
IsZeroBuffer(), so copy the default implementation into BaseMemoryLibStm
as well.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
---
 .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
 .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
 MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c    | 29 ++++++++++++
 MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h  | 17 +++++++
 4 files changed, 101 insertions(+)
 create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c

diff --git a/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf b/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
index eac6cef..30e2459 100644
--- a/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
+++ b/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
@@ -45,6 +45,7 @@ [Sources.Common]
   SetMem16Wrapper.c
   SetMemWrapper.c
   CopyMemWrapper.c
+  IsZeroBufferWrapper.c
   MemLibGeneric.c
   MemLibGuid.c
   MemLibInternals.h
diff --git a/MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c b/MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
new file mode 100644
index 0000000..c42c1aa
--- /dev/null
+++ b/MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
@@ -0,0 +1,54 @@
+/** @file
+  Implementation of IsZeroBuffer function.
+
+  The following BaseMemoryLib instances contain the same copy of this file:
+
+    BaseMemoryLib
+    BaseMemoryLibMmx
+    BaseMemoryLibSse2
+    BaseMemoryLibRepStr
+    BaseMemoryLibOptDxe
+    BaseMemoryLibOptPei
+    PeiMemoryLib
+    UefiMemoryLib
+
+  Copyright (c) 2016, Intel Corporation. All rights reserved.<BR>
+  This program and the accompanying materials
+  are licensed and made available under the terms and conditions of the BSD License
+  which accompanies this distribution.  The full text of the license may be found at
+  http://opensource.org/licenses/bsd-license.php
+
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+**/
+
+#include "MemLibInternals.h"
+
+/**
+  Checks if the contents of a buffer are all zeros.
+
+  This function checks whether the contents of a buffer are all zeros. If the
+  contents are all zeros, return TRUE. Otherwise, return FALSE.
+
+  If Length > 0 and Buffer is NULL, then ASSERT().
+  If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
+
+  @param  Buffer      The pointer to the buffer to be checked.
+  @param  Length      The size of the buffer (in bytes) to be checked.
+
+  @retval TRUE        Contents of the buffer are all zeros.
+  @retval FALSE       Contents of the buffer are not all zeros.
+
+**/
+BOOLEAN
+EFIAPI
+IsZeroBuffer (
+  IN CONST VOID  *Buffer,
+  IN UINTN       Length
+  )
+{
+  ASSERT (!(Buffer == NULL && Length > 0));
+  ASSERT ((Length - 1) <= (MAX_ADDRESS - (UINTN)Buffer));
+  return InternalMemIsZeroBuffer (Buffer, Length);
+}
diff --git a/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
index 54c2701..43fbcb6 100644
--- a/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
+++ b/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
@@ -262,3 +262,32 @@ InternalMemScanMem64 (
   } while (--Length != 0);
   return NULL;
 }
+
+/**
+  Checks whether the contents of a buffer are all zeros.
+
+  @param  Buffer  The pointer to the buffer to be checked.
+  @param  Length  The size of the buffer (in bytes) to be checked.
+
+  @retval TRUE    Contents of the buffer are all zeros.
+  @retval FALSE   Contents of the buffer are not all zeros.
+
+**/
+BOOLEAN
+EFIAPI
+InternalMemIsZeroBuffer (
+  IN CONST VOID  *Buffer,
+  IN UINTN       Length
+  )
+{
+  CONST UINT8 *BufferData;
+  UINTN       Index;
+
+  BufferData = Buffer;
+  for (Index = 0; Index < Length; Index++) {
+    if (BufferData[Index] != 0) {
+      return FALSE;
+    }
+  }
+  return TRUE;
+}
diff --git a/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h b/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
index 10c741f..f7b44f5 100644
--- a/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
+++ b/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
@@ -231,4 +231,21 @@ InternalMemScanMem64 (
   IN      UINT64                    Value
   );
 
+/**
+  Checks whether the contents of a buffer are all zeros.
+
+  @param  Buffer  The pointer to the buffer to be checked.
+  @param  Length  The size of the buffer (in bytes) to be checked.
+
+  @retval TRUE    Contents of the buffer are all zeros.
+  @retval FALSE   Contents of the buffer are not all zeros.
+
+**/
+BOOLEAN
+EFIAPI
+InternalMemIsZeroBuffer (
+  IN CONST VOID  *Buffer,
+  IN UINTN       Length
+  );
+
 #endif
-- 
2.9.3



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
                   ` (2 preceding siblings ...)
  2016-09-02 14:29 ` [PATCH 3/3] MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() " Leif Lindholm
@ 2016-09-02 14:48 ` Laszlo Ersek
  2016-09-02 14:53   ` Laszlo Ersek
  2016-09-02 15:49 ` Kinney, Michael D
  4 siblings, 1 reply; 19+ messages in thread
From: Laszlo Ersek @ 2016-09-02 14:48 UTC (permalink / raw)
  To: Leif Lindholm, edk2-devel; +Cc: Michael D Kinney, Liming Gao, Ard Biesheuvel

On 09/02/16 16:29, Leif Lindholm wrote:
> The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
> caused all ARM/AARCH64 platforms to stop building. The oversight was
> helped by the ARM implementation residing in ArmPkg rather than in
> MdePkg with all of the others.
> 
> Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
> accidents in future, and add the new functions.
> 
> This set resolves the build issue without affecting any non-ARM
> platforms, in the interest of getting back to a working master
> branch. It would be very nice if it could be approved quickly.
> 
> Ard Biesheuvel (2):
>   MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
>   MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
> 
> Leif Lindholm (1):
>   MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
> 
>  ArmPkg/ArmPkg.dsc                                  |  1 -
>  ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
>  BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
>  .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
>  .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
>  .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
>  .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
>  .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
>  .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
>  .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
>  .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
>  .../Library/BaseMemoryLibStm/CopyMem.c             |  0
>  .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
>  .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
>  .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem.c              |  0
>  .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
>  .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
>  MdePkg/MdePkg.dsc                                  |  1 +
>  28 files changed, 133 insertions(+), 3 deletions(-)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
>  create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
> 

I believe the series needs a few more (small) patches to update the library resolutions (and other references) in DSC files that become invalid due to the move:

$ git grep ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
ArmPkg/ArmPkg.dsc:  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
ArmVirtPkg/ArmVirt.dsc.inc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
BeagleBoardPkg/BeagleBoardPkg.dsc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf

Thanks
Laszlo


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 14:48 ` [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Laszlo Ersek
@ 2016-09-02 14:53   ` Laszlo Ersek
  2016-09-02 16:02     ` Leif Lindholm
  0 siblings, 1 reply; 19+ messages in thread
From: Laszlo Ersek @ 2016-09-02 14:53 UTC (permalink / raw)
  To: Leif Lindholm, edk2-devel; +Cc: Michael D Kinney, Liming Gao, Ard Biesheuvel

On 09/02/16 16:48, Laszlo Ersek wrote:
> On 09/02/16 16:29, Leif Lindholm wrote:
>> The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
>> caused all ARM/AARCH64 platforms to stop building. The oversight was
>> helped by the ARM implementation residing in ArmPkg rather than in
>> MdePkg with all of the others.
>>
>> Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
>> accidents in future, and add the new functions.
>>
>> This set resolves the build issue without affecting any non-ARM
>> platforms, in the interest of getting back to a working master
>> branch. It would be very nice if it could be approved quickly.
>>
>> Ard Biesheuvel (2):
>>   MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
>>   MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
>>
>> Leif Lindholm (1):
>>   MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
>>
>>  ArmPkg/ArmPkg.dsc                                  |  1 -
>>  ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
>>  BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
>>  .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
>>  .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
>>  .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
>>  .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
>>  .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
>>  .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
>>  .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
>>  .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
>>  .../Library/BaseMemoryLibStm/CopyMem.c             |  0
>>  .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
>>  .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
>>  .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
>>  .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
>>  .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
>>  .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
>>  .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
>>  .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
>>  .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
>>  .../Library/BaseMemoryLibStm/SetMem.c              |  0
>>  .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
>>  .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
>>  .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
>>  .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
>>  .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
>>  MdePkg/MdePkg.dsc                                  |  1 +
>>  28 files changed, 133 insertions(+), 3 deletions(-)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
>>  create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
>>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
>>
> 
> I believe the series needs a few more (small) patches to update the library resolutions (and other references) in DSC files that become invalid due to the move:
> 
> $ git grep ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> ArmPkg/ArmPkg.dsc:  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> ArmVirtPkg/ArmVirt.dsc.inc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> BeagleBoardPkg/BeagleBoardPkg.dsc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf

Scratch that, the first patch does it already. Sorry for missing it; I
got misled by the subject (MdePkg...) and I wasn't careful enough when
looking at the diffstat. Sorry about the noise.

Laszlo



^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 14:29 ` [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg Leif Lindholm
@ 2016-09-02 15:02   ` Ard Biesheuvel
  2016-09-02 15:23     ` Leif Lindholm
  0 siblings, 1 reply; 19+ messages in thread
From: Ard Biesheuvel @ 2016-09-02 15:02 UTC (permalink / raw)
  To: Leif Lindholm; +Cc: edk2-devel, Laszlo Ersek, Michael D Kinney, Liming Gao


> On 2 sep. 2016, at 15:29, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> 
> Recent changes to the BaseMemoryLib implementations in MdePkg,
> and other changes dependent on these, left all ARM* platforms
> unbuildable. To avoid this sort of thing in the future, move
> the ARM* BaseMemoryLib implementations to the same locations
> as the other ones.
> 

Can't we just get rid of the stm version, and move everything to the generic version? Copying all this crap into MdePkg does not seem like an improvement to me at all.

The AArch64 optdxe changes i proposed are arguably as harmless, since they don't affect any other arch either. And the stm aarch64 versions are plain c to begin with

> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
> ---
> ArmPkg/ArmPkg.dsc                                                | 1 -
> ArmVirtPkg/ArmVirt.dsc.inc                                       | 2 +-
> BeagleBoardPkg/BeagleBoardPkg.dsc                                | 2 +-
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c     | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S        | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm      | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S         | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm       | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c  | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c            | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c     | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c      | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c         | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c   | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c   | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c   | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c             | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c    | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c      | 0
> {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c     | 0
> MdePkg/MdePkg.dsc                                                | 1 +
> 27 files changed, 3 insertions(+), 3 deletions(-)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
> 
> diff --git a/ArmPkg/ArmPkg.dsc b/ArmPkg/ArmPkg.dsc
> index 6f9fc66..09cbb85 100644
> --- a/ArmPkg/ArmPkg.dsc
> +++ b/ArmPkg/ArmPkg.dsc
> @@ -112,7 +112,6 @@ [Components.common]
>   ArmPkg/Library/ArmDisassemblerLib/ArmDisassemblerLib.inf
>   ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf
>   ArmPkg/Library/ArmLib/Null/NullArmLib.inf
> -  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
>   ArmPkg/Library/BdsLib/BdsLib.inf
>   ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
>   ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
> diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc
> index 6c6a52b..338c22c 100644
> --- a/ArmVirtPkg/ArmVirt.dsc.inc
> +++ b/ArmVirtPkg/ArmVirt.dsc.inc
> @@ -69,7 +69,7 @@ [LibraryClasses.common]
> 
>   # 1/123 faster than Stm or Vstm version
>   #BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
> -  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> +  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> 
>   # Networking Requirements
>   NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> diff --git a/BeagleBoardPkg/BeagleBoardPkg.dsc b/BeagleBoardPkg/BeagleBoardPkg.dsc
> index b4a645b..7bf7d52 100644
> --- a/BeagleBoardPkg/BeagleBoardPkg.dsc
> +++ b/BeagleBoardPkg/BeagleBoardPkg.dsc
> @@ -55,7 +55,7 @@ [LibraryClasses.common]
>   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
> 
>   BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
> -  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> +  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> 
>   EfiResetSystemLib|BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf
> 
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> rename to MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> rename to MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf b/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> rename to MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/CopyMem.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/CopyMem.c
> rename to MdePkg/Library/BaseMemoryLibStm/CopyMem.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> rename to MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c
> rename to MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h b/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h
> rename to MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/SetMem.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/SetMem.c
> rename to MdePkg/Library/BaseMemoryLibStm/SetMem.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> diff --git a/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> similarity index 100%
> rename from ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> rename to MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> diff --git a/MdePkg/MdePkg.dsc b/MdePkg/MdePkg.dsc
> index ab57689..75a8f1a 100644
> --- a/MdePkg/MdePkg.dsc
> +++ b/MdePkg/MdePkg.dsc
> @@ -177,6 +177,7 @@ [Components.EBC]
>   MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
> 
> [Components.ARM, Components.AARCH64]
> +  MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
>   MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
> 
> [BuildOptions]
> -- 
> 2.9.3
> 


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 15:02   ` Ard Biesheuvel
@ 2016-09-02 15:23     ` Leif Lindholm
  2016-09-02 16:07       ` Ard Biesheuvel
  0 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 15:23 UTC (permalink / raw)
  To: Ard Biesheuvel; +Cc: edk2-devel, Laszlo Ersek, Michael D Kinney, Liming Gao

On Fri, Sep 02, 2016 at 04:02:44PM +0100, Ard Biesheuvel wrote:
> > On 2 sep. 2016, at 15:29, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> > 
> > Recent changes to the BaseMemoryLib implementations in MdePkg,
> > and other changes dependent on these, left all ARM* platforms
> > unbuildable. To avoid this sort of thing in the future, move
> > the ARM* BaseMemoryLib implementations to the same locations
> > as the other ones.
> 
> Can't we just get rid of the stm version, and move everything to the
> generic version? Copying all this crap into MdePkg does not seem
> like an improvement to me at all.

This isn't a proposed alternative to your patchset, this is an
alternative to reverting all of the other BaseMemoryLib changes.
I'm happy to throw it away next week if we can get something better in
by then.

> The AArch64 optdxe changes i proposed are arguably as harmless,

Yes, but that leaves ARM broken.

> since they don't affect any other arch either. And the stm aarch64
> versions are plain c to begin with

And I want to discuss that next week. Against the backdrop of a
working master branch.

/
    Leif

> > Contributed-under: TianoCore Contribution Agreement 1.0
> > Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
> > ---
> > ArmPkg/ArmPkg.dsc                                                | 1 -
> > ArmVirtPkg/ArmVirt.dsc.inc                                       | 2 +-
> > BeagleBoardPkg/BeagleBoardPkg.dsc                                | 2 +-
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c     | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S        | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm      | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S         | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm       | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c  | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c            | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c     | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c      | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c         | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c   | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c   | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c   | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c             | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c    | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c      | 0
> > {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c     | 0
> > MdePkg/MdePkg.dsc                                                | 1 +
> > 27 files changed, 3 insertions(+), 3 deletions(-)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
> > rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
> > 
> > diff --git a/ArmPkg/ArmPkg.dsc b/ArmPkg/ArmPkg.dsc
> > index 6f9fc66..09cbb85 100644
> > --- a/ArmPkg/ArmPkg.dsc
> > +++ b/ArmPkg/ArmPkg.dsc
> > @@ -112,7 +112,6 @@ [Components.common]
> >   ArmPkg/Library/ArmDisassemblerLib/ArmDisassemblerLib.inf
> >   ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf
> >   ArmPkg/Library/ArmLib/Null/NullArmLib.inf
> > -  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> >   ArmPkg/Library/BdsLib/BdsLib.inf
> >   ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
> >   ArmPkg/Library/DebugAgentSymbolsBaseLib/DebugAgentSymbolsBaseLib.inf
> > diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc
> > index 6c6a52b..338c22c 100644
> > --- a/ArmVirtPkg/ArmVirt.dsc.inc
> > +++ b/ArmVirtPkg/ArmVirt.dsc.inc
> > @@ -69,7 +69,7 @@ [LibraryClasses.common]
> > 
> >   # 1/123 faster than Stm or Vstm version
> >   #BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
> > -  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > +  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > 
> >   # Networking Requirements
> >   NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
> > diff --git a/BeagleBoardPkg/BeagleBoardPkg.dsc b/BeagleBoardPkg/BeagleBoardPkg.dsc
> > index b4a645b..7bf7d52 100644
> > --- a/BeagleBoardPkg/BeagleBoardPkg.dsc
> > +++ b/BeagleBoardPkg/BeagleBoardPkg.dsc
> > @@ -55,7 +55,7 @@ [LibraryClasses.common]
> >   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
> > 
> >   BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
> > -  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > +  BaseMemoryLib|MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > 
> >   EfiResetSystemLib|BeagleBoardPkg/Library/ResetSystemLib/ResetSystemLib.inf
> > 
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> > rename to MdePkg/Library/BaseMemoryLibStm/AArch64/CopyMem.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> > rename to MdePkg/Library/BaseMemoryLibStm/AArch64/SetMem.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> > rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.S
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> > rename to MdePkg/Library/BaseMemoryLibStm/Arm/CopyMem.asm
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> > rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.S
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm b/MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> > rename to MdePkg/Library/BaseMemoryLibStm/Arm/SetMem.asm
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf b/MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > rename to MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/CompareMemWrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMem.c b/MdePkg/Library/BaseMemoryLibStm/CopyMem.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/CopyMem.c
> > rename to MdePkg/Library/BaseMemoryLibStm/CopyMem.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/CopyMemWrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> > rename to MdePkg/Library/BaseMemoryLibStm/MemLibGeneric.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c b/MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/MemLibGuid.c
> > rename to MdePkg/Library/BaseMemoryLibStm/MemLibGuid.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h b/MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/MemLibInternals.h
> > rename to MdePkg/Library/BaseMemoryLibStm/MemLibInternals.h
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/ScanMem16Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/ScanMem32Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/ScanMem64Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/ScanMem8Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem.c b/MdePkg/Library/BaseMemoryLibStm/SetMem.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/SetMem.c
> > rename to MdePkg/Library/BaseMemoryLibStm/SetMem.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/SetMem16Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/SetMem32Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/SetMem64Wrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/SetMemWrapper.c
> > diff --git a/ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c b/MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> > similarity index 100%
> > rename from ArmPkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> > rename to MdePkg/Library/BaseMemoryLibStm/ZeroMemWrapper.c
> > diff --git a/MdePkg/MdePkg.dsc b/MdePkg/MdePkg.dsc
> > index ab57689..75a8f1a 100644
> > --- a/MdePkg/MdePkg.dsc
> > +++ b/MdePkg/MdePkg.dsc
> > @@ -177,6 +177,7 @@ [Components.EBC]
> >   MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
> > 
> > [Components.ARM, Components.AARCH64]
> > +  MdePkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> >   MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
> > 
> > [BuildOptions]
> > -- 
> > 2.9.3
> > 


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
                   ` (3 preceding siblings ...)
  2016-09-02 14:48 ` [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Laszlo Ersek
@ 2016-09-02 15:49 ` Kinney, Michael D
  2016-09-02 15:57   ` Leif Lindholm
  4 siblings, 1 reply; 19+ messages in thread
From: Kinney, Michael D @ 2016-09-02 15:49 UTC (permalink / raw)
  To: Leif Lindholm, edk2-devel@lists.01.org, Kinney, Michael D
  Cc: Laszlo Ersek, Gao, Liming, Ard Biesheuvel

Leif,

Moving this library into MdePkg looks good to me along with the addition of the 2 new BaseMemoryLib APIs.

Minor issues in ArmPkg.dsc, ArmPkg.dsc.inc not updating the Copyright to 2016.  

Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>

Mike

> -----Original Message-----
> From: Leif Lindholm [mailto:leif.lindholm@linaro.org]
> Sent: Friday, September 2, 2016 7:29 AM
> To: edk2-devel@lists.01.org
> Cc: Laszlo Ersek <lersek@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com>;
> Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Subject: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
> 
> The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
> caused all ARM/AARCH64 platforms to stop building. The oversight was
> helped by the ARM implementation residing in ArmPkg rather than in
> MdePkg with all of the others.
> 
> Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
> accidents in future, and add the new functions.
> 
> This set resolves the build issue without affecting any non-ARM
> platforms, in the interest of getting back to a working master
> branch. It would be very nice if it could be approved quickly.
> 
> Ard Biesheuvel (2):
>   MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
>   MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
> 
> Leif Lindholm (1):
>   MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
> 
>  ArmPkg/ArmPkg.dsc                                  |  1 -
>  ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
>  BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
>  .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
>  .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
>  .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
>  .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
>  .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
>  .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
>  .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
>  .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
>  .../Library/BaseMemoryLibStm/CopyMem.c             |  0
>  .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
>  .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
>  .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
>  .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
>  .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem.c              |  0
>  .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
>  .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
>  .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
>  MdePkg/MdePkg.dsc                                  |  1 +
>  28 files changed, 133 insertions(+), 3 deletions(-)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
>  create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
>  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
> 
> --
> 2.9.3



^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 15:49 ` Kinney, Michael D
@ 2016-09-02 15:57   ` Leif Lindholm
  2016-09-02 15:59     ` Andrew Fish
  0 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 15:57 UTC (permalink / raw)
  To: Kinney, Michael D
  Cc: edk2-devel@lists.01.org, Laszlo Ersek, Gao, Liming,
	Ard Biesheuvel

On Fri, Sep 02, 2016 at 03:49:03PM +0000, Kinney, Michael D wrote:
> Moving this library into MdePkg looks good to me along with the
> addition of the 2 new BaseMemoryLib APIs.
> 
> Minor issues in ArmPkg.dsc, ArmPkg.dsc.inc not updating the
> Copyright to 2016.

Ah, OK, I could fix that before pushing if you'd like?

> Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>

Many thanks. I'll wait to hear back from Ard before I push.

Regards,

Leif

> Mike
> 
> > -----Original Message-----
> > From: Leif Lindholm [mailto:leif.lindholm@linaro.org]
> > Sent: Friday, September 2, 2016 7:29 AM
> > To: edk2-devel@lists.01.org
> > Cc: Laszlo Ersek <lersek@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com>;
> > Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel <ard.biesheuvel@linaro.org>
> > Subject: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
> > 
> > The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
> > caused all ARM/AARCH64 platforms to stop building. The oversight was
> > helped by the ARM implementation residing in ArmPkg rather than in
> > MdePkg with all of the others.
> > 
> > Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
> > accidents in future, and add the new functions.
> > 
> > This set resolves the build issue without affecting any non-ARM
> > platforms, in the interest of getting back to a working master
> > branch. It would be very nice if it could be approved quickly.
> > 
> > Ard Biesheuvel (2):
> >   MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
> >   MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
> > 
> > Leif Lindholm (1):
> >   MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
> > 
> >  ArmPkg/ArmPkg.dsc                                  |  1 -
> >  ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
> >  BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
> >  .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
> >  .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
> >  .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
> >  .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
> >  .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
> >  .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
> >  .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
> >  .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
> >  .../Library/BaseMemoryLibStm/CopyMem.c             |  0
> >  .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
> >  .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
> >  .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
> >  .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
> >  .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
> >  .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
> >  .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
> >  .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
> >  .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
> >  .../Library/BaseMemoryLibStm/SetMem.c              |  0
> >  .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
> >  .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
> >  .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
> >  .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
> >  .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
> >  MdePkg/MdePkg.dsc                                  |  1 +
> >  28 files changed, 133 insertions(+), 3 deletions(-)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
> >  create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
> >  rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
> > 
> > --
> > 2.9.3
> 


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 15:57   ` Leif Lindholm
@ 2016-09-02 15:59     ` Andrew Fish
  0 siblings, 0 replies; 19+ messages in thread
From: Andrew Fish @ 2016-09-02 15:59 UTC (permalink / raw)
  To: Leif Lindholm
  Cc: Mike Kinney, edk2-devel@lists.01.org, Laszlo Ersek, Gao, Liming,
	Ard Biesheuvel


> On Sep 2, 2016, at 8:57 AM, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> 
> On Fri, Sep 02, 2016 at 03:49:03PM +0000, Kinney, Michael D wrote:
>> Moving this library into MdePkg looks good to me along with the
>> addition of the 2 new BaseMemoryLib APIs.
>> 
>> Minor issues in ArmPkg.dsc, ArmPkg.dsc.inc not updating the
>> Copyright to 2016.
> 
> Ah, OK, I could fix that before pushing if you'd like?
> 
>> Reviewed-by: Michael Kinney <michael.d.kinney@intel.com>
> 
> Many thanks. I'll wait to hear back from Ard before I push.
> 

Reviewed-by: Andrew Fish <afish@apple.com>

Thanks,

Andrew Fish

> Regards,
> 
> Leif
> 
>> Mike
>> 
>>> -----Original Message-----
>>> From: Leif Lindholm [mailto:leif.lindholm@linaro.org]
>>> Sent: Friday, September 2, 2016 7:29 AM
>>> To: edk2-devel@lists.01.org
>>> Cc: Laszlo Ersek <lersek@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com>;
>>> Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel <ard.biesheuvel@linaro.org>
>>> Subject: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
>>> 
>>> The recent addition, and use, of new functions IsZeroGuid/IsZeroBuffer
>>> caused all ARM/AARCH64 platforms to stop building. The oversight was
>>> helped by the ARM implementation residing in ArmPkg rather than in
>>> MdePkg with all of the others.
>>> 
>>> Move BaseMemoryLibStm across to MdePkg to reduce risk of similar
>>> accidents in future, and add the new functions.
>>> 
>>> This set resolves the build issue without affecting any non-ARM
>>> platforms, in the interest of getting back to a working master
>>> branch. It would be very nice if it could be approved quickly.
>>> 
>>> Ard Biesheuvel (2):
>>>  MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function
>>>  MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() API function
>>> 
>>> Leif Lindholm (1):
>>>  MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
>>> 
>>> ArmPkg/ArmPkg.dsc                                  |  1 -
>>> ArmVirtPkg/ArmVirt.dsc.inc                         |  2 +-
>>> BeagleBoardPkg/BeagleBoardPkg.dsc                  |  2 +-
>>> .../Library/BaseMemoryLibStm/AArch64/CopyMem.c     |  0
>>> .../Library/BaseMemoryLibStm/AArch64/SetMem.c      |  0
>>> .../Library/BaseMemoryLibStm/Arm/CopyMem.S         |  0
>>> .../Library/BaseMemoryLibStm/Arm/CopyMem.asm       |  0
>>> .../Library/BaseMemoryLibStm/Arm/SetMem.S          |  0
>>> .../Library/BaseMemoryLibStm/Arm/SetMem.asm        |  0
>>> .../Library/BaseMemoryLibStm/BaseMemoryLibStm.inf  |  1 +
>>> .../Library/BaseMemoryLibStm/CompareMemWrapper.c   |  0
>>> .../Library/BaseMemoryLibStm/CopyMem.c             |  0
>>> .../Library/BaseMemoryLibStm/CopyMemWrapper.c      |  0
>>> .../Library/BaseMemoryLibStm/IsZeroBufferWrapper.c | 54 ++++++++++++++++++++++
>>> .../Library/BaseMemoryLibStm/MemLibGeneric.c       | 29 ++++++++++++
>>> .../Library/BaseMemoryLibStm/MemLibGuid.c          | 29 ++++++++++++
>>> .../Library/BaseMemoryLibStm/MemLibInternals.h     | 17 +++++++
>>> .../Library/BaseMemoryLibStm/ScanMem16Wrapper.c    |  0
>>> .../Library/BaseMemoryLibStm/ScanMem32Wrapper.c    |  0
>>> .../Library/BaseMemoryLibStm/ScanMem64Wrapper.c    |  0
>>> .../Library/BaseMemoryLibStm/ScanMem8Wrapper.c     |  0
>>> .../Library/BaseMemoryLibStm/SetMem.c              |  0
>>> .../Library/BaseMemoryLibStm/SetMem16Wrapper.c     |  0
>>> .../Library/BaseMemoryLibStm/SetMem32Wrapper.c     |  0
>>> .../Library/BaseMemoryLibStm/SetMem64Wrapper.c     |  0
>>> .../Library/BaseMemoryLibStm/SetMemWrapper.c       |  0
>>> .../Library/BaseMemoryLibStm/ZeroMemWrapper.c      |  0
>>> MdePkg/MdePkg.dsc                                  |  1 +
>>> 28 files changed, 133 insertions(+), 3 deletions(-)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/CopyMem.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/AArch64/SetMem.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.S (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/CopyMem.asm (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.S (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/Arm/SetMem.asm (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf (94%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CompareMemWrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMem.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/CopyMemWrapper.c (100%)
>>> create mode 100644 MdePkg/Library/BaseMemoryLibStm/IsZeroBufferWrapper.c
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGeneric.c (88%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibGuid.c (81%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/MemLibInternals.h (90%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem16Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem32Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem64Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ScanMem8Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem16Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem32Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMem64Wrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/SetMemWrapper.c (100%)
>>> rename {ArmPkg => MdePkg}/Library/BaseMemoryLibStm/ZeroMemWrapper.c (100%)
>>> 
>>> --
>>> 2.9.3
>> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel



^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib
  2016-09-02 14:53   ` Laszlo Ersek
@ 2016-09-02 16:02     ` Leif Lindholm
  0 siblings, 0 replies; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 16:02 UTC (permalink / raw)
  To: Laszlo Ersek; +Cc: edk2-devel, Michael D Kinney, Liming Gao, Ard Biesheuvel

On Fri, Sep 02, 2016 at 04:53:19PM +0200, Laszlo Ersek wrote:
> > I believe the series needs a few more (small) patches to update
> > the library resolutions (and other references) in DSC files that
> > become invalid due to the move:
> > 
> > $ git grep ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > ArmPkg/ArmPkg.dsc:  ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > ArmVirtPkg/ArmVirt.dsc.inc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> > BeagleBoardPkg/BeagleBoardPkg.dsc:  BaseMemoryLib|ArmPkg/Library/BaseMemoryLibStm/BaseMemoryLibStm.inf
> 
> Scratch that, the first patch does it already. Sorry for missing it; I
> got misled by the subject (MdePkg...) and I wasn't careful enough when
> looking at the diffstat. Sorry about the noise.

Yeah, sorry, commit message could have been clearer.
Even though master is already broken, my brain keeps going "don't
break bisect".

/
    Leif


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 15:23     ` Leif Lindholm
@ 2016-09-02 16:07       ` Ard Biesheuvel
  2016-09-02 18:05         ` Leif Lindholm
  0 siblings, 1 reply; 19+ messages in thread
From: Ard Biesheuvel @ 2016-09-02 16:07 UTC (permalink / raw)
  To: Leif Lindholm; +Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao

On 2 September 2016 at 16:23, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> On Fri, Sep 02, 2016 at 04:02:44PM +0100, Ard Biesheuvel wrote:
>> > On 2 sep. 2016, at 15:29, Leif Lindholm <leif.lindholm@linaro.org> wrote:
>> >
>> > Recent changes to the BaseMemoryLib implementations in MdePkg,
>> > and other changes dependent on these, left all ARM* platforms
>> > unbuildable. To avoid this sort of thing in the future, move
>> > the ARM* BaseMemoryLib implementations to the same locations
>> > as the other ones.
>>
>> Can't we just get rid of the stm version, and move everything to the
>> generic version? Copying all this crap into MdePkg does not seem
>> like an improvement to me at all.
>
> This isn't a proposed alternative to your patchset, this is an
> alternative to reverting all of the other BaseMemoryLib changes.
> I'm happy to throw it away next week if we can get something better in
> by then.
>
>> The AArch64 optdxe changes i proposed are arguably as harmless,
>
> Yes, but that leaves ARM broken.
>

Not necessarily. ARM can use the generic BaseMemoryLib in MdePkg

>> since they don't affect any other arch either. And the stm aarch64
>> versions are plain c to begin with
>
> And I want to discuss that next week. Against the backdrop of a
> working master branch.
>

My concern is that having an 'ARM' flavor of BaseMemoryLib in MdePkg/
will make it more difficult rather than easier to simply add ARM
support to the existing non-sse/mmx ones

Added the fact that the Stm is not in great shape, I would really
prefer to get rid of it rather than 'promote' it to the standard ARM
implementation. Note that we will need another round of updates to the
platform .DSCs when we remove the Stm version again.


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 16:07       ` Ard Biesheuvel
@ 2016-09-02 18:05         ` Leif Lindholm
  2016-09-02 18:11           ` Ard Biesheuvel
  0 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 18:05 UTC (permalink / raw)
  To: Ard Biesheuvel; +Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao

On Fri, Sep 02, 2016 at 05:07:48PM +0100, Ard Biesheuvel wrote:
> > This isn't a proposed alternative to your patchset, this is an
> > alternative to reverting all of the other BaseMemoryLib changes.
> > I'm happy to throw it away next week if we can get something better in
> > by then.
> >
> >> The AArch64 optdxe changes i proposed are arguably as harmless,
> >
> > Yes, but that leaves ARM broken.
> 
> Not necessarily. ARM can use the generic BaseMemoryLib in MdePkg

OK, but that's still yet another change.

> >> since they don't affect any other arch either. And the stm aarch64
> >> versions are plain c to begin with
> >
> > And I want to discuss that next week. Against the backdrop of a
> > working master branch.
> 
> My concern is that having an 'ARM' flavor of BaseMemoryLib in MdePkg/
> will make it more difficult rather than easier to simply add ARM
> support to the existing non-sse/mmx ones

I don't share that concern. I am entirely serious about nuking it next
week if we come to an agreement on a better solution.
And I'm happy to take on the drudgery of fixing up all the platforms.

(As a side note, this is an excellent example of why we need to
create reusable config fragments - fixing all ARM platforms to use the
correct library should be at most a two-liner in one place in edk2.)

> Added the fact that the Stm is not in great shape, I would really
> prefer to get rid of it rather than 'promote' it to the standard ARM
> implementation. Note that we will need another round of updates to the
> platform .DSCs when we remove the Stm version again.

My main concern is leaving the master branch unusable for ARM during
the Labor Day weekend. If we don't resolve this tonight, with the best
will in the world we won't be back to a functioning master before
Tuesday evening.

/
    Leif


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 18:05         ` Leif Lindholm
@ 2016-09-02 18:11           ` Ard Biesheuvel
  2016-09-02 18:32             ` Leif Lindholm
  0 siblings, 1 reply; 19+ messages in thread
From: Ard Biesheuvel @ 2016-09-02 18:11 UTC (permalink / raw)
  To: Leif Lindholm; +Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao

On 2 September 2016 at 19:05, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> On Fri, Sep 02, 2016 at 05:07:48PM +0100, Ard Biesheuvel wrote:
>> > This isn't a proposed alternative to your patchset, this is an
>> > alternative to reverting all of the other BaseMemoryLib changes.
>> > I'm happy to throw it away next week if we can get something better in
>> > by then.
>> >
>> >> The AArch64 optdxe changes i proposed are arguably as harmless,
>> >
>> > Yes, but that leaves ARM broken.
>>
>> Not necessarily. ARM can use the generic BaseMemoryLib in MdePkg
>
> OK, but that's still yet another change.
>
>> >> since they don't affect any other arch either. And the stm aarch64
>> >> versions are plain c to begin with
>> >
>> > And I want to discuss that next week. Against the backdrop of a
>> > working master branch.
>>
>> My concern is that having an 'ARM' flavor of BaseMemoryLib in MdePkg/
>> will make it more difficult rather than easier to simply add ARM
>> support to the existing non-sse/mmx ones
>
> I don't share that concern. I am entirely serious about nuking it next
> week if we come to an agreement on a better solution.
> And I'm happy to take on the drudgery of fixing up all the platforms.
>
> (As a side note, this is an excellent example of why we need to
> create reusable config fragments - fixing all ARM platforms to use the
> correct library should be at most a two-liner in one place in edk2.)
>
>> Added the fact that the Stm is not in great shape, I would really
>> prefer to get rid of it rather than 'promote' it to the standard ARM
>> implementation. Note that we will need another round of updates to the
>> platform .DSCs when we remove the Stm version again.
>
> My main concern is leaving the master branch unusable for ARM during
> the Labor Day weekend. If we don't resolve this tonight, with the best
> will in the world we won't be back to a functioning master before
> Tuesday evening.
>

I agree that fixing the branch now would be nice. I just don't
understand why fixing BaseMemoryLibStm in place is not a better
solution, especially if we are nuking it anyway next week. That way,
we have to change all the platforms only a single time.


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 18:11           ` Ard Biesheuvel
@ 2016-09-02 18:32             ` Leif Lindholm
  2016-09-02 18:45               ` Ard Biesheuvel
  0 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 18:32 UTC (permalink / raw)
  To: Ard Biesheuvel; +Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao

On Fri, Sep 02, 2016 at 07:11:02PM +0100, Ard Biesheuvel wrote:
> >> Added the fact that the Stm is not in great shape, I would really
> >> prefer to get rid of it rather than 'promote' it to the standard ARM
> >> implementation. Note that we will need another round of updates to the
> >> platform .DSCs when we remove the Stm version again.
> >
> > My main concern is leaving the master branch unusable for ARM during
> > the Labor Day weekend. If we don't resolve this tonight, with the best
> > will in the world we won't be back to a functioning master before
> > Tuesday evening.
> 
> I agree that fixing the branch now would be nice. I just don't
> understand why fixing BaseMemoryLibStm in place is not a better
> solution, especially if we are nuking it anyway next week. That way,
> we have to change all the platforms only a single time.

Mainly because we don't _know_ that it will be resolved next week and
I'm currently having some trust issues regarding these libraries.

If that's what it takes to get consensus, sure, I'll go along with
that. I'm fully aware I'm being slightly irrational here.

So where to now? Just push 2-3 from Wednesday?

/
    Leif


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 18:32             ` Leif Lindholm
@ 2016-09-02 18:45               ` Ard Biesheuvel
  2016-09-02 19:18                 ` Leif Lindholm
  0 siblings, 1 reply; 19+ messages in thread
From: Ard Biesheuvel @ 2016-09-02 18:45 UTC (permalink / raw)
  To: Leif Lindholm; +Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao


> On 2 sep. 2016, at 19:32, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> 
> On Fri, Sep 02, 2016 at 07:11:02PM +0100, Ard Biesheuvel wrote:
>>>> Added the fact that the Stm is not in great shape, I would really
>>>> prefer to get rid of it rather than 'promote' it to the standard ARM
>>>> implementation. Note that we will need another round of updates to the
>>>> platform .DSCs when we remove the Stm version again.
>>> 
>>> My main concern is leaving the master branch unusable for ARM during
>>> the Labor Day weekend. If we don't resolve this tonight, with the best
>>> will in the world we won't be back to a functioning master before
>>> Tuesday evening.
>> 
>> I agree that fixing the branch now would be nice. I just don't
>> understand why fixing BaseMemoryLibStm in place is not a better
>> solution, especially if we are nuking it anyway next week. That way,
>> we have to change all the platforms only a single time.
> 
> Mainly because we don't _know_ that it will be resolved next week and
> I'm currently having some trust issues regarding these libraries.
> 
> If that's what it takes to get consensus, sure, I'll go along with
> that. I'm fully aware I'm being slightly irrational here.
> 
> So where to now? Just push 2-3 from Wednesday?
> 

Yes, please. On Monday, I will look into adding Arm support to the optdxe flavor, and once that is in, we can move all platforms over and deprecate/remove the stm version.



^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 18:45               ` Ard Biesheuvel
@ 2016-09-02 19:18                 ` Leif Lindholm
  2016-09-02 19:24                   ` Laszlo Ersek
  0 siblings, 1 reply; 19+ messages in thread
From: Leif Lindholm @ 2016-09-02 19:18 UTC (permalink / raw)
  To: Ard Biesheuvel
  Cc: edk2-devel-01, Laszlo Ersek, Michael D Kinney, Liming Gao, afish

On Fri, Sep 02, 2016 at 07:45:26PM +0100, Ard Biesheuvel wrote:
> >> 
> >> I agree that fixing the branch now would be nice. I just don't
> >> understand why fixing BaseMemoryLibStm in place is not a better
> >> solution, especially if we are nuking it anyway next week. That way,
> >> we have to change all the platforms only a single time.
> > 
> > Mainly because we don't _know_ that it will be resolved next week and
> > I'm currently having some trust issues regarding these libraries.
> > 
> > If that's what it takes to get consensus, sure, I'll go along with
> > that. I'm fully aware I'm being slightly irrational here.
> > 
> > So where to now? Just push 2-3 from Wednesday?
> 
> Yes, please. On Monday, I will look into adding Arm support to the
> optdxe flavor, and once that is in, we can move all platforms over
> and deprecate/remove the stm version.

Allright - now pushed.

Mike, Andrew, apologies for the noise, and thank you for very quick
feedback.

/
    Leif



^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg
  2016-09-02 19:18                 ` Leif Lindholm
@ 2016-09-02 19:24                   ` Laszlo Ersek
  0 siblings, 0 replies; 19+ messages in thread
From: Laszlo Ersek @ 2016-09-02 19:24 UTC (permalink / raw)
  To: Leif Lindholm, Ard Biesheuvel
  Cc: edk2-devel-01, Michael D Kinney, Liming Gao, afish

On 09/02/16 21:18, Leif Lindholm wrote:
> On Fri, Sep 02, 2016 at 07:45:26PM +0100, Ard Biesheuvel wrote:
>>>>
>>>> I agree that fixing the branch now would be nice. I just don't
>>>> understand why fixing BaseMemoryLibStm in place is not a better
>>>> solution, especially if we are nuking it anyway next week. That way,
>>>> we have to change all the platforms only a single time.
>>>
>>> Mainly because we don't _know_ that it will be resolved next week and
>>> I'm currently having some trust issues regarding these libraries.
>>>
>>> If that's what it takes to get consensus, sure, I'll go along with
>>> that. I'm fully aware I'm being slightly irrational here.
>>>
>>> So where to now? Just push 2-3 from Wednesday?
>>
>> Yes, please. On Monday, I will look into adding Arm support to the
>> optdxe flavor, and once that is in, we can move all platforms over
>> and deprecate/remove the stm version.
> 
> Allright - now pushed.
> 
> Mike, Andrew, apologies for the noise, and thank you for very quick
> feedback.

Thanks everyone!

Laszlo



^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2016-09-02 19:24 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-02 14:29 [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Leif Lindholm
2016-09-02 14:29 ` [PATCH 1/3] MdePkg/Misc: Move ARM* BaseMemoryLibStm to MdePkg Leif Lindholm
2016-09-02 15:02   ` Ard Biesheuvel
2016-09-02 15:23     ` Leif Lindholm
2016-09-02 16:07       ` Ard Biesheuvel
2016-09-02 18:05         ` Leif Lindholm
2016-09-02 18:11           ` Ard Biesheuvel
2016-09-02 18:32             ` Leif Lindholm
2016-09-02 18:45               ` Ard Biesheuvel
2016-09-02 19:18                 ` Leif Lindholm
2016-09-02 19:24                   ` Laszlo Ersek
2016-09-02 14:29 ` [PATCH 2/3] MdePkg/BaseMemoryLibStm: implement new IsZeroGuid() API function Leif Lindholm
2016-09-02 14:29 ` [PATCH 3/3] MdePkg/BaseMemoryLibStm: implement new IsZeroBuffer() " Leif Lindholm
2016-09-02 14:48 ` [PATCH 0/3] MdePkg/Misc: fix Arm BaseMemoryLib Laszlo Ersek
2016-09-02 14:53   ` Laszlo Ersek
2016-09-02 16:02     ` Leif Lindholm
2016-09-02 15:49 ` Kinney, Michael D
2016-09-02 15:57   ` Leif Lindholm
2016-09-02 15:59     ` Andrew Fish

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox