mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 18:57:27 +02:00
Merge pull request #4799 from SparkiDev/file_gen_fixes
Generated files: fixes
This commit is contained in:
@ -1,6 +1,6 @@
|
|||||||
/* fe_448.c
|
/* fe_448.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2021 wolfSSL Inc.
|
* Copyright (C) 2006-2022 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* fe_x25519_128.i
|
/* fe_x25519_128.i
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2021 wolfSSL Inc.
|
* Copyright (C) 2006-2022 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
@ -19,6 +19,11 @@
|
|||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* Generated using (from wolfssl):
|
||||||
|
* cd ../scripts
|
||||||
|
* ruby ./x25519/fe_x25519_128_gen.rb > ../wolfssl/wolfcrypt/src/fe_x25519_128.i
|
||||||
|
*/
|
||||||
|
|
||||||
void fe_init(void)
|
void fe_init(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@ -189,9 +194,9 @@ void fe_copy(fe r, const fe a)
|
|||||||
|
|
||||||
/* Constant time, conditional swap of field elements a and b.
|
/* Constant time, conditional swap of field elements a and b.
|
||||||
*
|
*
|
||||||
* a A field element.
|
* f A field element.
|
||||||
* b A field element.
|
* g A field element.
|
||||||
* c If 1 then swap and if 0 then don't swap.
|
* b If 1 then swap and if 0 then don't swap.
|
||||||
*/
|
*/
|
||||||
void fe_cswap(fe f, fe g, int b)
|
void fe_cswap(fe f, fe g, int b)
|
||||||
{
|
{
|
||||||
@ -501,9 +506,9 @@ void fe_neg(fe r, const fe a)
|
|||||||
/* Constant time, conditional move of b into a.
|
/* Constant time, conditional move of b into a.
|
||||||
* a is not changed if the condition is 0.
|
* a is not changed if the condition is 0.
|
||||||
*
|
*
|
||||||
* a A field element.
|
* f A field element.
|
||||||
* b A field element.
|
* g A field element.
|
||||||
* c If 1 then copy and if 0 then don't copy.
|
* b If 1 then copy and if 0 then don't copy.
|
||||||
*/
|
*/
|
||||||
void fe_cmov(fe f, const fe g, int b)
|
void fe_cmov(fe f, const fe g, int b)
|
||||||
{
|
{
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* ge_448.c
|
/* ge_448.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2021 wolfSSL Inc.
|
* Copyright (C) 2006-2022 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -23,8 +23,13 @@
|
|||||||
* cd ../scripts
|
* cd ../scripts
|
||||||
* ruby ./x25519/x25519.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-curve25519.S
|
* ruby ./x25519/x25519.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-curve25519.S
|
||||||
*/
|
*/
|
||||||
#if defined(WOLFSSL_ARMASM) && defined(HAVE_CURVE25519)
|
|
||||||
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
|
||||||
|
#ifdef WOLFSSL_ARMASM
|
||||||
#ifndef __aarch64__
|
#ifndef __aarch64__
|
||||||
|
#ifdef HAVE_CURVE25519
|
||||||
|
|
||||||
.text
|
.text
|
||||||
.align 2
|
.align 2
|
||||||
.globl fe_init
|
.globl fe_init
|
||||||
@ -6007,8 +6012,10 @@ fe_ge_sub:
|
|||||||
add sp, sp, #0x60
|
add sp, sp, #0x60
|
||||||
pop {r4, r5, r6, r7, r8, r9, r10, r11, pc}
|
pop {r4, r5, r6, r7, r8, r9, r10, r11, pc}
|
||||||
.size fe_ge_sub,.-fe_ge_sub
|
.size fe_ge_sub,.-fe_ge_sub
|
||||||
|
|
||||||
|
#endif /* HAVE_CURVE25519 */
|
||||||
#endif /* !__aarch64__ */
|
#endif /* !__aarch64__ */
|
||||||
#endif /* WOLFSSL_ARMASM && HAVE_CURVE25519 */
|
#endif /* WOLFSSL_ARMASM */
|
||||||
|
|
||||||
#if defined(__linux__) && defined(__ELF__)
|
#if defined(__linux__) && defined(__ELF__)
|
||||||
.section .note.GNU-stack,"",%progbits
|
.section .note.GNU-stack,"",%progbits
|
||||||
|
@ -23,7 +23,10 @@
|
|||||||
* cd ../scripts
|
* cd ../scripts
|
||||||
* ruby ./x25519/x25519.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-curve25519.c
|
* ruby ./x25519/x25519.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-curve25519.c
|
||||||
*/
|
*/
|
||||||
#if defined(WOLFSSL_ARMASM) && defined(HAVE_CURVE25519)
|
|
||||||
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
|
||||||
|
#ifdef WOLFSSL_ARMASM
|
||||||
#ifndef __aarch64__
|
#ifndef __aarch64__
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
@ -32,6 +35,8 @@
|
|||||||
#include <wolfssl/wolfcrypt/settings.h>
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
#include <wolfssl/wolfcrypt/fe_operations.h>
|
#include <wolfssl/wolfcrypt/fe_operations.h>
|
||||||
|
|
||||||
|
#ifdef HAVE_CURVE25519
|
||||||
|
|
||||||
void fe_init()
|
void fe_init()
|
||||||
{
|
{
|
||||||
__asm__ __volatile__ (
|
__asm__ __volatile__ (
|
||||||
@ -5572,5 +5577,7 @@ void fe_ge_sub(fe rx, fe ry, fe rz, fe rt, const fe px, const fe py, const fe pz
|
|||||||
(void)qyminusx;
|
(void)qyminusx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* HAVE_CURVE25519 */
|
||||||
#endif /* !__aarch64__ */
|
#endif /* !__aarch64__ */
|
||||||
#endif /* WOLFSSL_ARMASM && HAVE_CURVE25519 */
|
#endif /* WOLFSSL_ARMASM */
|
||||||
|
@ -23,8 +23,12 @@
|
|||||||
* cd ../scripts
|
* cd ../scripts
|
||||||
* ruby ./sha2/sha512.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-sha512-asm.S
|
* ruby ./sha2/sha512.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-sha512-asm.S
|
||||||
*/
|
*/
|
||||||
#if defined(WOLFSSL_ARMASM) && defined(WOLFSSL_SHA512)
|
|
||||||
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
|
||||||
|
#ifdef WOLFSSL_ARMASM
|
||||||
#ifndef __aarch64__
|
#ifndef __aarch64__
|
||||||
|
#ifdef WOLFSSL_SHA512
|
||||||
#ifdef WOLFSSL_ARMASM_NO_NEON
|
#ifdef WOLFSSL_ARMASM_NO_NEON
|
||||||
.text
|
.text
|
||||||
.type L_SHA512_transform_len_k, %object
|
.type L_SHA512_transform_len_k, %object
|
||||||
@ -5330,8 +5334,9 @@ L_sha512_len_neon_start:
|
|||||||
bx lr
|
bx lr
|
||||||
.size Transform_Sha512_Len,.-Transform_Sha512_Len
|
.size Transform_Sha512_Len,.-Transform_Sha512_Len
|
||||||
#endif /* !WOLFSSL_ARMASM_NO_NEON */
|
#endif /* !WOLFSSL_ARMASM_NO_NEON */
|
||||||
|
#endif /* WOLFSSL_SHA512 */
|
||||||
#endif /* !__aarch64__ */
|
#endif /* !__aarch64__ */
|
||||||
#endif /* WOLFSSL_ARMASM && WOLFSSL_SHA512 */
|
#endif /* WOLFSSL_ARMASM */
|
||||||
|
|
||||||
#if defined(__linux__) && defined(__ELF__)
|
#if defined(__linux__) && defined(__ELF__)
|
||||||
.section .note.GNU-stack,"",%progbits
|
.section .note.GNU-stack,"",%progbits
|
||||||
|
@ -23,13 +23,17 @@
|
|||||||
* cd ../scripts
|
* cd ../scripts
|
||||||
* ruby ./sha2/sha512.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-sha512-asm.c
|
* ruby ./sha2/sha512.rb arm32 ../wolfssl/wolfcrypt/src/port/arm/armv8-32-sha512-asm.c
|
||||||
*/
|
*/
|
||||||
#if defined(WOLFSSL_ARMASM) && defined(WOLFSSL_SHA512)
|
|
||||||
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
|
||||||
|
#ifdef WOLFSSL_ARMASM
|
||||||
#ifndef __aarch64__
|
#ifndef __aarch64__
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#endif /* HAVE_CONFIG_H */
|
#endif /* HAVE_CONFIG_H */
|
||||||
#include <wolfssl/wolfcrypt/settings.h>
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
#ifdef WOLFSSL_SHA512
|
||||||
#include <wolfssl/wolfcrypt/sha512.h>
|
#include <wolfssl/wolfcrypt/sha512.h>
|
||||||
|
|
||||||
#ifdef WOLFSSL_ARMASM_NO_NEON
|
#ifdef WOLFSSL_ARMASM_NO_NEON
|
||||||
@ -4775,5 +4779,6 @@ void Transform_Sha512_Len(wc_Sha512* sha512, const byte* data, word32 len)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#endif /* !WOLFSSL_ARMASM_NO_NEON */
|
#endif /* !WOLFSSL_ARMASM_NO_NEON */
|
||||||
|
#endif /* WOLFSSL_SHA512 */
|
||||||
#endif /* !__aarch64__ */
|
#endif /* !__aarch64__ */
|
||||||
#endif /* WOLFSSL_ARMASM && WOLFSSL_SHA512 */
|
#endif /* WOLFSSL_ARMASM */
|
||||||
|
@ -147,6 +147,7 @@ static int InitSha512_256(wc_Sha512* sha512)
|
|||||||
#ifdef WOLFSSL_SHA512
|
#ifdef WOLFSSL_SHA512
|
||||||
|
|
||||||
#ifdef WOLFSSL_ARMASM
|
#ifdef WOLFSSL_ARMASM
|
||||||
|
#ifdef __aarch64__
|
||||||
#ifndef WOLFSSL_ARMASM_CRYPTO_SHA512
|
#ifndef WOLFSSL_ARMASM_CRYPTO_SHA512
|
||||||
extern void Transform_Sha512_Len_neon(wc_Sha512* sha512, const byte* data,
|
extern void Transform_Sha512_Len_neon(wc_Sha512* sha512, const byte* data,
|
||||||
word32 len);
|
word32 len);
|
||||||
@ -156,6 +157,10 @@ static int InitSha512_256(wc_Sha512* sha512)
|
|||||||
word32 len);
|
word32 len);
|
||||||
#define Transform_Sha512_Len Transform_Sha512_Len_crypto
|
#define Transform_Sha512_Len Transform_Sha512_Len_crypto
|
||||||
#endif
|
#endif
|
||||||
|
#else
|
||||||
|
extern void Transform_Sha512_Len(wc_Sha512* sha512, const byte* data,
|
||||||
|
word32 len);
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static int InitSha512_Family(wc_Sha512* sha512, void* heap, int devId,
|
static int InitSha512_Family(wc_Sha512* sha512, void* heap, int devId,
|
||||||
|
Reference in New Issue
Block a user