Messages in this thread | | | Date | Wed, 17 Dec 2008 16:56:46 +1100 | From | Herbert Xu <> | Subject | Re: [PATCH 2/2] crypto: salsa20 use endian access helpers |
| |
On Mon, Dec 08, 2008 at 05:26:36PM -0800, Harvey Harrison wrote: > > @@ -98,40 +91,51 @@ static void salsa20_wordtobyte(u8 output[64], const u32 input[16]) > for (i = 0; i < 16; ++i) > x[i] += input[i]; > for (i = 0; i < 16; ++i) > - U32TO8_LITTLE(output + 4 * i,x[i]); > + store_le32((__le32 *)(output + 4 * i), x[i]); > }
We need to mark output (i.e., buf) as aligned in the caller.
Otherwise the patch looks good to me.
Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
| |