Commit 6398a59b authored by Malcolm Priestley's avatar Malcolm Priestley Committed by Greg Kroah-Hartman

staging: vt6656: desc.h: Move typedef tagSRrvTime_gRTS to new structure in rxtx.h

To new structure.
typedef struct tagSRrvTime_gRTS -> struct vnt_rrv_time_rts

This is only needed by rxtc.c so moved to rxtx.h and
will eventually form part of the structure of
struct vnt_tx_buffer.
Signed-off-by: default avatarMalcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ce9c1cef
...@@ -146,18 +146,6 @@ ...@@ -146,18 +146,6 @@
/* /*
* RsvTime buffer header * RsvTime buffer header
*/ */
typedef struct tagSRrvTime_gRTS {
u16 wRTSTxRrvTime_ba;
u16 wRTSTxRrvTime_aa;
u16 wRTSTxRrvTime_bb;
u16 wReserved;
u16 wTxRrvTime_b;
u16 wTxRrvTime_a;
} __attribute__ ((__packed__))
SRrvTime_gRTS, *PSRrvTime_gRTS;
typedef const SRrvTime_gRTS *PCSRrvTime_gRTS;
typedef struct tagSRrvTime_gCTS { typedef struct tagSRrvTime_gCTS {
u16 wCTSTxRrvTime_ba; u16 wCTSTxRrvTime_ba;
u16 wReserved; u16 wReserved;
......
...@@ -919,7 +919,8 @@ static void s_vGenerateTxParameter(struct vnt_private *pDevice, ...@@ -919,7 +919,8 @@ static void s_vGenerateTxParameter(struct vnt_private *pDevice,
if (pvRTS != NULL) { //RTS_need if (pvRTS != NULL) { //RTS_need
//Fill RsvTime //Fill RsvTime
if (pvRrvTime) { if (pvRrvTime) {
PSRrvTime_gRTS pBuf = (PSRrvTime_gRTS)pvRrvTime; struct vnt_rrv_time_rts *pBuf =
(struct vnt_rrv_time_rts *)pvRrvTime;
pBuf->wRTSTxRrvTime_aa = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 2, byPktType, cbFrameSize, wCurrentRate));//2:RTSTxRrvTime_aa, 1:2.4GHz pBuf->wRTSTxRrvTime_aa = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 2, byPktType, cbFrameSize, wCurrentRate));//2:RTSTxRrvTime_aa, 1:2.4GHz
pBuf->wRTSTxRrvTime_ba = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 1, byPktType, cbFrameSize, wCurrentRate));//1:RTSTxRrvTime_ba, 1:2.4GHz pBuf->wRTSTxRrvTime_ba = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 1, byPktType, cbFrameSize, wCurrentRate));//1:RTSTxRrvTime_ba, 1:2.4GHz
pBuf->wRTSTxRrvTime_bb = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 0, byPktType, cbFrameSize, wCurrentRate));//0:RTSTxRrvTime_bb, 1:2.4GHz pBuf->wRTSTxRrvTime_bb = cpu_to_le16((u16)s_uGetRTSCTSRsvTime(pDevice, 0, byPktType, cbFrameSize, wCurrentRate));//0:RTSTxRrvTime_bb, 1:2.4GHz
...@@ -1149,15 +1150,17 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType, ...@@ -1149,15 +1150,17 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType,
if (byPktType == PK_TYPE_11GB || byPktType == PK_TYPE_11GA) {//802.11g packet if (byPktType == PK_TYPE_11GB || byPktType == PK_TYPE_11GA) {//802.11g packet
if (byFBOption == AUTO_FB_NONE) { if (byFBOption == AUTO_FB_NONE) {
if (bRTS == true) {//RTS_need if (bRTS == true) {//RTS_need
pvRrvTime = (PSRrvTime_gRTS) (pbyTxBufferAddr + wTxBufSize); pvRrvTime = (struct vnt_rrv_time_rts *)
pMICHDR = (PSMICHDRHead) (pbyTxBufferAddr + wTxBufSize + sizeof(SRrvTime_gRTS)); (pbyTxBufferAddr + wTxBufSize);
pMICHDR = (PSMICHDRHead)(pbyTxBufferAddr + wTxBufSize +
sizeof(struct vnt_rrv_time_rts));
pvRTS = (struct vnt_rts_g *) (pbyTxBufferAddr + wTxBufSize + pvRTS = (struct vnt_rts_g *) (pbyTxBufferAddr + wTxBufSize +
sizeof(SRrvTime_gRTS) + cbMICHDR); sizeof(struct vnt_rrv_time_rts) + cbMICHDR);
pvCTS = NULL; pvCTS = NULL;
pvTxDataHd = (PSTxDataHead_g) (pbyTxBufferAddr + wTxBufSize + pvTxDataHd = (PSTxDataHead_g) (pbyTxBufferAddr + wTxBufSize +
sizeof(SRrvTime_gRTS) + cbMICHDR + sizeof(struct vnt_rrv_time_rts) + cbMICHDR +
sizeof(struct vnt_rts_g)); sizeof(struct vnt_rts_g));
cbHeaderLength = wTxBufSize + sizeof(SRrvTime_gRTS) + cbHeaderLength = wTxBufSize + sizeof(struct vnt_rrv_time_rts) +
cbMICHDR + sizeof(struct vnt_rts_g) + cbMICHDR + sizeof(struct vnt_rts_g) +
sizeof(STxDataHead_g); sizeof(STxDataHead_g);
} }
...@@ -1176,16 +1179,19 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType, ...@@ -1176,16 +1179,19 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType,
} else { } else {
// Auto Fall Back // Auto Fall Back
if (bRTS == true) {//RTS_need if (bRTS == true) {//RTS_need
pvRrvTime = (PSRrvTime_gRTS) (pbyTxBufferAddr + wTxBufSize); pvRrvTime = (struct vnt_rrv_time_rts *)(pbyTxBufferAddr +
pMICHDR = (PSMICHDRHead) (pbyTxBufferAddr + wTxBufSize + sizeof(SRrvTime_gRTS)); wTxBufSize);
pMICHDR = (PSMICHDRHead) (pbyTxBufferAddr + wTxBufSize +
sizeof(struct vnt_rrv_time_rts));
pvRTS = (struct vnt_rts_g_fb *) (pbyTxBufferAddr + wTxBufSize + pvRTS = (struct vnt_rts_g_fb *) (pbyTxBufferAddr + wTxBufSize +
sizeof(SRrvTime_gRTS) + cbMICHDR); sizeof(struct vnt_rrv_time_rts) + cbMICHDR);
pvCTS = NULL; pvCTS = NULL;
pvTxDataHd = (PSTxDataHead_g_FB) (pbyTxBufferAddr + wTxBufSize + pvTxDataHd = (PSTxDataHead_g_FB) (pbyTxBufferAddr + wTxBufSize +
sizeof(SRrvTime_gRTS) + cbMICHDR + sizeof(struct vnt_rrv_time_rts) + cbMICHDR +
sizeof(struct vnt_rts_g_fb)); sizeof(struct vnt_rts_g_fb));
cbHeaderLength = wTxBufSize + sizeof(SRrvTime_gRTS) + cbMICHDR + cbHeaderLength = wTxBufSize + sizeof(struct vnt_rrv_time_rts) +
sizeof(struct vnt_rts_g_fb) + sizeof(STxDataHead_g_FB); cbMICHDR + sizeof(struct vnt_rts_g_fb) +
sizeof(STxDataHead_g_FB);
} }
else if (bRTS == false) { //RTS_needless else if (bRTS == false) { //RTS_needless
pvRrvTime = (PSRrvTime_gCTS) (pbyTxBufferAddr + wTxBufSize); pvRrvTime = (PSRrvTime_gCTS) (pbyTxBufferAddr + wTxBufSize);
......
...@@ -32,6 +32,16 @@ ...@@ -32,6 +32,16 @@
#include "device.h" #include "device.h"
#include "wcmd.h" #include "wcmd.h"
/* RsvTime buffer header */
struct vnt_rrv_time_rts {
u16 wRTSTxRrvTime_ba;
u16 wRTSTxRrvTime_aa;
u16 wRTSTxRrvTime_bb;
u16 wReserved;
u16 wTxRrvTime_b;
u16 wTxRrvTime_a;
} __packed;
/* RTS buffer header */ /* RTS buffer header */
struct vnt_rts_g { struct vnt_rts_g {
u8 bySignalField_b; u8 bySignalField_b;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment