summaryrefslogtreecommitdiffstats
path: root/src/crypto/cipher/salsa20/xmm/salsa20_xmm.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/crypto/cipher/salsa20/xmm/salsa20_xmm.c')
-rw-r--r--src/crypto/cipher/salsa20/xmm/salsa20_xmm.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/crypto/cipher/salsa20/xmm/salsa20_xmm.c b/src/crypto/cipher/salsa20/xmm/salsa20_xmm.c
index 2025c98..1c8c721 100644
--- a/src/crypto/cipher/salsa20/xmm/salsa20_xmm.c
+++ b/src/crypto/cipher/salsa20/xmm/salsa20_xmm.c
@@ -42,17 +42,8 @@
#define KEYBYTES 32
-#ifdef __x86_64__
-#define crypto_stream_salsa20_xor crypto_stream_salsa20_amd64_xmm6_xor
-#endif
-
-#ifdef __i386__
-#define crypto_stream_salsa20_xor crypto_stream_salsa20_x86_xmm5_xor
-#endif
-
-
/** The actual Salsa20 assembly implementation */
-int crypto_stream_salsa20_xor(unsigned char *c, const unsigned char *m, unsigned long long mlen, const unsigned char *n, const unsigned char *k);
+int fastd_salsa20_xmm_xor(unsigned char *c, const unsigned char *m, unsigned long long mlen, const unsigned char *n, const unsigned char *k);
/** The cipher state */
@@ -76,7 +67,7 @@ static fastd_cipher_state_t * salsa20_init(const uint8_t *key) {
/** XORs data with the Salsa20 cipher stream */
static bool salsa20_crypt(const fastd_cipher_state_t *state, fastd_block128_t *out, const fastd_block128_t *in, size_t len, const uint8_t *iv) {
- crypto_stream_salsa20_xor(out->b, in->b, len, iv, state->key);
+ fastd_salsa20_xmm_xor(out->b, in->b, len, iv, state->key);
return true;
}