All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] QLGE: qlge_main: Fix style
@ 2021-12-01 14:39 Adam Kandur
  2021-12-01 14:53 ` Greg KH
  2021-12-03  8:14 ` Dan Carpenter
  0 siblings, 2 replies; 4+ messages in thread
From: Adam Kandur @ 2021-12-01 14:39 UTC (permalink / raw)
  To: netdev; +Cc: linux-staging, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2 bytes --]




[-- Attachment #2: 0001-QLGE-qlge_main-Fix-style.patch --]
[-- Type: application/octet-stream, Size: 2626 bytes --]

From 41266a72ae2ad8fb45e96e455c519177bfd23bc0 Mon Sep 17 00:00:00 2001
From: Adam Kandur <rndd@tuta.io>
Date: Wed, 1 Dec 2021 17:32:11 +0300
Subject: [PATCH] QLGE: qlge_main: Fix style

---
 drivers/staging/qlge/qlge_main.c | 28 +++++++++++++---------------
 1 file changed, 13 insertions(+), 15 deletions(-)

diff --git a/drivers/staging/qlge/qlge_main.c b/drivers/staging/qlge/qlge_main.c
index 9873bb2a9..c86e2a936 100644
--- a/drivers/staging/qlge/qlge_main.c
+++ b/drivers/staging/qlge/qlge_main.c
@@ -1200,11 +1200,11 @@ static void qlge_unmap_send(struct qlge_adapter *qdev,
 			 * element and there is more than 6 frags,
 			 * then its an OAL.
 			 */
-			if (i == 7) {
+			if (i == 7)
 				netif_printk(qdev, tx_done, KERN_DEBUG,
 					     qdev->ndev,
 					     "unmapping OAL area.\n");
-			}
+
 			dma_unmap_single(&qdev->pdev->dev,
 					 dma_unmap_addr(&tx_ring_desc->map[i],
 							mapaddr),
@@ -1236,10 +1236,10 @@ static int qlge_map_send(struct qlge_adapter *qdev,
 	struct tx_buf_desc *tbd = mac_iocb_ptr->tbd;
 	int frag_cnt = skb_shinfo(skb)->nr_frags;
 
-	if (frag_cnt) {
+	if (frag_cnt)
 		netif_printk(qdev, tx_queued, KERN_DEBUG, qdev->ndev,
 			     "frag_cnt = %d.\n", frag_cnt);
-	}
+
 	/*
 	 * Map the skb buffer first.
 	 */
@@ -3351,12 +3351,11 @@ static void qlge_free_irq(struct qlge_adapter *qdev)
 
 	for (i = 0; i < qdev->intr_count; i++, intr_context++) {
 		if (intr_context->hooked) {
-			if (test_bit(QL_MSIX_ENABLED, &qdev->flags)) {
+			if (test_bit(QL_MSIX_ENABLED, &qdev->flags))
 				free_irq(qdev->msi_x_entry[i].vector,
 					 &qdev->rx_ring[i]);
-			} else {
+			else
 				free_irq(qdev->pdev->irq, &qdev->rx_ring[0]);
-			}
 		}
 	}
 	qlge_disable_msix(qdev);
@@ -4128,22 +4127,21 @@ static void qlge_set_multicast_list(struct net_device *ndev)
 	if (ndev->flags & IFF_PROMISC) {
 		if (!test_bit(QL_PROMISCUOUS, &qdev->flags)) {
 			if (qlge_set_routing_reg
-			    (qdev, RT_IDX_PROMISCUOUS_SLOT, RT_IDX_VALID, 1)) {
+			    (qdev, RT_IDX_PROMISCUOUS_SLOT, RT_IDX_VALID, 1))
 				netif_err(qdev, hw, qdev->ndev,
 					  "Failed to set promiscuous mode.\n");
-			} else {
+			else
 				set_bit(QL_PROMISCUOUS, &qdev->flags);
-			}
-		}
 	} else {
 		if (test_bit(QL_PROMISCUOUS, &qdev->flags)) {
-			if (qlge_set_routing_reg
-			    (qdev, RT_IDX_PROMISCUOUS_SLOT, RT_IDX_VALID, 0)) {
+			if (qlge_set_routing_reg (qdev,
+						  RT_IDX_PROMISCUOUS_SLOT,
+						  RT_IDX_VALID,
+						  0))
 				netif_err(qdev, hw, qdev->ndev,
 					  "Failed to clear promiscuous mode.\n");
-			} else {
+			else
 				clear_bit(QL_PROMISCUOUS, &qdev->flags);
-			}
 		}
 	}
 
-- 
2.34.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-12-03  9:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-01 14:39 [PATCH] QLGE: qlge_main: Fix style Adam Kandur
2021-12-01 14:53 ` Greg KH
2021-12-03  8:14 ` Dan Carpenter
2021-12-03  9:06   ` Adam Kandur

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.