staging: vt6656: desc.h remove typedef tagSTxDataHead_g_FB to new structure in rxtx.h
authorMalcolm Priestley <tvboxspy@gmail.com>
Fri, 16 Aug 2013 22:49:15 +0000 (23:49 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 19 Aug 2013 22:39:19 +0000 (15:39 -0700)
To new structure.
typedef struct tagSTxDataHead_g_FB -> struct vnt_tx_datahead_g_fb

This is only needed by rxtc.c so moved to rxtx.h visible to
vnt_rts*/vnt_cts* structures which it will eventually form part of
their structure.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/vt6656/desc.h
drivers/staging/vt6656/rxtx.c
drivers/staging/vt6656/rxtx.h

index b0cb8c430c5ca3a3313abd6280d27352125201ca..1ee0331757c545a84592c604c7f7613c8a68aa91 100644 (file)
@@ -166,23 +166,6 @@ typedef const STxShortBufHead *PCSTxShortBufHead;
 /*
  * TX data header
  */
-typedef struct tagSTxDataHead_g_FB {
-    u8    bySignalField_b;
-    u8    byServiceField_b;
-    u16    wTransmitLength_b;
-    u8    bySignalField_a;
-    u8    byServiceField_a;
-    u16    wTransmitLength_a;
-    u16    wDuration_b;
-    u16    wDuration_a;
-    u16    wDuration_a_f0;
-    u16    wDuration_a_f1;
-    u16    wTimeStampOff_b;
-    u16    wTimeStampOff_a;
-} __attribute__ ((__packed__))
-STxDataHead_g_FB, *PSTxDataHead_g_FB;
-typedef const STxDataHead_g_FB *PCSTxDataHead_g_FB;
-
 typedef struct tagSTxDataHead_ab {
     u8    bySignalField;
     u8    byServiceField;
index 585a2e327151ce841fc8e4cab063edaaa3f39bed..20c4656e03599e8ddf6ce36e009630b705ce0ad1 100644 (file)
@@ -535,7 +535,8 @@ static u32 s_uFillDataHead(struct vnt_private *pDevice,
                 return (pBuf->wDuration_a);
              } else {
                 // Auto Fallback
-                PSTxDataHead_g_FB pBuf = (PSTxDataHead_g_FB)pTxDataHead;
+               struct vnt_tx_datahead_g_fb *pBuf =
+                       (struct vnt_tx_datahead_g_fb *)pTxDataHead;
                 //Get SignalField,ServiceField,Length
                 BBvCalculateParameter(pDevice, cbFrameLength, wCurrentRate, byPktType,
                     (u16 *)&(pBuf->wTransmitLength_a), (u8 *)&(pBuf->byServiceField_a), (u8 *)&(pBuf->bySignalField_a)
@@ -1195,12 +1196,12 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType,
                pvRTS = (struct vnt_rts_g_fb *) (pbyTxBufferAddr + wTxBufSize +
                                sizeof(struct vnt_rrv_time_rts) + cbMICHDR);
                 pvCTS = NULL;
-               pvTxDataHd = (PSTxDataHead_g_FB) (pbyTxBufferAddr + wTxBufSize +
-                       sizeof(struct vnt_rrv_time_rts) + cbMICHDR +
-                                       sizeof(struct vnt_rts_g_fb));
+               pvTxDataHd = (struct vnt_tx_datahead_g_fb *) (pbyTxBufferAddr +
+                       wTxBufSize + sizeof(struct vnt_rrv_time_rts) +
+                               cbMICHDR + sizeof(struct vnt_rts_g_fb));
                cbHeaderLength = wTxBufSize + sizeof(struct vnt_rrv_time_rts) +
                        cbMICHDR + sizeof(struct vnt_rts_g_fb) +
-                               sizeof(STxDataHead_g_FB);
+                               sizeof(struct vnt_tx_datahead_g_fb);
             }
             else if (bRTS == false) { //RTS_needless
                pvRrvTime = (struct vnt_rrv_time_cts *)
@@ -1210,12 +1211,12 @@ static int s_bPacketToWirelessUsb(struct vnt_private *pDevice, u8 byPktType,
                 pvRTS = NULL;
                pvCTS = (struct vnt_cts_fb *) (pbyTxBufferAddr + wTxBufSize +
                        sizeof(struct vnt_rrv_time_cts) + cbMICHDR);
-               pvTxDataHd = (PSTxDataHead_g_FB) (pbyTxBufferAddr +
+               pvTxDataHd = (struct vnt_tx_datahead_g_fb *) (pbyTxBufferAddr +
                        wTxBufSize + sizeof(struct vnt_rrv_time_cts) +
                                cbMICHDR + sizeof(struct vnt_cts_fb));
                cbHeaderLength = wTxBufSize + sizeof(struct vnt_rrv_time_cts) +
                                cbMICHDR + sizeof(struct vnt_cts_fb) +
-                                       sizeof(STxDataHead_g_FB);
+                                       sizeof(struct vnt_tx_datahead_g_fb);
             }
         } // Auto Fall Back
     }
index 3c8262321795a054f01d6585213fe79f0558aa65..ba80271d11b41f8c4f8669d7fc7025cde0041595 100644 (file)
@@ -68,6 +68,21 @@ struct vnt_tx_datahead_g {
        u16 wTimeStampOff_a;
 } __packed;
 
+struct vnt_tx_datahead_g_fb {
+       u8 bySignalField_b;
+       u8 byServiceField_b;
+       u16 wTransmitLength_b;
+       u8 bySignalField_a;
+       u8 byServiceField_a;
+       u16 wTransmitLength_a;
+       u16 wDuration_b;
+       u16 wDuration_a;
+       u16 wDuration_a_f0;
+       u16 wDuration_a_f1;
+       u16 wTimeStampOff_b;
+       u16 wTimeStampOff_a;
+} __packed;
+
 /* RTS buffer header */
 struct vnt_rts_g {
        u8 bySignalField_b;