Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1299892

[PATCH 2/3] net-gianfar: Delete unnecessary variable initialisations in gfar_ethflow_to_filer_table()

From SF Markus Elfring <elfring@users.sourceforge.net>
Newsgroups linux.kernel
Subject [PATCH 2/3] net-gianfar: Delete unnecessary variable initialisations in gfar_ethflow_to_filer_table()
Date 2016-01-01 13:30 +0100
Message-ID <qM70d-2ob-1@gated-at.bofh.it> (permalink)
References <qEuGl-43C-5@gated-at.bofh.it> <qM6Qy-2kR-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Markus Elfring <elfring@users.sourceforge.net>
Date: Fri, 1 Jan 2016 12:56:23 +0100

Omit explicit initialisation at the beginning for four local variables
which are redefined before their first use.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
 drivers/net/ethernet/freescale/gianfar_ethtool.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/freescale/gianfar_ethtool.c b/drivers/net/ethernet/freescale/gianfar_ethtool.c
index be4941e..508be89 100644
--- a/drivers/net/ethernet/freescale/gianfar_ethtool.c
+++ b/drivers/net/ethernet/freescale/gianfar_ethtool.c
@@ -768,12 +768,12 @@ static void ethflow_to_filer_rules (struct gfar_private *priv, u64 ethflow)
 static int gfar_ethflow_to_filer_table(struct gfar_private *priv, u64 ethflow,
 				       u64 class)
 {
-	unsigned int last_rule_idx = priv->cur_filer_idx;
+	unsigned int last_rule_idx;
 	unsigned int cmp_rqfpr;
 	unsigned int *local_rqfpr;
 	unsigned int *local_rqfcr;
-	int i = 0x0, k = 0x0;
-	int j = MAX_FILER_IDX, l = 0x0;
+	int i, k, l;
+	int j = MAX_FILER_IDX;
 	int ret = 1;
 
 	local_rqfpr = kmalloc_array(MAX_FILER_IDX + 1, sizeof(unsigned int),
-- 
2.6.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/3] net-gianfar: Fine-tuning for  gfar_ethflow_to_filer_table() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 13:20 +0100
  [PATCH 2/3] net-gianfar: Delete unnecessary variable initialisations  in gfar_ethflow_to_filer_table() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 13:30 +0100
  [PATCH 3/3] net-gianfar: Extend an initialisation clause of a for  loop in gfar_ethflow_to_filer_table() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 13:30 +0100
  [PATCH 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 13:30 +0100
    Re: [PATCH 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection Julia Lawall <julia.lawall@lip6.fr> - 2016-01-01 13:40 +0100
      Re: [PATCH 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 14:00 +0100
        Re: [PATCH 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection Julia Lawall <julia.lawall@lip6.fr> - 2016-01-01 14:10 +0100
          Re: [PATCH 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection Francois Romieu <romieu@fr.zoreil.com> - 2016-01-01 15:50 +0100
      [PATCH v2 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-01-01 14:10 +0100
        Re: [PATCH v2 1/3] net-gianfar: Less function calls in  gfar_ethflow_to_filer_table() after error detection David Miller <davem@davemloft.net> - 2016-01-02 04:20 +0100

csiph-web