diff mbox

[net-next] ixgbe: removing unnecesary assignments

Message ID 49F88B2F.4000802@linux.vnet.ibm.com
State Not Applicable, archived
Delegated to: David Miller
Headers show

Commit Message

Breno Leitao April 29, 2009, 5:15 p.m. UTC
This patch removes some assignment that are not necessary. Since the ret
variable is declared as false during its initialization, it makes no sense to
reassign false to it again.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>

---
 drivers/net/ixgbe/ixgbe_main.c |   12 ------------
 1 files changed, 0 insertions(+), 12 deletions(-)

Comments

Kirsher, Jeffrey T April 29, 2009, 10:27 p.m. UTC | #1
On Wed, Apr 29, 2009 at 10:15 AM, Breno Leitao
<leitao@linux.vnet.ibm.com> wrote:
> This patch removes some assignment that are not necessary. Since the ret
> variable is declared as false during its initialization, it makes no sense to
> reassign false to it again.
>
> Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
>
> ---

Thanks Breno, I have added the patch to my queue of ixgbe patches.  I
will push it with the other ixgbe patches I have, thanks again.
diff mbox

Patch

diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c
index 5020f11..c238677 100644
--- a/drivers/net/ixgbe/ixgbe_main.c
+++ b/drivers/net/ixgbe/ixgbe_main.c
@@ -2775,8 +2775,6 @@  static inline bool ixgbe_set_dcb_queues(struct ixgbe_adapter *adapter)
 		adapter->num_tx_queues =
 		                      adapter->ring_feature[RING_F_DCB].indices;
 		ret = true;
-	} else {
-		ret = false;
 	}
 
 	return ret;
@@ -2802,8 +2800,6 @@  static inline bool ixgbe_set_rss_queues(struct ixgbe_adapter *adapter)
 		adapter->num_tx_queues =
 		                      adapter->ring_feature[RING_F_RSS].indices;
 		ret = true;
-	} else {
-		ret = false;
 	}
 
 	return ret;
@@ -2910,8 +2906,6 @@  static inline bool ixgbe_cache_ring_rss(struct ixgbe_adapter *adapter)
 		for (i = 0; i < adapter->num_tx_queues; i++)
 			adapter->tx_ring[i].reg_idx = i;
 		ret = true;
-	} else {
-		ret = false;
 	}
 
 	return ret;
@@ -2986,14 +2980,8 @@  static inline bool ixgbe_cache_ring_dcb(struct ixgbe_adapter *adapter)
 					adapter->rx_ring[i].reg_idx = i << 5;
 
 				ret = true;
-			} else {
-				ret = false;
 			}
-		} else {
-			ret = false;
 		}
-	} else {
-		ret = false;
 	}
 
 	return ret;