Staging: add w35und wifi driver
[linux-2.6/mini2440.git] / drivers / staging / winbond / ds_tkip.h
blob29e5055b45a1ef59ebb200f907cce873dd806793
1 // Rotation functions on 32 bit values
2 #define ROL32( A, n ) \
3 ( ((A) << (n)) | ( ((A)>>(32-(n))) & ( (1UL << (n)) - 1 ) ) )
5 #define ROR32( A, n ) ROL32( (A), 32-(n) )
8 typedef struct tkip
10 u32 K0, K1; // Key
11 union
13 struct // Current state
15 u32 L;
16 u32 R;
18 u8 LR[8];
20 union
22 u32 M; // Message accumulator (single word)
23 u8 Mb[4];
25 s32 bytes_in_M; // # bytes in M
26 } tkip_t;
28 //void _append_data( PUCHAR pData, u16 size, tkip_t *p );
29 void Mds_MicGet( void* Adapter, void* pRxLayer1, PUCHAR pKey, PUCHAR pMic );
30 void Mds_MicFill( void* Adapter, void* pDes, PUCHAR XmitBufAddress );