Staging: rtl8192u: ieee80211: corrected block comments
This patch reformats some block comments in order to match the Linux kernel coding style. Signed-off-by: Kurt Kanzenbach <kurt@kmk-computers.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
7bdb7d554e
commit
e1cb1af28a
|
@ -256,8 +256,10 @@ static void tkip_mixing_phase1(u16 *TTAK, const u8 *TK, const u8 *TA, u32 IV32)
|
|||
static void tkip_mixing_phase2(u8 *WEPSeed, const u8 *TK, const u16 *TTAK,
|
||||
u16 IV16)
|
||||
{
|
||||
/* Make temporary area overlap WEP seed so that the final copy can be
|
||||
* avoided on little endian hosts. */
|
||||
/*
|
||||
* Make temporary area overlap WEP seed so that the final copy can be
|
||||
* avoided on little endian hosts.
|
||||
*/
|
||||
u16 *PPK = (u16 *) &WEPSeed[4];
|
||||
|
||||
/* Step 1 - make copy of TTAK and bring in TSC */
|
||||
|
@ -283,8 +285,10 @@ static void tkip_mixing_phase2(u8 *WEPSeed, const u8 *TK, const u16 *TTAK,
|
|||
PPK[4] += RotR1(PPK[3]);
|
||||
PPK[5] += RotR1(PPK[4]);
|
||||
|
||||
/* Step 3 - bring in last of TK bits, assign 24-bit WEP IV value
|
||||
* WEPSeed[0..2] is transmitted as WEP IV */
|
||||
/*
|
||||
* Step 3 - bring in last of TK bits, assign 24-bit WEP IV value
|
||||
* WEPSeed[0..2] is transmitted as WEP IV
|
||||
*/
|
||||
WEPSeed[0] = Hi8(IV16);
|
||||
WEPSeed[1] = (Hi8(IV16) | 0x20) & 0x7F;
|
||||
WEPSeed[2] = Lo8(IV16);
|
||||
|
@ -463,8 +467,11 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv)
|
|||
|
||||
if (memcmp(icv, pos + plen, 4) != 0) {
|
||||
if (iv32 != tkey->rx_iv32) {
|
||||
/* Previously cached Phase1 result was already lost, so
|
||||
* it needs to be recalculated for the next packet. */
|
||||
/*
|
||||
* Previously cached Phase1 result was already
|
||||
* lost, so it needs to be recalculated for the
|
||||
* next packet.
|
||||
*/
|
||||
tkey->rx_phase1_done = 0;
|
||||
}
|
||||
if (net_ratelimit()) {
|
||||
|
@ -477,8 +484,10 @@ static int ieee80211_tkip_decrypt(struct sk_buff *skb, int hdr_len, void *priv)
|
|||
|
||||
}
|
||||
|
||||
/* Update real counters only after Michael MIC verification has
|
||||
* completed */
|
||||
/*
|
||||
* Update real counters only after Michael MIC verification has
|
||||
* completed.
|
||||
*/
|
||||
tkey->rx_iv32_new = iv32;
|
||||
tkey->rx_iv16_new = iv16;
|
||||
|
||||
|
@ -633,8 +642,10 @@ static int ieee80211_michael_mic_verify(struct sk_buff *skb, int keyidx,
|
|||
return -1;
|
||||
}
|
||||
|
||||
/* Update TSC counters for RX now that the packet verification has
|
||||
* completed. */
|
||||
/*
|
||||
* Update TSC counters for RX now that the packet verification has
|
||||
* completed.
|
||||
*/
|
||||
tkey->rx_iv32 = tkey->rx_iv32_new;
|
||||
tkey->rx_iv16 = tkey->rx_iv16_new;
|
||||
|
||||
|
|
Loading…
Reference in New Issue