X-Git-Url: https://git.cryptolib.org/?a=blobdiff_plain;ds=sidebyside;f=keccak%2Frotate64.h;h=22593de62a4b6f78f89603145b67f7c30309c389;hb=1f6be6ce98d01772fbb1f4d5205a13bea896a1f1;hp=a80d2b5e39025afa7f1f85fa9593a7cf1a5692ab;hpb=701d813c99a7bd164e98f82c5651e6e7bdab404a;p=avr-crypto-lib.git diff --git a/keccak/rotate64.h b/keccak/rotate64.h index a80d2b5..22593de 100644 --- a/keccak/rotate64.h +++ b/keccak/rotate64.h @@ -1,7 +1,7 @@ /* rotate64.h */ /* This file is part of the AVR-Crypto-Lib. - Copyright (C) 2010 Daniel Otte (daniel.otte@rub.de) + Copyright (C) 2006-2015 Daniel Otte (bg@nerilex.org) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -33,13 +33,6 @@ #define ROTR_3 (8+3) -#define ROT_BIT(a) (((a) <= 4) ? ((a) << 1) : (0x01 | ((8 - (a)) << 1))) - -//#define ROT_CODE(a,b) (((a)<<4) | ((b)&0x0f)) - -#define ROT_CODE(a) ((((a) / 8 + ((((a) % 8) > 4) ? 1 : 0)) << 4) | ROT_BIT(((a) % 8))) -//#define ROT_CODE(a) ((((a)/8)<<4) | ((a)%8)) /* rotations only to the left */ - uint64_t rotate64_1bit_left(uint64_t a); uint64_t rotate64_1bit_right(uint64_t a); uint64_t rotate64_nbit_autodir(uint64_t a, int8_t n);