From f2117d84ef4ef02754b564dcb5badefb87c475f9 Mon Sep 17 00:00:00 2001 From: Enrico Pozzobon Date: Tue, 2 Jun 2020 13:24:44 +0200 Subject: [PATCH] drygascon128.add_arm_cortex-m - fixed some compilation issues --- drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v6m.S | 3 ++- drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m.S | 3 ++- drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu.S | 3 ++- drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu_x.S | 3 ++- drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/encrypt.c | 4 ++-- 5 files changed, 10 insertions(+), 6 deletions(-) diff --git a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v6m.S b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v6m.S index 930df1d..ddaaa5f 100644 --- a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v6m.S +++ b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v6m.S @@ -5,7 +5,8 @@ Sebastien Riou, May 27th 2020 Implementation optimized for ARM-Cortex-M0 (Size and Speed) */ -#if defined(__DRYGASCON_ARM_SELECTOR_H__) +#include "drygascon128_arm_selector.h" +#if defined(__DRYGASCON_ARM_SELECTOR_V6M__) .cpu cortex-m0 .syntax unified .code 16 diff --git a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m.S b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m.S index f0c5fa1..ac0b62e 100644 --- a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m.S +++ b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m.S @@ -22,7 +22,8 @@ the 'v7m_fpu_x' can be used to prevent this attack. Note that implementation 'v7m_fpu' is faster (but requires FPU). */ -#if defined(__DRYGASCON_ARM_SELECTOR_H__) +#include "drygascon128_arm_selector.h" +#if defined(__DRYGASCON_ARM_SELECTOR_V7M__) .cpu cortex-m3 .syntax unified .code 16 diff --git a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu.S b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu.S index d016dc8..326ba93 100644 --- a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu.S +++ b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu.S @@ -20,7 +20,8 @@ Reference manual) shows data cache lines of 16 bytes. - In the unlikely case in which none of the condition can be met, the 'v7m_fpu_x' can be used to prevent this attack. */ -#if defined(__DRYGASCON_ARM_SELECTOR_H__) +#include "drygascon128_arm_selector.h" +#if defined(__DRYGASCON_ARM_SELECTOR_FPU__) .cpu cortex-m3 .syntax unified .code 16 diff --git a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu_x.S b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu_x.S index 53472ea..6bf1cbc 100644 --- a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu_x.S +++ b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/drygascon128_arm-v7m_fpu_x.S @@ -7,7 +7,8 @@ Include protection against timing attack on X look up operations Note that implementation 'v7m_fpu' is faster and safe on all Cortex-M7 as of May 2020. */ -#if defined(__DRYGASCON_ARM_SELECTOR_H__) +#include "drygascon128_arm_selector.h" +#if defined(__DRYGASCON_ARM_SELECTOR_FPU_X__) .cpu cortex-m7 .syntax unified .code 16 diff --git a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/encrypt.c b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/encrypt.c index ca1e9f9..275b50f 100644 --- a/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/encrypt.c +++ b/drygascon/Implementations/crypto_aead/drygascon128/add_arm_cortex-m/encrypt.c @@ -8,7 +8,7 @@ int crypto_aead_encrypt const unsigned char *npub, const unsigned char *k) { - return drygascon128_aead_encrypt + return drygascon128k16_aead_encrypt (c, clen, m, mlen, ad, adlen, nsec, npub, k); } @@ -20,6 +20,6 @@ int crypto_aead_decrypt const unsigned char *npub, const unsigned char *k) { - return drygascon128_aead_decrypt + return drygascon128k16_aead_decrypt (m, mlen, nsec, c, clen, ad, adlen, npub, k); } -- libgit2 0.26.0