Merge branch 'upstream' into upstream-jgarzik

Conflicts:

	net/ieee80211/softmac/ieee80211softmac_module.c
	net/ieee80211/softmac/ieee80211softmac_wx.c
This commit is contained in:
John W. Linville
2007-02-17 18:26:09 -05:00
18 changed files with 157 additions and 185 deletions

View File

@@ -1623,7 +1623,7 @@ static void emmh32_setseed(emmh32_context *context, u8 *pkey, int keylen,
crypto_cipher_setkey(tfm, pkey, 16);
counter = 0;
for (i = 0; i < (sizeof(context->coeff)/sizeof(context->coeff[0])); ) {
for (i = 0; i < ARRAY_SIZE(context->coeff); ) {
aes_counter[15] = (u8)(counter >> 0);
aes_counter[14] = (u8)(counter >> 8);
aes_counter[13] = (u8)(counter >> 16);
@@ -1632,7 +1632,7 @@ static void emmh32_setseed(emmh32_context *context, u8 *pkey, int keylen,
memcpy (plain, aes_counter, 16);
crypto_cipher_encrypt_one(tfm, plain, plain);
cipher = plain;
for (j=0; (j<16) && (i< (sizeof(context->coeff)/sizeof(context->coeff[0]))); ) {
for (j = 0; (j < 16) && (i < ARRAY_SIZE(context->coeff)); ) {
context->coeff[i++] = ntohl(*(u32 *)&cipher[j]);
j += 4;
}