From 8ef805817cb3c8ff80526702d2bcfb3cb642dcb2 Mon Sep 17 00:00:00 2001 From: Steffen Jaeckel Date: Wed, 24 May 2017 21:36:15 +0200 Subject: [PATCH] rename time_cipher[2-4]? appropriately --- demos/timing.c | 8 ++++---- testprof/timing_test.c | 18 +++++++++--------- testprof/tomcrypt_test.h | 8 ++++---- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/demos/timing.c b/demos/timing.c index 5cc23fc..8d525ea 100644 --- a/demos/timing.c +++ b/demos/timing.c @@ -18,10 +18,10 @@ register_algs(); #endif time_keysched(); -time_cipher(); -time_cipher2(); -time_cipher3(); -time_cipher4(); +time_cipher_ecb(); +time_cipher_cbc(); +time_cipher_ctr(); +time_cipher_lrw(); time_hash(); time_macs(); time_encmacs(); diff --git a/testprof/timing_test.c b/testprof/timing_test.c index 03f4003..ec61e92 100644 --- a/testprof/timing_test.c +++ b/testprof/timing_test.c @@ -154,7 +154,7 @@ int time_keysched(void) } #ifdef LTC_ECB_MODE -int time_cipher(void) +int time_cipher_ecb(void) { unsigned long x, y1; ulong64 t1, t2, c1, c2, a1, a2; @@ -225,11 +225,11 @@ int time_cipher(void) return 0; } #else -int time_cipher(void) { fprintf(stderr, "NO ECB\n"); return 0; } +int time_cipher_ecb(void) { fprintf(stderr, "NO ECB\n"); return 0; } #endif #ifdef LTC_CBC_MODE -int time_cipher2(void) +int time_cipher_cbc(void) { unsigned long x, y1; ulong64 t1, t2, c1, c2, a1, a2; @@ -300,11 +300,11 @@ int time_cipher2(void) return 0; } #else -int time_cipher2(void) { fprintf(stderr, "NO CBC\n"); return 0; } +int time_cipher_cbc(void) { fprintf(stderr, "NO CBC\n"); return 0; } #endif #ifdef LTC_CTR_MODE -int time_cipher3(void) +int time_cipher_ctr(void) { unsigned long x, y1; ulong64 t1, t2, c1, c2, a1, a2; @@ -375,11 +375,11 @@ int time_cipher3(void) return 0; } #else -int time_cipher3(void) { fprintf(stderr, "NO CTR\n"); return 0; } +int time_cipher_ctr(void) { fprintf(stderr, "NO CTR\n"); return 0; } #endif #ifdef LTC_LRW_MODE -int time_cipher4(void) +int time_cipher_lrw(void) { unsigned long x, y1; ulong64 t1, t2, c1, c2, a1, a2; @@ -452,7 +452,7 @@ int time_cipher4(void) return 0; } #else -int time_cipher4(void) { fprintf(stderr, "NO LRW\n"); return 0; } +int time_cipher_lrw(void) { fprintf(stderr, "NO LRW\n"); return 0; } #endif @@ -1155,7 +1155,7 @@ void time_macs(void) time_macs_(32); } -void time_encmacs_(unsigned long MAC_SIZE) +static void time_encmacs_(unsigned long MAC_SIZE) { #if defined(LTC_EAX_MODE) || defined(LTC_OCB_MODE) || defined(LTC_OCB3_MODE) || defined(LTC_CCM_MODE) || defined(LTC_GCM_MODE) unsigned char *buf, IV[16], key[16], tag[16]; diff --git a/testprof/tomcrypt_test.h b/testprof/tomcrypt_test.h index 59745b9..1c4b309 100644 --- a/testprof/tomcrypt_test.h +++ b/testprof/tomcrypt_test.h @@ -77,10 +77,10 @@ void init_timer(void); /* register default algs */ int time_keysched(void); -int time_cipher(void); -int time_cipher2(void); -int time_cipher3(void); -int time_cipher4(void); +int time_cipher_ecb(void); +int time_cipher_cbc(void); +int time_cipher_ctr(void); +int time_cipher_lrw(void); int time_hash(void); void time_mult(void); void time_sqr(void);