Search Linux Wireless

[PATCH 12/16] staging: vt6656: s_vGenerateTxParameter remove else from if statements

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The function returns out at if statements so drop else.

Signed-off-by: Malcolm Priestley <tvboxspy@xxxxxxxxx>
---
 drivers/staging/vt6656/rxtx.c | 23 +++++++++--------------
 1 file changed, 9 insertions(+), 14 deletions(-)

diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c
index 6113807..0d0a956 100644
--- a/drivers/staging/vt6656/rxtx.c
+++ b/drivers/staging/vt6656/rxtx.c
@@ -717,25 +717,20 @@ static u16 s_vGenerateTxParameter(struct vnt_usb_send_context *tx_context,
 			return vnt_rxtx_rts(tx_context, &tx_buffer->tx_head,
 					byPktType, cbFrameSize, bNeedACK,
 						wCurrentRate, need_mic);
-		} else {
-			if (need_mic)
-				*mic_hdr = &tx_buffer->
-						tx_head.tx_cts.tx.mic.hdr;
-
-			return vnt_rxtx_cts(tx_context, &tx_buffer->tx_head,
-					byPktType, cbFrameSize, bNeedACK,
-						wCurrentRate, need_mic);
 		}
-	} else {
+
 		if (need_mic)
-			*mic_hdr = &tx_buffer->tx_head.tx_ab.tx.mic.hdr;
+			*mic_hdr = &tx_buffer->tx_head.tx_cts.tx.mic.hdr;
 
-		return vnt_rxtx_ab(tx_context, &tx_buffer->tx_head,
-					byPktType, cbFrameSize, bNeedACK,
-					wCurrentRate, need_rts, need_mic);
+		return vnt_rxtx_cts(tx_context, &tx_buffer->tx_head, byPktType,
+				cbFrameSize, bNeedACK, wCurrentRate, need_mic);
 	}
 
-	return 0;
+	if (need_mic)
+		*mic_hdr = &tx_buffer->tx_head.tx_ab.tx.mic.hdr;
+
+	return vnt_rxtx_ab(tx_context, &tx_buffer->tx_head, byPktType,
+		cbFrameSize, bNeedACK, wCurrentRate, need_rts, need_mic);
 }
 
 static void vnt_fill_txkey(struct vnt_usb_send_context *tx_context,
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux