Skip to content

Commit

Permalink
CryptoPkg: Enable Openssl Accel builds for AARCH64
Browse files Browse the repository at this point in the history
Enable the following modules builds for AARCH64:
- OpensslLibAccel.inf
- OpensslLibFullAccel.inf

Signed-off-by: Pierre Gondois <[email protected]>
  • Loading branch information
pierregondois authored and mergify[bot] committed Aug 1, 2024
1 parent 368f9b6 commit a679cec
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 18 deletions.
23 changes: 12 additions & 11 deletions CryptoPkg/CryptoPkg.dsc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
# Copyright (c) 2009 - 2022, Intel Corporation. All rights reserved.<BR>
# Copyright (c) 2020, Hewlett Packard Enterprise Development LP. All rights reserved.<BR>
# Copyright (c) 2022, Loongson Technology Corporation Limited. All rights reserved.<BR>
# Copyright (c) 2023, Arm Limited. All rights reserved.<BR>
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
##
Expand Down Expand Up @@ -327,7 +328,7 @@
MSFT:NOOPT_*_*_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /BASE:0x10000
}

[Components.IA32, Components.X64]
[Components.IA32, Components.X64, Components.AARCH64]
CryptoPkg/Test/UnitTest/Library/BaseCryptLib/TestBaseCryptLibShell.inf {
<Defines>
FILE_GUID = B91B9A95-4D52-4501-A98F-A1711C14ED93
Expand Down Expand Up @@ -396,9 +397,9 @@
TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf
}

[Components.IA32, Components.X64]
[Components.IA32, Components.X64, Components.AARCH64]
#
# Build verification of IA32/X64 specific libraries
# Build verification of IA32/X64/AARCH64 specific libraries
#
CryptoPkg/Library/OpensslLib/OpensslLibAccel.inf
CryptoPkg/Library/OpensslLib/OpensslLibFullAccel.inf
Expand Down Expand Up @@ -439,9 +440,9 @@
OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLibFull.inf
}

[Components.IA32, Components.X64]
[Components.IA32, Components.X64, Components.AARCH64]
#
# CryptoPei with IA32/X64 performance optimized OpensslLib instance without EC services
# CryptoPei with IA32/X64/AARCH64 performance optimized OpensslLib instance without EC services
# IA32/X64 assembly optimizations required larger alignments
#
CryptoPkg/Driver/CryptoPei.inf {
Expand All @@ -455,7 +456,7 @@
}

#
# CryptoPei with IA32/X64 performance optimized OpensslLib instance all services
# CryptoPei with IA32/X64/AARCH64 performance optimized OpensslLib instance all services
# IA32/X64 assembly optimizations required larger alignments
#
CryptoPkg/Driver/CryptoPei.inf {
Expand Down Expand Up @@ -505,9 +506,9 @@
OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLibFull.inf
}

[Components.IA32, Components.X64]
[Components.IA32, Components.X64, Components.AARCH64]
#
# CryptoDxe with IA32/X64 performance optimized OpensslLib instance with no EC services
# CryptoDxe with IA32/X64/AARCH64 performance optimized OpensslLib instance with no EC services
# with TLS feature enabled.
# IA32/X64 assembly optimizations required larger alignments
#
Expand All @@ -521,7 +522,7 @@
MSFT:*_*_X64_DLINK_FLAGS = /ALIGN:256
}
#
# CryptoDxe with IA32/X64 performance optimized OpensslLib instance with all services.
# CryptoDxe with IA32/X64/AARCH64 performance optimized OpensslLib instance with all services.
# IA32/X64 assembly optimizations required larger alignments
#
CryptoPkg/Driver/CryptoDxe.inf {
Expand Down Expand Up @@ -561,7 +562,7 @@
OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLibFull.inf
}
#
# CryptoSmm with IA32/X64 performance optimized OpensslLib instance with no EC services
# CryptoSmm with IA32/X64/AARCH64 performance optimized OpensslLib instance with no EC services
# IA32/X64 assembly optimizations required larger alignments
#
CryptoPkg/Driver/CryptoSmm.inf {
Expand All @@ -574,7 +575,7 @@
MSFT:*_*_X64_DLINK_FLAGS = /ALIGN:256
}
#
# CryptoSmm with IA32/X64 performance optimized OpensslLib instance with all services
# CryptoSmm with IA32/X64/AARCH64 performance optimized OpensslLib instance with all services
# IA32/X64 assembly optimizations required larger alignments
#
CryptoPkg/Driver/CryptoSmm.inf {
Expand Down
14 changes: 7 additions & 7 deletions CryptoPkg/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -246,13 +246,13 @@ specific set of enabled cryptographic services. If ECC services are not
required, then the size can be reduced by using OpensslLib.inf instead of
`OpensslLibFull.inf`. Performance optimization requires a size increase.

| OpensslLib Instance | SSL | ECC | Perf Opt | CPU Arch | Size |
|:------------------------|:---:|:---:|:--------:|:--------:|:-----:|
| OpensslLibCrypto.inf | N | N | N | All | +0K |
| OpensslLib.inf | Y | N | N | All | +0K |
| OpensslLibAccel.inf | Y | N | Y | IA32/X64 | +20K |
| OpensslLibFull.inf | Y | Y | N | All | +115K |
| OpensslLibFullAccel.inf | Y | Y | Y | IA32/X64 | +135K |
| OpensslLib Instance | SSL | ECC | Perf Opt | CPU Arch | Size |
|:------------------------|:---:|:---:|:--------:|:----------------:|:-----:|
| OpensslLibCrypto.inf | N | N | N | All | +0K |
| OpensslLib.inf | Y | N | N | All | +0K |
| OpensslLibAccel.inf | Y | N | Y | IA32/X64/AARCH64 | +20K |
| OpensslLibFull.inf | Y | Y | N | All | +115K |
| OpensslLibFullAccel.inf | Y | Y | Y | IA32/X64/AARCH64 | +135K |

### SEC Phase Library Mappings

Expand Down

0 comments on commit a679cec

Please sign in to comment.