staging: vt6656: Replace typedef struct _CMD_CARD_INIT
authorMalcolm Priestley <tvboxspy@gmail.com>
Sun, 3 Nov 2013 17:43:23 +0000 (17:43 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Nov 2013 00:32:00 +0000 (16:32 -0800)
Replace with struct vnt_cmd_card_init init_cmd in
device_init_registers.

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

index 297dd109631c8b60b03f9d5652664e9d75f57fcd..fd8dfe9710541a9ff0e4a6796f655a5f9daa6a59 100644 (file)
@@ -299,13 +299,13 @@ static void device_init_diversity_timer(struct vnt_private *pDevice)
 static int device_init_registers(struct vnt_private *pDevice)
 {
        struct vnt_manager *pMgmt = &pDevice->vnt_mgmt;
+       struct vnt_cmd_card_init init_cmd;
        u8 abyBroadcastAddr[ETH_ALEN] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};
        u8 abySNAP_RFC1042[ETH_ALEN] = {0xaa, 0xaa, 0x03, 0x00, 0x00, 0x00};
        u8 abySNAP_Bridgetunnel[ETH_ALEN]
                = {0xaa, 0xaa, 0x03, 0x00, 0x00, 0xf8};
        u8 byAntenna;
        int ii;
-       CMD_CARD_INIT sInitCmd;
        int ntStatus = STATUS_SUCCESS;
        RSP_CARD_INIT   sInitRsp;
        u8 byTmp;
@@ -343,20 +343,17 @@ static int device_init_registers(struct vnt_private *pDevice)
             return false;
         }
 
-    sInitCmd.byInitClass = DEVICE_INIT_COLD;
-    sInitCmd.bExistSWNetAddr = (u8) pDevice->bExistSWNetAddr;
-    for (ii = 0; ii < 6; ii++)
-       sInitCmd.bySWNetAddr[ii] = pDevice->abyCurrentNetAddr[ii];
-    sInitCmd.byShortRetryLimit = pDevice->byShortRetryLimit;
-    sInitCmd.byLongRetryLimit = pDevice->byLongRetryLimit;
-
-    /* issue card_init command to device */
-    ntStatus = CONTROLnsRequestOut(pDevice,
-                                    MESSAGE_TYPE_CARDINIT,
-                                    0,
-                                    0,
-                                    sizeof(CMD_CARD_INIT),
-                                    (u8 *) &(sInitCmd));
+       init_cmd.init_class = DEVICE_INIT_COLD;
+       init_cmd.exist_sw_net_addr = (u8) pDevice->bExistSWNetAddr;
+       for (ii = 0; ii < 6; ii++)
+               init_cmd.sw_net_addr[ii] = pDevice->abyCurrentNetAddr[ii];
+       init_cmd.short_retry_limit = pDevice->byShortRetryLimit;
+       init_cmd.long_retry_limit = pDevice->byLongRetryLimit;
+
+       /* issue card_init command to device */
+       ntStatus = CONTROLnsRequestOut(pDevice,
+               MESSAGE_TYPE_CARDINIT, 0, 0,
+               sizeof(struct vnt_cmd_card_init), (u8 *)&init_cmd);
 
     if ( ntStatus != STATUS_SUCCESS ) {
         DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO" Issue Card init fail \n");
index 5e073062017a2e657e1f0b33ebddcaa1d2fa21c4..5dcc4b4007a3eb4af38066e8d7e7563b24469bf1 100644 (file)
@@ -77,14 +77,14 @@ typedef struct _CMD_WRITE_MASK
     u8        byMask;
 } CMD_WRITE_MASK, *PCMD_WRITE_MASK;
 
-typedef struct _CMD_CARD_INIT
+struct vnt_cmd_card_init
 {
-    u8        byInitClass;
-    u8        bExistSWNetAddr;
-    u8        bySWNetAddr[6];
-    u8        byShortRetryLimit;
-    u8        byLongRetryLimit;
-} CMD_CARD_INIT, *PCMD_CARD_INIT;
+       u8 init_class;
+       u8 exist_sw_net_addr;
+       u8 sw_net_addr[6];
+       u8 short_retry_limit;
+       u8 long_retry_limit;
+};
 
 typedef struct _RSP_CARD_INIT
 {