All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/43] drivers/net: fix (sparse) warnings
@ 2009-02-14 21:11 ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:11 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

The following series fixes a couple of (sparse) warnings.

---

Hannes Eder (43):
      drivers/net/wireless/prism54: fix sparse warning: fix signedness
      drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness
      drivers/net/wireless/b43: fix warning: format not a string literal and no ...
      drivers/net/wireless/ath9k: fix sparse warnings: Should it be static?
      drivers/net/wireless: fix sparse warnings: fix signedness
      drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one
      drivers/net/wireless: fix sparse warning: context imbalance
      drivers/net/wan: fix sparse warning: symbol shadows an earlier one
      drivers/net/wan: fix warning: format not a string literal and no ...
      drivers/net/usb: fix sparse warnings: Should it be static?
      drivers/net/tulip: fix sparse warning: symbol shadows an earlier one
      drivers/net/tulip: fix warning: format not a string literal and no ...
      drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
      drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one
      drivers/net/tokenring: fix warning: format not a string literal and no ...
      drivers/net/skfp: fix sparse warning: move decls to header file
      drivers/net/sfc: fix sparse warnings: Should it be static?
      drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
      drivers/net/pcmcia: fix warning: format not a string literal and no ...
      drivers/net/ixgbe: fix sparse warning: Should it be static?
      drivers/net/igb: fix sparse warning: symbol shadows an earlier one
      drivers/net/hamradio: fix sparse warnings: fix signedness
      drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one
      drivers/net/hamradio: fix sparse warning: context imbalance
      drivers/net/hamradio: fix warning: format not a string literal and no ...
      drivers/net/e1000e: fix sparse warning: Should it be static?
      drivers/net/cxgb3: fix sparse warnings: fix signedness
      drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
      drivers/net/bonding: fix sparse warning: symbol shadows an earlier one
      drivers/net/bonding: fix sparse warnings: context imbalance
      drivers/net/atlx: fix sparse warnings: fix signedness
      drivers/net/atl1e: fix sparse warnings: fix signedness
      drivers/net/arcnet: fix sparse warning:  symbol shadows an earlier one
      drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
      drivers/net/ppp*.c: fix sparse warnings: fix signedness
      drivers/net/ni65.c: fix sparse warnings: fix signedness
      drivers/net/lance.c: fix sparse warnings: fix signedness
      drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/ns83820.c: fix sparse warnings: fix signedness
      drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one
      drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one


 drivers/net/arcnet/arcnet.c              |    1 -
 drivers/net/at1700.c                     |    2 +-
 drivers/net/atl1e/atl1e.h                |    2 +-
 drivers/net/atl1e/atl1e_param.c          |    2 +-
 drivers/net/atlx/atl1.c                  |    2 +-
 drivers/net/atlx/atl2.c                  |    2 +-
 drivers/net/bonding/bond_alb.c           |    8 ++++++++
 drivers/net/bonding/bond_main.c          |   14 +++++++++++---
 drivers/net/cxgb3/ael1002.c              |    3 ++-
 drivers/net/cxgb3/cxgb3_main.c           |    3 +--
 drivers/net/e1000e/82571.c               |    2 +-
 drivers/net/e2100.c                      |    6 +++---
 drivers/net/hamradio/6pack.c             |    4 ++--
 drivers/net/hamradio/bpqether.c          |    5 ++++-
 drivers/net/hamradio/mkiss.c             |    9 +++++----
 drivers/net/hamradio/scc.c               |    3 ++-
 drivers/net/hamradio/yam.c               |    9 +++++----
 drivers/net/igb/igb_main.c               |    4 ++--
 drivers/net/ixgbe/ixgbe_82598.c          |    2 +-
 drivers/net/lance.c                      |   11 ++++++-----
 drivers/net/ni65.c                       |   11 +++++------
 drivers/net/niu.c                        |    2 +-
 drivers/net/ns83820.c                    |    2 +-
 drivers/net/pcmcia/axnet_cs.c            |    2 +-
 drivers/net/ppp_generic.c                |    2 +-
 drivers/net/pppoe.c                      |    2 +-
 drivers/net/pppol2tp.c                   |    2 +-
 drivers/net/r6040.c                      |    4 ++--
 drivers/net/s2io.c                       |    1 -
 drivers/net/sfc/mtd.c                    |    3 +++
 drivers/net/sfc/tenxpress.c              |    7 +++----
 drivers/net/skfp/h/smc.h                 |   17 +++++++++++++++++
 drivers/net/skfp/hwmtm.c                 |    9 ---------
 drivers/net/skfp/pcmplc.c                |    3 ---
 drivers/net/skfp/skfddi.c                |    3 ---
 drivers/net/skfp/smt.c                   |   10 ----------
 drivers/net/tokenring/lanstreamer.c      |    2 --
 drivers/net/tokenring/madgemc.c          |    2 --
 drivers/net/tokenring/olympic.c          |    1 -
 drivers/net/tokenring/smctr.c            |    3 ++-
 drivers/net/tokenring/smctr.h            |    2 +-
 drivers/net/tulip/de4x5.c                |    7 ++++---
 drivers/net/tulip/media.c                |    8 +++-----
 drivers/net/tulip/winbond-840.c          |    2 +-
 drivers/net/usb/hso.c                    |   10 +++++-----
 drivers/net/usb/smsc95xx.c               |    2 +-
 drivers/net/wan/lapbether.c              |    3 ++-
 drivers/net/wan/sbni.c                   |   17 +++++++++--------
 drivers/net/wan/z85230.c                 |    3 ++-
 drivers/net/wireless/airo.c              |    6 ++----
 drivers/net/wireless/ath9k/eeprom.c      |    8 ++++----
 drivers/net/wireless/b43/main.c          |   10 +++++-----
 drivers/net/wireless/ipw2x00/ipw2100.c   |    9 +++++----
 drivers/net/wireless/prism54/isl_ioctl.c |    3 ++-
 drivers/net/wireless/prism54/oid_mgt.c   |    2 +-
 drivers/net/wireless/strip.c             |    2 ++
 drivers/net/wireless/wavelan.c           |    8 ++++----
 include/linux/hdlcdrv.h                  |    2 +-
 58 files changed, 150 insertions(+), 136 deletions(-)

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

* [PATCH 00/43] drivers/net: fix (sparse) warnings
@ 2009-02-14 21:11 ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:11 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

The following series fixes a couple of (sparse) warnings.

---

Hannes Eder (43):
      drivers/net/wireless/prism54: fix sparse warning: fix signedness
      drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness
      drivers/net/wireless/b43: fix warning: format not a string literal and no ...
      drivers/net/wireless/ath9k: fix sparse warnings: Should it be static?
      drivers/net/wireless: fix sparse warnings: fix signedness
      drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one
      drivers/net/wireless: fix sparse warning: context imbalance
      drivers/net/wan: fix sparse warning: symbol shadows an earlier one
      drivers/net/wan: fix warning: format not a string literal and no ...
      drivers/net/usb: fix sparse warnings: Should it be static?
      drivers/net/tulip: fix sparse warning: symbol shadows an earlier one
      drivers/net/tulip: fix warning: format not a string literal and no ...
      drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
      drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one
      drivers/net/tokenring: fix warning: format not a string literal and no ...
      drivers/net/skfp: fix sparse warning: move decls to header file
      drivers/net/sfc: fix sparse warnings: Should it be static?
      drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
      drivers/net/pcmcia: fix warning: format not a string literal and no ...
      drivers/net/ixgbe: fix sparse warning: Should it be static?
      drivers/net/igb: fix sparse warning: symbol shadows an earlier one
      drivers/net/hamradio: fix sparse warnings: fix signedness
      drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one
      drivers/net/hamradio: fix sparse warning: context imbalance
      drivers/net/hamradio: fix warning: format not a string literal and no ...
      drivers/net/e1000e: fix sparse warning: Should it be static?
      drivers/net/cxgb3: fix sparse warnings: fix signedness
      drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
      drivers/net/bonding: fix sparse warning: symbol shadows an earlier one
      drivers/net/bonding: fix sparse warnings: context imbalance
      drivers/net/atlx: fix sparse warnings: fix signedness
      drivers/net/atl1e: fix sparse warnings: fix signedness
      drivers/net/arcnet: fix sparse warning:  symbol shadows an earlier one
      drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
      drivers/net/ppp*.c: fix sparse warnings: fix signedness
      drivers/net/ni65.c: fix sparse warnings: fix signedness
      drivers/net/lance.c: fix sparse warnings: fix signedness
      drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/ns83820.c: fix sparse warnings: fix signedness
      drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one
      drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
      drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one


 drivers/net/arcnet/arcnet.c              |    1 -
 drivers/net/at1700.c                     |    2 +-
 drivers/net/atl1e/atl1e.h                |    2 +-
 drivers/net/atl1e/atl1e_param.c          |    2 +-
 drivers/net/atlx/atl1.c                  |    2 +-
 drivers/net/atlx/atl2.c                  |    2 +-
 drivers/net/bonding/bond_alb.c           |    8 ++++++++
 drivers/net/bonding/bond_main.c          |   14 +++++++++++---
 drivers/net/cxgb3/ael1002.c              |    3 ++-
 drivers/net/cxgb3/cxgb3_main.c           |    3 +--
 drivers/net/e1000e/82571.c               |    2 +-
 drivers/net/e2100.c                      |    6 +++---
 drivers/net/hamradio/6pack.c             |    4 ++--
 drivers/net/hamradio/bpqether.c          |    5 ++++-
 drivers/net/hamradio/mkiss.c             |    9 +++++----
 drivers/net/hamradio/scc.c               |    3 ++-
 drivers/net/hamradio/yam.c               |    9 +++++----
 drivers/net/igb/igb_main.c               |    4 ++--
 drivers/net/ixgbe/ixgbe_82598.c          |    2 +-
 drivers/net/lance.c                      |   11 ++++++-----
 drivers/net/ni65.c                       |   11 +++++------
 drivers/net/niu.c                        |    2 +-
 drivers/net/ns83820.c                    |    2 +-
 drivers/net/pcmcia/axnet_cs.c            |    2 +-
 drivers/net/ppp_generic.c                |    2 +-
 drivers/net/pppoe.c                      |    2 +-
 drivers/net/pppol2tp.c                   |    2 +-
 drivers/net/r6040.c                      |    4 ++--
 drivers/net/s2io.c                       |    1 -
 drivers/net/sfc/mtd.c                    |    3 +++
 drivers/net/sfc/tenxpress.c              |    7 +++----
 drivers/net/skfp/h/smc.h                 |   17 +++++++++++++++++
 drivers/net/skfp/hwmtm.c                 |    9 ---------
 drivers/net/skfp/pcmplc.c                |    3 ---
 drivers/net/skfp/skfddi.c                |    3 ---
 drivers/net/skfp/smt.c                   |   10 ----------
 drivers/net/tokenring/lanstreamer.c      |    2 --
 drivers/net/tokenring/madgemc.c          |    2 --
 drivers/net/tokenring/olympic.c          |    1 -
 drivers/net/tokenring/smctr.c            |    3 ++-
 drivers/net/tokenring/smctr.h            |    2 +-
 drivers/net/tulip/de4x5.c                |    7 ++++---
 drivers/net/tulip/media.c                |    8 +++-----
 drivers/net/tulip/winbond-840.c          |    2 +-
 drivers/net/usb/hso.c                    |   10 +++++-----
 drivers/net/usb/smsc95xx.c               |    2 +-
 drivers/net/wan/lapbether.c              |    3 ++-
 drivers/net/wan/sbni.c                   |   17 +++++++++--------
 drivers/net/wan/z85230.c                 |    3 ++-
 drivers/net/wireless/airo.c              |    6 ++----
 drivers/net/wireless/ath9k/eeprom.c      |    8 ++++----
 drivers/net/wireless/b43/main.c          |   10 +++++-----
 drivers/net/wireless/ipw2x00/ipw2100.c   |    9 +++++----
 drivers/net/wireless/prism54/isl_ioctl.c |    3 ++-
 drivers/net/wireless/prism54/oid_mgt.c   |    2 +-
 drivers/net/wireless/strip.c             |    2 ++
 drivers/net/wireless/wavelan.c           |    8 ++++----
 include/linux/hdlcdrv.h                  |    2 +-
 58 files changed, 150 insertions(+), 136 deletions(-)

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

* [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:11   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:11 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration to a more inner scope.

Fix this sparse warning:
  drivers/net/at1700.c:846:21: warning: symbol 'i' shadows an earlier one
  drivers/net/at1700.c:831:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/at1700.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/at1700.c b/drivers/net/at1700.c
index 72ea6e3..ced7079 100644
--- a/drivers/net/at1700.c
+++ b/drivers/net/at1700.c
@@ -828,7 +828,6 @@ set_rx_mode(struct net_device *dev)
 	struct net_local *lp = netdev_priv(dev);
 	unsigned char mc_filter[8];		 /* Multicast hash filter */
 	unsigned long flags;
-	int i;
 
 	if (dev->flags & IFF_PROMISC) {
 		memset(mc_filter, 0xff, sizeof(mc_filter));
@@ -857,6 +856,7 @@ set_rx_mode(struct net_device *dev)
 
 	spin_lock_irqsave (&lp->lock, flags);
 	if (memcmp(mc_filter, lp->mc_filter, sizeof(mc_filter))) {
+		int i;
 		int saved_bank = inw(ioaddr + CONFIG_0);
 		/* Switch to bank 1 and set the multicast table. */
 		outw((saved_bank & ~0x0C00) | 0x0480, ioaddr + CONFIG_0);


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

* [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol
@ 2009-02-14 21:11   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:11 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration to a more inner scope.

Fix this sparse warning:
  drivers/net/at1700.c:846:21: warning: symbol 'i' shadows an earlier one
  drivers/net/at1700.c:831:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/at1700.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/at1700.c b/drivers/net/at1700.c
index 72ea6e3..ced7079 100644
--- a/drivers/net/at1700.c
+++ b/drivers/net/at1700.c
@@ -828,7 +828,6 @@ set_rx_mode(struct net_device *dev)
 	struct net_local *lp = netdev_priv(dev);
 	unsigned char mc_filter[8];		 /* Multicast hash filter */
 	unsigned long flags;
-	int i;
 
 	if (dev->flags & IFF_PROMISC) {
 		memset(mc_filter, 0xff, sizeof(mc_filter));
@@ -857,6 +856,7 @@ set_rx_mode(struct net_device *dev)
 
 	spin_lock_irqsave (&lp->lock, flags);
 	if (memcmp(mc_filter, lp->mc_filter, sizeof(mc_filter))) {
+		int i;
 		int saved_bank = inw(ioaddr + CONFIG_0);
 		/* Switch to bank 1 and set the multicast table. */
 		outw((saved_bank & ~0x0C00) | 0x0480, ioaddr + CONFIG_0);


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

* [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:12   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable and while being at it
make use of ARRAY_SIZE instead of a hardcoded number.

Fix this sparse warning:
  drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
  drivers/net/e2100.c:181:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/e2100.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/e2100.c b/drivers/net/e2100.c
index b07ba19..d2f6ee1 100644
--- a/drivers/net/e2100.c
+++ b/drivers/net/e2100.c
@@ -216,13 +216,13 @@ static int __init e21_probe1(struct net_device *dev, int ioaddr)
 		printk(" %02X", station_addr[i]);
 
 	if (dev->irq < 2) {
-		int irqlist[] = {15,11,10,12,5,9,3,4}, i;
-		for (i = 0; i < 8; i++)
+		int irqlist[] = {15, 11, 10, 12, 5, 9, 3, 4};
+		for (i = 0; i < ARRAY_SIZE(irqlist); i++)
 			if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
 				dev->irq = irqlist[i];
 				break;
 			}
-		if (i >= 8) {
+		if (i >= ARRAY_SIZE(irqlist)) {
 			printk(" unable to get IRQ %d.\n", dev->irq);
 			retval = -EAGAIN;
 			goto out;


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

* [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows
@ 2009-02-14 21:12   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable and while being at it
make use of ARRAY_SIZE instead of a hardcoded number.

Fix this sparse warning:
  drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
  drivers/net/e2100.c:181:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/e2100.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/e2100.c b/drivers/net/e2100.c
index b07ba19..d2f6ee1 100644
--- a/drivers/net/e2100.c
+++ b/drivers/net/e2100.c
@@ -216,13 +216,13 @@ static int __init e21_probe1(struct net_device *dev, int ioaddr)
 		printk(" %02X", station_addr[i]);
 
 	if (dev->irq < 2) {
-		int irqlist[] = {15,11,10,12,5,9,3,4}, i;
-		for (i = 0; i < 8; i++)
+		int irqlist[] = {15, 11, 10, 12, 5, 9, 3, 4};
+		for (i = 0; i < ARRAY_SIZE(irqlist); i++)
 			if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
 				dev->irq = irqlist[i];
 				break;
 			}
-		if (i >= 8) {
+		if (i >= ARRAY_SIZE(irqlist)) {
 			printk(" unable to get IRQ %d.\n", dev->irq);
 			retval = -EAGAIN;
 			goto out;


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

* [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:12   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant variable declaration or move them to a more
inner scope.

Fix this sparse warnings:
  drivers/net/ni65.c:900:37: warning: symbol 'p' shadows an earlier one
  drivers/net/ni65.c:874:21: originally declared here
  drivers/net/ni65.c:925:21: warning: symbol 'p' shadows an earlier one
  drivers/net/ni65.c:874:21: originally declared here
  drivers/net/ni65.c:945:29: warning: symbol 'k' shadows an earlier one
  drivers/net/ni65.c:926:15: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ni65.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ni65.c b/drivers/net/ni65.c
index 2540572..d769a88 100644
--- a/drivers/net/ni65.c
+++ b/drivers/net/ni65.c
@@ -897,7 +897,6 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 
 		if(csr0 & CSR0_ERR)
 		{
-			struct priv *p = dev->ml_priv;
 			if(debuglevel > 1)
 				printk(KERN_ERR "%s: general error: %04x.\n",dev->name,csr0);
 			if(csr0 & CSR0_BABL)
@@ -922,8 +921,7 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
  int j;
  for(j=0;j<RMDNUM;j++)
  {
-	struct priv *p = dev->ml_priv;
-	int i,k,num1,num2;
+	int i, num2;
 	for(i=RMDNUM-1;i>0;i--) {
 		 num2 = (p->rmdnum + i) & (RMDNUM-1);
 		 if(!(p->rmdhead[num2].u.s.status & RCV_OWN))
@@ -931,6 +929,7 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 	}
 
 	if(i) {
+		int k, num1;
 		for(k=0;k<RMDNUM;k++) {
 			num1 = (p->rmdnum + k) & (RMDNUM-1);
 			if(!(p->rmdhead[num1].u.s.status & RCV_OWN))
@@ -942,7 +941,6 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 		if(debuglevel > 0)
 		{
 			char buf[256],*buf1;
-			int k;
 			buf1 = buf;
 			for(k=0;k<RMDNUM;k++) {
 				sprintf(buf1,"%02x ",(p->rmdhead[k].u.s.status)); /* & RCV_OWN) ); */


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

* [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows
@ 2009-02-14 21:12   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant variable declaration or move them to a more
inner scope.

Fix this sparse warnings:
  drivers/net/ni65.c:900:37: warning: symbol 'p' shadows an earlier one
  drivers/net/ni65.c:874:21: originally declared here
  drivers/net/ni65.c:925:21: warning: symbol 'p' shadows an earlier one
  drivers/net/ni65.c:874:21: originally declared here
  drivers/net/ni65.c:945:29: warning: symbol 'k' shadows an earlier one
  drivers/net/ni65.c:926:15: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ni65.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ni65.c b/drivers/net/ni65.c
index 2540572..d769a88 100644
--- a/drivers/net/ni65.c
+++ b/drivers/net/ni65.c
@@ -897,7 +897,6 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 
 		if(csr0 & CSR0_ERR)
 		{
-			struct priv *p = dev->ml_priv;
 			if(debuglevel > 1)
 				printk(KERN_ERR "%s: general error: %04x.\n",dev->name,csr0);
 			if(csr0 & CSR0_BABL)
@@ -922,8 +921,7 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
  int j;
  for(j=0;j<RMDNUM;j++)
  {
-	struct priv *p = dev->ml_priv;
-	int i,k,num1,num2;
+	int i, num2;
 	for(i=RMDNUM-1;i>0;i--) {
 		 num2 = (p->rmdnum + i) & (RMDNUM-1);
 		 if(!(p->rmdhead[num2].u.s.status & RCV_OWN))
@@ -931,6 +929,7 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 	}
 
 	if(i) {
+		int k, num1;
 		for(k=0;k<RMDNUM;k++) {
 			num1 = (p->rmdnum + k) & (RMDNUM-1);
 			if(!(p->rmdhead[num1].u.s.status & RCV_OWN))
@@ -942,7 +941,6 @@ static irqreturn_t ni65_interrupt(int irq, void * dev_id)
 		if(debuglevel > 0)
 		{
 			char buf[256],*buf1;
-			int k;
 			buf1 = buf;
 			for(k=0;k<RMDNUM;k++) {
 				sprintf(buf1,"%02x ",(p->rmdhead[k].u.s.status)); /* & RCV_OWN) ); */


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

* [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:12   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ns83820.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/ns83820.c b/drivers/net/ns83820.c
index e80294d..9266502 100644
--- a/drivers/net/ns83820.c
+++ b/drivers/net/ns83820.c
@@ -409,7 +409,7 @@ static int lnksts = 0;		/* CFG_LNKSTS bit polarity */
 struct rx_info {
 	spinlock_t	lock;
 	int		up;
-	long		idle;
+	unsigned long	idle;
 
 	struct sk_buff	*skbs[NR_RX_DESC];
 


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

* [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix
@ 2009-02-14 21:12   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
  drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ns83820.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/ns83820.c b/drivers/net/ns83820.c
index e80294d..9266502 100644
--- a/drivers/net/ns83820.c
+++ b/drivers/net/ns83820.c
@@ -409,7 +409,7 @@ static int lnksts = 0;		/* CFG_LNKSTS bit polarity */
 struct rx_info {
 	spinlock_t	lock;
 	int		up;
-	long		idle;
+	unsigned long	idle;
 
 	struct sk_buff	*skbs[NR_RX_DESC];
 


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

* [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:12   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration to a more inner scope.

Fix this sparse warning:
  drivers/net/niu.c:2399:21: warning: symbol 'err' shadows an earlier one
  drivers/net/niu.c:2287:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/niu.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/niu.c b/drivers/net/niu.c
index c26325d..32374a1 100644
--- a/drivers/net/niu.c
+++ b/drivers/net/niu.c
@@ -2284,7 +2284,6 @@ static int serdes_init_10g_serdes(struct niu *np)
 	struct niu_link_config *lp = &np->link_config;
 	unsigned long ctrl_reg, test_cfg_reg, pll_cfg, i;
 	u64 ctrl_val, test_cfg_val, sig, mask, val;
-	int err;
 	u64 reset_val;
 
 	switch (np->port) {
@@ -2337,6 +2336,7 @@ static int serdes_init_10g_serdes(struct niu *np)
 	/* Initialize all 4 lanes of the SERDES.  */
 	for (i = 0; i < 4; i++) {
 		u32 rxtx_ctrl, glue0;
+		int err;
 
 		err = esr_read_rxtx_ctrl(np, i, &rxtx_ctrl);
 		if (err)


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

* [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows
@ 2009-02-14 21:12   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:12 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration to a more inner scope.

Fix this sparse warning:
  drivers/net/niu.c:2399:21: warning: symbol 'err' shadows an earlier one
  drivers/net/niu.c:2287:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/niu.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/niu.c b/drivers/net/niu.c
index c26325d..32374a1 100644
--- a/drivers/net/niu.c
+++ b/drivers/net/niu.c
@@ -2284,7 +2284,6 @@ static int serdes_init_10g_serdes(struct niu *np)
 	struct niu_link_config *lp = &np->link_config;
 	unsigned long ctrl_reg, test_cfg_reg, pll_cfg, i;
 	u64 ctrl_val, test_cfg_val, sig, mask, val;
-	int err;
 	u64 reset_val;
 
 	switch (np->port) {
@@ -2337,6 +2336,7 @@ static int serdes_init_10g_serdes(struct niu *np)
 	/* Initialize all 4 lanes of the SERDES.  */
 	for (i = 0; i < 4; i++) {
 		u32 rxtx_ctrl, glue0;
+		int err;
 
 		err = esr_read_rxtx_ctrl(np, i, &rxtx_ctrl);
 		if (err)


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

* [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:13   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Besides from fixing the signedness issue remove some
whitespace to obey to the 80 character limit.

Fix this sparse warnings:
  drivers/net/lance.c:399:19: warning: incorrect type in assignment (different signedness)
  drivers/net/lance.c:654:29: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/lance.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/net/lance.c b/drivers/net/lance.c
index d7afb93..d83d401 100644
--- a/drivers/net/lance.c
+++ b/drivers/net/lance.c
@@ -391,7 +391,8 @@ MODULE_LICENSE("GPL");
    */
 static int __init do_lance_probe(struct net_device *dev)
 {
-	int *port, result;
+	unsigned int *port;
+	int result;
 
 	if (high_memory <= phys_to_virt(16*1024*1024))
 		lance_need_isa_bounce_buffers = 0;
@@ -456,13 +457,13 @@ out:
 static int __init lance_probe1(struct net_device *dev, int ioaddr, int irq, int options)
 {
 	struct lance_private *lp;
-	long dma_channels;			/* Mark spuriously-busy DMA channels */
+	unsigned long dma_channels;	/* Mark spuriously-busy DMA channels */
 	int i, reset_val, lance_version;
 	const char *chipname;
 	/* Flags for specific chips or boards. */
-	unsigned char hpJ2405A = 0;		/* HP ISA adaptor */
-	int hp_builtin = 0;			/* HP on-board ethernet. */
-	static int did_version;			/* Already printed version info. */
+	unsigned char hpJ2405A = 0;	/* HP ISA adaptor */
+	int hp_builtin = 0;		/* HP on-board ethernet. */
+	static int did_version;		/* Already printed version info. */
 	unsigned long flags;
 	int err = -ENOMEM;
 	void __iomem *bios;


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

* [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix signedness
@ 2009-02-14 21:13   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Besides from fixing the signedness issue remove some
whitespace to obey to the 80 character limit.

Fix this sparse warnings:
  drivers/net/lance.c:399:19: warning: incorrect type in assignment (different signedness)
  drivers/net/lance.c:654:29: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/lance.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/net/lance.c b/drivers/net/lance.c
index d7afb93..d83d401 100644
--- a/drivers/net/lance.c
+++ b/drivers/net/lance.c
@@ -391,7 +391,8 @@ MODULE_LICENSE("GPL");
    */
 static int __init do_lance_probe(struct net_device *dev)
 {
-	int *port, result;
+	unsigned int *port;
+	int result;
 
 	if (high_memory <= phys_to_virt(16*1024*1024))
 		lance_need_isa_bounce_buffers = 0;
@@ -456,13 +457,13 @@ out:
 static int __init lance_probe1(struct net_device *dev, int ioaddr, int irq, int options)
 {
 	struct lance_private *lp;
-	long dma_channels;			/* Mark spuriously-busy DMA channels */
+	unsigned long dma_channels;	/* Mark spuriously-busy DMA channels */
 	int i, reset_val, lance_version;
 	const char *chipname;
 	/* Flags for specific chips or boards. */
-	unsigned char hpJ2405A = 0;		/* HP ISA adaptor */
-	int hp_builtin = 0;			/* HP on-board ethernet. */
-	static int did_version;			/* Already printed version info. */
+	unsigned char hpJ2405A = 0;	/* HP ISA adaptor */
+	int hp_builtin = 0;		/* HP on-board ethernet. */
+	static int did_version;		/* Already printed version info. */
 	unsigned long flags;
 	int err = -ENOMEM;
 	void __iomem *bios;


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

* [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:13   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ni65.c:488:36: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ni65.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ni65.c b/drivers/net/ni65.c
index d769a88..df5f869 100644
--- a/drivers/net/ni65.c
+++ b/drivers/net/ni65.c
@@ -481,8 +481,9 @@ static int __init ni65_probe1(struct net_device *dev,int ioaddr)
 	else {
 		if(dev->dma == 0) {
 		/* 'stuck test' from lance.c */
-			long dma_channels = ((inb(DMA1_STAT_REG) >> 4) & 0x0f) |
-					    (inb(DMA2_STAT_REG) & 0xf0);
+			unsigned long dma_channels =
+				((inb(DMA1_STAT_REG) >> 4) & 0x0f)
+				| (inb(DMA2_STAT_REG) & 0xf0);
 			for(i=1;i<5;i++) {
 				int dma = dmatab[i];
 				if(test_bit(dma,&dma_channels) || request_dma(dma,"ni6510"))


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

* [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix signedness
@ 2009-02-14 21:13   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ni65.c:488:36: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ni65.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ni65.c b/drivers/net/ni65.c
index d769a88..df5f869 100644
--- a/drivers/net/ni65.c
+++ b/drivers/net/ni65.c
@@ -481,8 +481,9 @@ static int __init ni65_probe1(struct net_device *dev,int ioaddr)
 	else {
 		if(dev->dma = 0) {
 		/* 'stuck test' from lance.c */
-			long dma_channels = ((inb(DMA1_STAT_REG) >> 4) & 0x0f) |
-					    (inb(DMA2_STAT_REG) & 0xf0);
+			unsigned long dma_channels +				((inb(DMA1_STAT_REG) >> 4) & 0x0f)
+				| (inb(DMA2_STAT_REG) & 0xf0);
 			for(i=1;i<5;i++) {
 				int dma = dmatab[i];
 				if(test_bit(dma,&dma_channels) || request_dma(dma,"ni6510"))


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

* [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:13   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
  drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
  drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ppp_generic.c |    2 +-
 drivers/net/pppoe.c       |    2 +-
 drivers/net/pppol2tp.c    |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c
index fddc849..81e7fcc 100644
--- a/drivers/net/ppp_generic.c
+++ b/drivers/net/ppp_generic.c
@@ -183,7 +183,7 @@ static atomic_t ppp_unit_count = ATOMIC_INIT(0);
 static atomic_t channel_count = ATOMIC_INIT(0);
 
 /* per-net private data for this module */
-static unsigned int ppp_net_id;
+static int ppp_net_id;
 struct ppp_net {
 	/* units to ppp mapping */
 	struct idr units_idr;
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index af6321d..e2968f0 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -97,7 +97,7 @@ static const struct proto_ops pppoe_ops;
 static struct ppp_channel_ops pppoe_chan_ops;
 
 /* per-net private data for this module */
-static unsigned int pppoe_net_id;
+static int pppoe_net_id;
 struct pppoe_net {
 	/*
 	 * we could use _single_ hash table for all
diff --git a/drivers/net/pppol2tp.c b/drivers/net/pppol2tp.c
index 1ba0f68..5b07dd8 100644
--- a/drivers/net/pppol2tp.c
+++ b/drivers/net/pppol2tp.c
@@ -232,7 +232,7 @@ static struct ppp_channel_ops pppol2tp_chan_ops = { pppol2tp_xmit , NULL };
 static struct proto_ops pppol2tp_ops;
 
 /* per-net private data for this module */
-static unsigned int pppol2tp_net_id;
+static int pppol2tp_net_id;
 struct pppol2tp_net {
 	struct list_head pppol2tp_tunnel_list;
 	rwlock_t pppol2tp_tunnel_list_lock;


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

* [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
@ 2009-02-14 21:13   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
  drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
  drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ppp_generic.c |    2 +-
 drivers/net/pppoe.c       |    2 +-
 drivers/net/pppol2tp.c    |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c
index fddc849..81e7fcc 100644
--- a/drivers/net/ppp_generic.c
+++ b/drivers/net/ppp_generic.c
@@ -183,7 +183,7 @@ static atomic_t ppp_unit_count = ATOMIC_INIT(0);
 static atomic_t channel_count = ATOMIC_INIT(0);
 
 /* per-net private data for this module */
-static unsigned int ppp_net_id;
+static int ppp_net_id;
 struct ppp_net {
 	/* units to ppp mapping */
 	struct idr units_idr;
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index af6321d..e2968f0 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -97,7 +97,7 @@ static const struct proto_ops pppoe_ops;
 static struct ppp_channel_ops pppoe_chan_ops;
 
 /* per-net private data for this module */
-static unsigned int pppoe_net_id;
+static int pppoe_net_id;
 struct pppoe_net {
 	/*
 	 * we could use _single_ hash table for all
diff --git a/drivers/net/pppol2tp.c b/drivers/net/pppol2tp.c
index 1ba0f68..5b07dd8 100644
--- a/drivers/net/pppol2tp.c
+++ b/drivers/net/pppol2tp.c
@@ -232,7 +232,7 @@ static struct ppp_channel_ops pppol2tp_chan_ops = { pppol2tp_xmit , NULL };
 static struct proto_ops pppol2tp_ops;
 
 /* per-net private data for this module */
-static unsigned int pppol2tp_net_id;
+static int pppol2tp_net_id;
 struct pppol2tp_net {
 	struct list_head pppol2tp_tunnel_list;
 	rwlock_t pppol2tp_tunnel_list_lock;


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

* [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:14   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
  drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/r6040.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c
index 3c27a7b..9c95ebe 100644
--- a/drivers/net/r6040.c
+++ b/drivers/net/r6040.c
@@ -484,12 +484,12 @@ static int r6040_close(struct net_device *dev)
 	/* Free Descriptor memory */
 	if (lp->rx_ring) {
 		pci_free_consistent(pdev, RX_DESC_SIZE, lp->rx_ring, lp->rx_ring_dma);
-		lp->rx_ring = 0;
+		lp->rx_ring = NULL;
 	}
 
 	if (lp->tx_ring) {
 		pci_free_consistent(pdev, TX_DESC_SIZE, lp->tx_ring, lp->tx_ring_dma);
-		lp->tx_ring = 0;
+		lp->tx_ring = NULL;
 	}
 
 	return 0;


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

* [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain
@ 2009-02-14 21:14   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
  drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/r6040.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c
index 3c27a7b..9c95ebe 100644
--- a/drivers/net/r6040.c
+++ b/drivers/net/r6040.c
@@ -484,12 +484,12 @@ static int r6040_close(struct net_device *dev)
 	/* Free Descriptor memory */
 	if (lp->rx_ring) {
 		pci_free_consistent(pdev, RX_DESC_SIZE, lp->rx_ring, lp->rx_ring_dma);
-		lp->rx_ring = 0;
+		lp->rx_ring = NULL;
 	}
 
 	if (lp->tx_ring) {
 		pci_free_consistent(pdev, TX_DESC_SIZE, lp->tx_ring, lp->tx_ring_dma);
-		lp->tx_ring = 0;
+		lp->tx_ring = NULL;
 	}
 
 	return 0;


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

* [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:14   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable.

Fix this sparse warning:
  drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
  drivers/net/s2io.c:7184:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/s2io.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c
index 5cd2291..16868b7 100644
--- a/drivers/net/s2io.c
+++ b/drivers/net/s2io.c
@@ -7220,7 +7220,6 @@ static int s2io_card_up(struct s2io_nic * sp)
 
 	/* Initialise napi */
 	if (config->napi) {
-		int i;
 		if (config->intr_type ==  MSI_X) {
 			for (i = 0; i < sp->config.rx_ring_num; i++)
 				napi_enable(&sp->mac_control.rings[i].napi);


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

* [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows
@ 2009-02-14 21:14   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable.

Fix this sparse warning:
  drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
  drivers/net/s2io.c:7184:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/s2io.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c
index 5cd2291..16868b7 100644
--- a/drivers/net/s2io.c
+++ b/drivers/net/s2io.c
@@ -7220,7 +7220,6 @@ static int s2io_card_up(struct s2io_nic * sp)
 
 	/* Initialise napi */
 	if (config->napi) {
-		int i;
 		if (config->intr_type =  MSI_X) {
 			for (i = 0; i < sp->config.rx_ring_num; i++)
 				napi_enable(&sp->mac_control.rings[i].napi);


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

* [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:14   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable.

Fix this sparse warning:
  drivers/net/arcnet/arcnet.c:383:21: warning: symbol 'count' shadows an earlier one
  drivers/net/arcnet/arcnet.c:375:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/arcnet/arcnet.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/arcnet/arcnet.c b/drivers/net/arcnet/arcnet.c
index a80d4a3..d6d4ab3 100644
--- a/drivers/net/arcnet/arcnet.c
+++ b/drivers/net/arcnet/arcnet.c
@@ -380,7 +380,6 @@ int arcnet_open(struct net_device *dev)
 		return -ENODEV;
 
 	BUGLVL(D_PROTO) {
-		int count;
 		BUGMSG(D_PROTO, "protocol map (default is '%c'): ",
 		       arc_proto_default->suffix);
 		for (count = 0; count < 256; count++)


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

* [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows
@ 2009-02-14 21:14   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant inner scope variable.

Fix this sparse warning:
  drivers/net/arcnet/arcnet.c:383:21: warning: symbol 'count' shadows an earlier one
  drivers/net/arcnet/arcnet.c:375:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/arcnet/arcnet.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/arcnet/arcnet.c b/drivers/net/arcnet/arcnet.c
index a80d4a3..d6d4ab3 100644
--- a/drivers/net/arcnet/arcnet.c
+++ b/drivers/net/arcnet/arcnet.c
@@ -380,7 +380,6 @@ int arcnet_open(struct net_device *dev)
 		return -ENODEV;
 
 	BUGLVL(D_PROTO) {
-		int count;
 		BUGMSG(D_PROTO, "protocol map (default is '%c'): ",
 		       arc_proto_default->suffix);
 		for (count = 0; count < 256; count++)


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

* [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:14   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/atl1e/atl1e_main.c:716:39: warning: incorrect type in argument 2 (different signedness)
  drivers/net/atl1e/atl1e_param.c:57:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:68:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:81:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:92:1: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/atl1e/atl1e.h       |    2 +-
 drivers/net/atl1e/atl1e_param.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/atl1e/atl1e.h b/drivers/net/atl1e/atl1e.h
index c49550d..2bf63b4 100644
--- a/drivers/net/atl1e/atl1e.h
+++ b/drivers/net/atl1e/atl1e.h
@@ -448,7 +448,7 @@ struct atl1e_adapter {
 	/* All Descriptor memory */
 	dma_addr_t  	ring_dma;
 	void     	*ring_vir_addr;
-	int             ring_size;
+	u32             ring_size;
 
 	struct atl1e_tx_ring tx_ring;
 	struct atl1e_rx_ring rx_ring;
diff --git a/drivers/net/atl1e/atl1e_param.c b/drivers/net/atl1e/atl1e_param.c
index f72abb3..b3be59f 100644
--- a/drivers/net/atl1e/atl1e_param.c
+++ b/drivers/net/atl1e/atl1e_param.c
@@ -41,7 +41,7 @@
 
 #define ATL1E_PARAM(x, desc) \
 	static int __devinitdata x[ATL1E_MAX_NIC + 1] = ATL1E_PARAM_INIT; \
-	static int num_##x; \
+	static unsigned int num_##x; \
 	module_param_array_named(x, x, int, &num_##x, 0); \
 	MODULE_PARM_DESC(x, desc);
 


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

* [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix signedness
@ 2009-02-14 21:14   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:14 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/atl1e/atl1e_main.c:716:39: warning: incorrect type in argument 2 (different signedness)
  drivers/net/atl1e/atl1e_param.c:57:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:68:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:81:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atl1e/atl1e_param.c:92:1: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/atl1e/atl1e.h       |    2 +-
 drivers/net/atl1e/atl1e_param.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/atl1e/atl1e.h b/drivers/net/atl1e/atl1e.h
index c49550d..2bf63b4 100644
--- a/drivers/net/atl1e/atl1e.h
+++ b/drivers/net/atl1e/atl1e.h
@@ -448,7 +448,7 @@ struct atl1e_adapter {
 	/* All Descriptor memory */
 	dma_addr_t  	ring_dma;
 	void     	*ring_vir_addr;
-	int             ring_size;
+	u32             ring_size;
 
 	struct atl1e_tx_ring tx_ring;
 	struct atl1e_rx_ring rx_ring;
diff --git a/drivers/net/atl1e/atl1e_param.c b/drivers/net/atl1e/atl1e_param.c
index f72abb3..b3be59f 100644
--- a/drivers/net/atl1e/atl1e_param.c
+++ b/drivers/net/atl1e/atl1e_param.c
@@ -41,7 +41,7 @@
 
 #define ATL1E_PARAM(x, desc) \
 	static int __devinitdata x[ATL1E_MAX_NIC + 1] = ATL1E_PARAM_INIT; \
-	static int num_##x; \
+	static unsigned int num_##x; \
 	module_param_array_named(x, x, int, &num_##x, 0); \
 	MODULE_PARM_DESC(x, desc);
 


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

* [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:15   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: While being at it: statics do not need to be initialized with 0.

Fix this sparse warnings:
  drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/atlx/atl1.c |    2 +-
 drivers/net/atlx/atl2.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c
index c0ceee0..43fc1b2 100644
--- a/drivers/net/atlx/atl1.c
+++ b/drivers/net/atlx/atl1.c
@@ -105,7 +105,7 @@
  * Default Value: 100 (200us)
  */
 static int __devinitdata int_mod_timer[ATL1_MAX_NIC+1] = ATL1_PARAM_INIT;
-static int num_int_mod_timer;
+static unsigned int num_int_mod_timer;
 module_param_array_named(int_mod_timer, int_mod_timer, int,
 	&num_int_mod_timer, 0);
 MODULE_PARM_DESC(int_mod_timer, "Interrupt moderator timer");
diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c
index bc39449..9fe06c3 100644
--- a/drivers/net/atlx/atl2.c
+++ b/drivers/net/atlx/atl2.c
@@ -2854,7 +2854,7 @@ static void atl2_force_ps(struct atl2_hw *hw)
 #else
 #define ATL2_PARAM(X, desc) \
     static int __devinitdata X[ATL2_MAX_NIC+1] = ATL2_PARAM_INIT; \
-    static int num_##X = 0; \
+    static unsigned int num_##X; \
     module_param_array_named(X, X, int, &num_##X, 0); \
     MODULE_PARM_DESC(X, desc);
 #endif


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

* [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness
@ 2009-02-14 21:15   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: While being at it: statics do not need to be initialized with 0.

Fix this sparse warnings:
  drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
  drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/atlx/atl1.c |    2 +-
 drivers/net/atlx/atl2.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c
index c0ceee0..43fc1b2 100644
--- a/drivers/net/atlx/atl1.c
+++ b/drivers/net/atlx/atl1.c
@@ -105,7 +105,7 @@
  * Default Value: 100 (200us)
  */
 static int __devinitdata int_mod_timer[ATL1_MAX_NIC+1] = ATL1_PARAM_INIT;
-static int num_int_mod_timer;
+static unsigned int num_int_mod_timer;
 module_param_array_named(int_mod_timer, int_mod_timer, int,
 	&num_int_mod_timer, 0);
 MODULE_PARM_DESC(int_mod_timer, "Interrupt moderator timer");
diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c
index bc39449..9fe06c3 100644
--- a/drivers/net/atlx/atl2.c
+++ b/drivers/net/atlx/atl2.c
@@ -2854,7 +2854,7 @@ static void atl2_force_ps(struct atl2_hw *hw)
 #else
 #define ATL2_PARAM(X, desc) \
     static int __devinitdata X[ATL2_MAX_NIC+1] = ATL2_PARAM_INIT; \
-    static int num_##X = 0; \
+    static unsigned int num_##X; \
     module_param_array_named(X, X, int, &num_##X, 0); \
     MODULE_PARM_DESC(X, desc);
 #endif


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

* [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context imbalance
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:15   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute functions with __acquires(...) and/or __releases(...).

Fix this sparse warnings:
  drivers/net/bonding/bond_alb.c:1675:9: warning: context imbalance in 'bond_alb_handle_active_change' - unexpected unlock
  drivers/net/bonding/bond_alb.c:1742:9: warning: context imbalance in 'bond_alb_set_mac_address' - unexpected unlock
  drivers/net/bonding/bond_main.c:1025:17: warning: context imbalance in 'bond_do_fail_over_mac' - unexpected unlock
  drivers/net/bonding/bond_main.c:3195:13: warning: context imbalance in 'bond_info_seq_start' - wrong count at exit
  drivers/net/bonding/bond_main.c:3234:13: warning: context imbalance in 'bond_info_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/bonding/bond_alb.c  |    8 ++++++++
 drivers/net/bonding/bond_main.c |    8 ++++++++
 2 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/drivers/net/bonding/bond_alb.c b/drivers/net/bonding/bond_alb.c
index 409b140..8dc6fbb 100644
--- a/drivers/net/bonding/bond_alb.c
+++ b/drivers/net/bonding/bond_alb.c
@@ -1628,6 +1628,10 @@ void bond_alb_handle_link_change(struct bonding *bond, struct slave *slave, char
  * no other locks may be held.
  */
 void bond_alb_handle_active_change(struct bonding *bond, struct slave *new_slave)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	struct slave *swap_slave;
 	int i;
@@ -1704,6 +1708,10 @@ void bond_alb_handle_active_change(struct bonding *bond, struct slave *new_slave
  * Called with RTNL
  */
 int bond_alb_set_mac_address(struct net_device *bond_dev, void *addr)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	struct bonding *bond = netdev_priv(bond_dev);
 	struct sockaddr *sa = addr;
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 4ec7c93..45f6d6a 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -1002,6 +1002,10 @@ static void bond_mc_swap(struct bonding *bond, struct slave *new_active, struct
 static void bond_do_fail_over_mac(struct bonding *bond,
 				  struct slave *new_active,
 				  struct slave *old_active)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	u8 tmp_mac[ETH_ALEN];
 	struct sockaddr saddr;
@@ -3193,6 +3197,8 @@ out:
 #ifdef CONFIG_PROC_FS
 
 static void *bond_info_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(&dev_base_lock)
+	__acquires(&bond->lock)
 {
 	struct bonding *bond = seq->private;
 	loff_t off = 0;
@@ -3232,6 +3238,8 @@ static void *bond_info_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void bond_info_seq_stop(struct seq_file *seq, void *v)
+	__releases(&bond->lock)
+	__releases(&dev_base_lock)
 {
 	struct bonding *bond = seq->private;
 


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

* [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context
@ 2009-02-14 21:15   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute functions with __acquires(...) and/or __releases(...).

Fix this sparse warnings:
  drivers/net/bonding/bond_alb.c:1675:9: warning: context imbalance in 'bond_alb_handle_active_change' - unexpected unlock
  drivers/net/bonding/bond_alb.c:1742:9: warning: context imbalance in 'bond_alb_set_mac_address' - unexpected unlock
  drivers/net/bonding/bond_main.c:1025:17: warning: context imbalance in 'bond_do_fail_over_mac' - unexpected unlock
  drivers/net/bonding/bond_main.c:3195:13: warning: context imbalance in 'bond_info_seq_start' - wrong count at exit
  drivers/net/bonding/bond_main.c:3234:13: warning: context imbalance in 'bond_info_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/bonding/bond_alb.c  |    8 ++++++++
 drivers/net/bonding/bond_main.c |    8 ++++++++
 2 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/drivers/net/bonding/bond_alb.c b/drivers/net/bonding/bond_alb.c
index 409b140..8dc6fbb 100644
--- a/drivers/net/bonding/bond_alb.c
+++ b/drivers/net/bonding/bond_alb.c
@@ -1628,6 +1628,10 @@ void bond_alb_handle_link_change(struct bonding *bond, struct slave *slave, char
  * no other locks may be held.
  */
 void bond_alb_handle_active_change(struct bonding *bond, struct slave *new_slave)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	struct slave *swap_slave;
 	int i;
@@ -1704,6 +1708,10 @@ void bond_alb_handle_active_change(struct bonding *bond, struct slave *new_slave
  * Called with RTNL
  */
 int bond_alb_set_mac_address(struct net_device *bond_dev, void *addr)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	struct bonding *bond = netdev_priv(bond_dev);
 	struct sockaddr *sa = addr;
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 4ec7c93..45f6d6a 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -1002,6 +1002,10 @@ static void bond_mc_swap(struct bonding *bond, struct slave *new_active, struct
 static void bond_do_fail_over_mac(struct bonding *bond,
 				  struct slave *new_active,
 				  struct slave *old_active)
+	__releases(&bond->curr_slave_lock)
+	__releases(&bond->lock)
+	__acquires(&bond->lock)
+	__acquires(&bond->curr_slave_lock)
 {
 	u8 tmp_mac[ETH_ALEN];
 	struct sockaddr saddr;
@@ -3193,6 +3197,8 @@ out:
 #ifdef CONFIG_PROC_FS
 
 static void *bond_info_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(&dev_base_lock)
+	__acquires(&bond->lock)
 {
 	struct bonding *bond = seq->private;
 	loff_t off = 0;
@@ -3232,6 +3238,8 @@ static void *bond_info_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void bond_info_seq_stop(struct seq_file *seq, void *v)
+	__releases(&bond->lock)
+	__releases(&dev_base_lock)
 {
 	struct bonding *bond = seq->private;
 


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

* [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:15   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename function scope variable.

Fix this sparse warning:
  drivers/net/bonding/bond_main.c:4704:13: warning: symbol 'mode' shadows an earlier one
  drivers/net/bonding/bond_main.c:95:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/bonding/bond_main.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 45f6d6a..c5abd17 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -4701,7 +4701,7 @@ static void bond_free_all(void)
  */
 int bond_parse_parm(const char *buf, const struct bond_parm_tbl *tbl)
 {
-	int mode = -1, i, rv;
+	int modeint = -1, i, rv;
 	char *p, modestr[BOND_MAX_MODENAME_LEN + 1] = { 0, };
 
 	for (p = (char *)buf; *p; p++)
@@ -4711,13 +4711,13 @@ int bond_parse_parm(const char *buf, const struct bond_parm_tbl *tbl)
 	if (*p)
 		rv = sscanf(buf, "%20s", modestr);
 	else
-		rv = sscanf(buf, "%d", &mode);
+		rv = sscanf(buf, "%d", &modeint);
 
 	if (!rv)
 		return -1;
 
 	for (i = 0; tbl[i].modename; i++) {
-		if (mode == tbl[i].mode)
+		if (modeint == tbl[i].mode)
 			return tbl[i].mode;
 		if (strcmp(modestr, tbl[i].modename) == 0)
 			return tbl[i].mode;


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

* [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows
@ 2009-02-14 21:15   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:15 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename function scope variable.

Fix this sparse warning:
  drivers/net/bonding/bond_main.c:4704:13: warning: symbol 'mode' shadows an earlier one
  drivers/net/bonding/bond_main.c:95:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/bonding/bond_main.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 45f6d6a..c5abd17 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -4701,7 +4701,7 @@ static void bond_free_all(void)
  */
 int bond_parse_parm(const char *buf, const struct bond_parm_tbl *tbl)
 {
-	int mode = -1, i, rv;
+	int modeint = -1, i, rv;
 	char *p, modestr[BOND_MAX_MODENAME_LEN + 1] = { 0, };
 
 	for (p = (char *)buf; *p; p++)
@@ -4711,13 +4711,13 @@ int bond_parse_parm(const char *buf, const struct bond_parm_tbl *tbl)
 	if (*p)
 		rv = sscanf(buf, "%20s", modestr);
 	else
-		rv = sscanf(buf, "%d", &mode);
+		rv = sscanf(buf, "%d", &modeint);
 
 	if (!rv)
 		return -1;
 
 	for (i = 0; tbl[i].modename; i++) {
-		if (mode = tbl[i].mode)
+		if (modeint = tbl[i].mode)
 			return tbl[i].mode;
 		if (strcmp(modestr, tbl[i].modename) = 0)
 			return tbl[i].mode;


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

* [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:16   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:16 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as close to usage as possible.

Fix this sparse warning:
  drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/cxgb3/cxgb3_main.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
index f2c7cc3..0f6062a 100644
--- a/drivers/net/cxgb3/cxgb3_main.c
+++ b/drivers/net/cxgb3/cxgb3_main.c
@@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
 
 static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
 {
-	int cap;
 	struct port_info *p = netdev_priv(dev);
 	struct link_config *lc = &p->link_config;
 
@@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
 		 * being requested.
 		 */
 		if (cmd->autoneg == AUTONEG_DISABLE) {
-			cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
+			int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
 			if (lc->supported & cap)
 				return 0;
 		}


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

* [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows
@ 2009-02-14 21:16   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:16 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as close to usage as possible.

Fix this sparse warning:
  drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/cxgb3/cxgb3_main.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
index f2c7cc3..0f6062a 100644
--- a/drivers/net/cxgb3/cxgb3_main.c
+++ b/drivers/net/cxgb3/cxgb3_main.c
@@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
 
 static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
 {
-	int cap;
 	struct port_info *p = netdev_priv(dev);
 	struct link_config *lc = &p->link_config;
 
@@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
 		 * being requested.
 		 */
 		if (cmd->autoneg = AUTONEG_DISABLE) {
-			cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
+			int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
 			if (lc->supported & cap)
 				return 0;
 		}


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

* [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:16   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:16 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warning:
  drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/cxgb3/ael1002.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/net/cxgb3/ael1002.c b/drivers/net/cxgb3/ael1002.c
index 5c3c05d..e1b2249 100644
--- a/drivers/net/cxgb3/ael1002.c
+++ b/drivers/net/cxgb3/ael1002.c
@@ -1005,7 +1005,8 @@ static int ael2005_reset(struct cphy *phy, int wait)
 		{ 0, 0, 0, 0 }
 	};
 
-	int err, lasi_ctrl;
+	int err;
+	unsigned int lasi_ctrl;
 
 	err = mdio_read(phy, MDIO_DEV_PMA_PMD, LASI_CTRL, &lasi_ctrl);
 	if (err)


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

* [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness
@ 2009-02-14 21:16   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:16 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warning:
  drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/cxgb3/ael1002.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/net/cxgb3/ael1002.c b/drivers/net/cxgb3/ael1002.c
index 5c3c05d..e1b2249 100644
--- a/drivers/net/cxgb3/ael1002.c
+++ b/drivers/net/cxgb3/ael1002.c
@@ -1005,7 +1005,8 @@ static int ael2005_reset(struct cphy *phy, int wait)
 		{ 0, 0, 0, 0 }
 	};
 
-	int err, lasi_ctrl;
+	int err;
+	unsigned int lasi_ctrl;
 
 	err = mdio_read(phy, MDIO_DEV_PMA_PMD, LASI_CTRL, &lasi_ctrl);
 	if (err)


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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
  2009-02-14 21:13   ` Hannes Eder
@ 2009-02-14 21:29     ` Cyrill Gorcunov
  -1 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-14 21:29 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

[Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
| Fix this sparse warnings:
|   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
|   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
|   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
| 
| Signed-off-by: Hannes Eder <hannes@hanneseder.net>
...

Thanks Hannes,

Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>

	- Cyrill -

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix
@ 2009-02-14 21:29     ` Cyrill Gorcunov
  0 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-14 21:29 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

[Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
| Fix this sparse warnings:
|   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
|   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
|   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
| 
| Signed-off-by: Hannes Eder <hannes@hanneseder.net>
...

Thanks Hannes,

Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>

	- Cyrill -

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

* [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:32   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:32 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbol static.

Fix this sparse warning:
  drivers/net/e1000e/82571.c:1229:5: warning: symbol 'e1000_check_for_serdes_link_82571' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/e1000e/82571.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/e1000e/82571.c b/drivers/net/e1000e/82571.c
index 565fd4e..51f8e84 100644
--- a/drivers/net/e1000e/82571.c
+++ b/drivers/net/e1000e/82571.c
@@ -1226,7 +1226,7 @@ static s32 e1000_setup_fiber_serdes_link_82571(struct e1000_hw *hw)
  *  Checks for link up on the hardware.  If link is not up and we have
  *  a signal, then we need to force link up.
  **/
-s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)
+static s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)
 {
 	struct e1000_mac_info *mac = &hw->mac;
 	u32 rxcw;


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

* [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be
@ 2009-02-14 21:32   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:32 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbol static.

Fix this sparse warning:
  drivers/net/e1000e/82571.c:1229:5: warning: symbol 'e1000_check_for_serdes_link_82571' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/e1000e/82571.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/e1000e/82571.c b/drivers/net/e1000e/82571.c
index 565fd4e..51f8e84 100644
--- a/drivers/net/e1000e/82571.c
+++ b/drivers/net/e1000e/82571.c
@@ -1226,7 +1226,7 @@ static s32 e1000_setup_fiber_serdes_link_82571(struct e1000_hw *hw)
  *  Checks for link up on the hardware.  If link is not up and we have
  *  a signal, then we need to force link up.
  **/
-s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)
+static s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)
 {
 	struct e1000_mac_info *mac = &hw->mac;
 	u32 rxcw;


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

* [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:33   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:33 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it fix an issue in 'mkiss_init_driver', where in case of an
error the status code was not passed to printk.

Fix this warnings:
  drivers/net/hamradio/6pack.c: In function 'sixpack_init_driver':
  drivers/net/hamradio/6pack.c:802: warning: format not a string literal and no format arguments
  drivers/net/hamradio/bpqether.c: In function 'bpq_init_driver':
  drivers/net/hamradio/bpqether.c:609: warning: format not a string literal and no format arguments
  drivers/net/hamradio/mkiss.c: In function 'mkiss_init_driver':
  drivers/net/hamradio/mkiss.c:988: warning: format not a string literal and no format arguments
  drivers/net/hamradio/mkiss.c:991: warning: format not a string literal and no format arguments
  drivers/net/hamradio/scc.c: In function 'scc_init_driver':
  drivers/net/hamradio/scc.c:2109: warning: format not a string literal and no format arguments
  drivers/net/hamradio/yam.c: In function 'yam_init_driver':
  drivers/net/hamradio/yam.c:1094: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/6pack.c    |    4 ++--
 drivers/net/hamradio/bpqether.c |    3 ++-
 drivers/net/hamradio/mkiss.c    |    9 +++++----
 drivers/net/hamradio/scc.c      |    3 ++-
 drivers/net/hamradio/yam.c      |    3 ++-
 5 files changed, 13 insertions(+), 9 deletions(-)

diff --git a/drivers/net/hamradio/6pack.c b/drivers/net/hamradio/6pack.c
index 3da9f39..1551600 100644
--- a/drivers/net/hamradio/6pack.c
+++ b/drivers/net/hamradio/6pack.c
@@ -790,9 +790,9 @@ static struct tty_ldisc_ops sp_ldisc = {
 
 /* Initialize 6pack control device -- register 6pack line discipline */
 
-static char msg_banner[]  __initdata = KERN_INFO \
+static const char msg_banner[]  __initdata = KERN_INFO \
 	"AX.25: 6pack driver, " SIXPACK_VERSION "\n";
-static char msg_regfail[] __initdata = KERN_ERR  \
+static const char msg_regfail[] __initdata = KERN_ERR  \
 	"6pack: can't register line discipline (err = %d)\n";
 
 static int __init sixpack_init_driver(void)
diff --git a/drivers/net/hamradio/bpqether.c b/drivers/net/hamradio/bpqether.c
index 2c619bc..723e9c1 100644
--- a/drivers/net/hamradio/bpqether.c
+++ b/drivers/net/hamradio/bpqether.c
@@ -87,7 +87,8 @@
 
 #include <linux/bpqether.h>
 
-static char banner[] __initdata = KERN_INFO "AX.25: bpqether driver version 004\n";
+static const char banner[] __initdata = KERN_INFO \
+	"AX.25: bpqether driver version 004\n";
 
 static char bcast_addr[6]={0xFF,0xFF,0xFF,0xFF,0xFF,0xFF};
 
diff --git a/drivers/net/hamradio/mkiss.c b/drivers/net/hamradio/mkiss.c
index ed5b37d..032c0db 100644
--- a/drivers/net/hamradio/mkiss.c
+++ b/drivers/net/hamradio/mkiss.c
@@ -976,9 +976,9 @@ static struct tty_ldisc_ops ax_ldisc = {
 	.write_wakeup	= mkiss_write_wakeup
 };
 
-static char banner[] __initdata = KERN_INFO \
+static const char banner[] __initdata = KERN_INFO \
 	"mkiss: AX.25 Multikiss, Hans Albas PE1AYX\n";
-static char msg_regfail[] __initdata = KERN_ERR \
+static const char msg_regfail[] __initdata = KERN_ERR \
 	"mkiss: can't register line discipline (err = %d)\n";
 
 static int __init mkiss_init_driver(void)
@@ -987,8 +987,9 @@ static int __init mkiss_init_driver(void)
 
 	printk(banner);
 
-	if ((status = tty_register_ldisc(N_AX25, &ax_ldisc)) != 0)
-		printk(msg_regfail);
+	status = tty_register_ldisc(N_AX25, &ax_ldisc);
+	if (status != 0)
+		printk(msg_regfail, status);
 
 	return status;
 }
diff --git a/drivers/net/hamradio/scc.c b/drivers/net/hamradio/scc.c
index 2acb18f..d712e7a 100644
--- a/drivers/net/hamradio/scc.c
+++ b/drivers/net/hamradio/scc.c
@@ -184,7 +184,8 @@
 
 #include "z8530.h"
 
-static char banner[] __initdata = KERN_INFO "AX.25: Z8530 SCC driver version "VERSION".dl1bke\n";
+static const char banner[] __initdata = KERN_INFO \
+	"AX.25: Z8530 SCC driver version "VERSION".dl1bke\n";
 
 static void t_dwait(unsigned long);
 static void t_txdelay(unsigned long);
diff --git a/drivers/net/hamradio/yam.c b/drivers/net/hamradio/yam.c
index 82a8be7..a54b865 100644
--- a/drivers/net/hamradio/yam.c
+++ b/drivers/net/hamradio/yam.c
@@ -77,7 +77,8 @@
 /* --------------------------------------------------------------------- */
 
 static const char yam_drvname[] = "yam";
-static char yam_drvinfo[] __initdata = KERN_INFO "YAM driver version 0.8 by F1OAT/F6FBB\n";
+static const char yam_drvinfo[] __initdata = KERN_INFO \
+	"YAM driver version 0.8 by F1OAT/F6FBB\n";
 
 /* --------------------------------------------------------------------- */
 


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

* [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string
@ 2009-02-14 21:33   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:33 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it fix an issue in 'mkiss_init_driver', where in case of an
error the status code was not passed to printk.

Fix this warnings:
  drivers/net/hamradio/6pack.c: In function 'sixpack_init_driver':
  drivers/net/hamradio/6pack.c:802: warning: format not a string literal and no format arguments
  drivers/net/hamradio/bpqether.c: In function 'bpq_init_driver':
  drivers/net/hamradio/bpqether.c:609: warning: format not a string literal and no format arguments
  drivers/net/hamradio/mkiss.c: In function 'mkiss_init_driver':
  drivers/net/hamradio/mkiss.c:988: warning: format not a string literal and no format arguments
  drivers/net/hamradio/mkiss.c:991: warning: format not a string literal and no format arguments
  drivers/net/hamradio/scc.c: In function 'scc_init_driver':
  drivers/net/hamradio/scc.c:2109: warning: format not a string literal and no format arguments
  drivers/net/hamradio/yam.c: In function 'yam_init_driver':
  drivers/net/hamradio/yam.c:1094: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/6pack.c    |    4 ++--
 drivers/net/hamradio/bpqether.c |    3 ++-
 drivers/net/hamradio/mkiss.c    |    9 +++++----
 drivers/net/hamradio/scc.c      |    3 ++-
 drivers/net/hamradio/yam.c      |    3 ++-
 5 files changed, 13 insertions(+), 9 deletions(-)

diff --git a/drivers/net/hamradio/6pack.c b/drivers/net/hamradio/6pack.c
index 3da9f39..1551600 100644
--- a/drivers/net/hamradio/6pack.c
+++ b/drivers/net/hamradio/6pack.c
@@ -790,9 +790,9 @@ static struct tty_ldisc_ops sp_ldisc = {
 
 /* Initialize 6pack control device -- register 6pack line discipline */
 
-static char msg_banner[]  __initdata = KERN_INFO \
+static const char msg_banner[]  __initdata = KERN_INFO \
 	"AX.25: 6pack driver, " SIXPACK_VERSION "\n";
-static char msg_regfail[] __initdata = KERN_ERR  \
+static const char msg_regfail[] __initdata = KERN_ERR  \
 	"6pack: can't register line discipline (err = %d)\n";
 
 static int __init sixpack_init_driver(void)
diff --git a/drivers/net/hamradio/bpqether.c b/drivers/net/hamradio/bpqether.c
index 2c619bc..723e9c1 100644
--- a/drivers/net/hamradio/bpqether.c
+++ b/drivers/net/hamradio/bpqether.c
@@ -87,7 +87,8 @@
 
 #include <linux/bpqether.h>
 
-static char banner[] __initdata = KERN_INFO "AX.25: bpqether driver version 004\n";
+static const char banner[] __initdata = KERN_INFO \
+	"AX.25: bpqether driver version 004\n";
 
 static char bcast_addr[6]={0xFF,0xFF,0xFF,0xFF,0xFF,0xFF};
 
diff --git a/drivers/net/hamradio/mkiss.c b/drivers/net/hamradio/mkiss.c
index ed5b37d..032c0db 100644
--- a/drivers/net/hamradio/mkiss.c
+++ b/drivers/net/hamradio/mkiss.c
@@ -976,9 +976,9 @@ static struct tty_ldisc_ops ax_ldisc = {
 	.write_wakeup	= mkiss_write_wakeup
 };
 
-static char banner[] __initdata = KERN_INFO \
+static const char banner[] __initdata = KERN_INFO \
 	"mkiss: AX.25 Multikiss, Hans Albas PE1AYX\n";
-static char msg_regfail[] __initdata = KERN_ERR \
+static const char msg_regfail[] __initdata = KERN_ERR \
 	"mkiss: can't register line discipline (err = %d)\n";
 
 static int __init mkiss_init_driver(void)
@@ -987,8 +987,9 @@ static int __init mkiss_init_driver(void)
 
 	printk(banner);
 
-	if ((status = tty_register_ldisc(N_AX25, &ax_ldisc)) != 0)
-		printk(msg_regfail);
+	status = tty_register_ldisc(N_AX25, &ax_ldisc);
+	if (status != 0)
+		printk(msg_regfail, status);
 
 	return status;
 }
diff --git a/drivers/net/hamradio/scc.c b/drivers/net/hamradio/scc.c
index 2acb18f..d712e7a 100644
--- a/drivers/net/hamradio/scc.c
+++ b/drivers/net/hamradio/scc.c
@@ -184,7 +184,8 @@
 
 #include "z8530.h"
 
-static char banner[] __initdata = KERN_INFO "AX.25: Z8530 SCC driver version "VERSION".dl1bke\n";
+static const char banner[] __initdata = KERN_INFO \
+	"AX.25: Z8530 SCC driver version "VERSION".dl1bke\n";
 
 static void t_dwait(unsigned long);
 static void t_txdelay(unsigned long);
diff --git a/drivers/net/hamradio/yam.c b/drivers/net/hamradio/yam.c
index 82a8be7..a54b865 100644
--- a/drivers/net/hamradio/yam.c
+++ b/drivers/net/hamradio/yam.c
@@ -77,7 +77,8 @@
 /* --------------------------------------------------------------------- */
 
 static const char yam_drvname[] = "yam";
-static char yam_drvinfo[] __initdata = KERN_INFO "YAM driver version 0.8 by F1OAT/F6FBB\n";
+static const char yam_drvinfo[] __initdata = KERN_INFO \
+	"YAM driver version 0.8 by F1OAT/F6FBB\n";
 
 /* --------------------------------------------------------------------- */
 


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

* [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context imbalance
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:34   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:34 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute functions with __acquires(...) resp. __releases(...).

Fix this sparse warnings:
  drivers/net/hamradio/bpqether.c:387:13: warning: context imbalance in 'bpq_seq_start' - wrong count at exit
  drivers/net/hamradio/bpqether.c:419:13: warning: context imbalance in 'bpq_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/bpqether.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/hamradio/bpqether.c b/drivers/net/hamradio/bpqether.c
index 723e9c1..44b183b 100644
--- a/drivers/net/hamradio/bpqether.c
+++ b/drivers/net/hamradio/bpqether.c
@@ -386,6 +386,7 @@ static int bpq_close(struct net_device *dev)
  *	Proc filesystem
  */
 static void *bpq_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(RCU)
 {
 	int i = 1;
 	struct bpqdev *bpqdev;
@@ -418,6 +419,7 @@ static void *bpq_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void bpq_seq_stop(struct seq_file *seq, void *v)
+	__releases(RCU)
 {
 	rcu_read_unlock();
 }


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

* [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context
@ 2009-02-14 21:34   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:34 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute functions with __acquires(...) resp. __releases(...).

Fix this sparse warnings:
  drivers/net/hamradio/bpqether.c:387:13: warning: context imbalance in 'bpq_seq_start' - wrong count at exit
  drivers/net/hamradio/bpqether.c:419:13: warning: context imbalance in 'bpq_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/bpqether.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/hamradio/bpqether.c b/drivers/net/hamradio/bpqether.c
index 723e9c1..44b183b 100644
--- a/drivers/net/hamradio/bpqether.c
+++ b/drivers/net/hamradio/bpqether.c
@@ -386,6 +386,7 @@ static int bpq_close(struct net_device *dev)
  *	Proc filesystem
  */
 static void *bpq_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(RCU)
 {
 	int i = 1;
 	struct bpqdev *bpqdev;
@@ -418,6 +419,7 @@ static void *bpq_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void bpq_seq_stop(struct seq_file *seq, void *v)
+	__releases(RCU)
 {
 	rcu_read_unlock();
 }


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

* [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:35   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:35 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename inner scrope variable.

Fix this sparse warning:
  drivers/net/hamradio/yam.c:856:35: warning: symbol 'dev' shadows an earlier one

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/yam.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/hamradio/yam.c b/drivers/net/hamradio/yam.c
index a54b865..500a40b 100644
--- a/drivers/net/hamradio/yam.c
+++ b/drivers/net/hamradio/yam.c
@@ -854,10 +854,10 @@ static int yam_open(struct net_device *dev)
 
 	/* Reset overruns for all ports - FPGA programming makes overruns */
 	for (i = 0; i < NR_PORTS; i++) {
-		struct net_device *dev = yam_devs[i];
+		struct net_device *yam_dev = yam_devs[i];
 
-		inb(LSR(dev->base_addr));
-		dev->stats.rx_fifo_errors = 0;
+		inb(LSR(yam_dev->base_addr));
+		yam_dev->stats.rx_fifo_errors = 0;
 	}
 
 	printk(KERN_INFO "%s at iobase 0x%lx irq %u uart %s\n", dev->name, dev->base_addr, dev->irq,


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

* [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol
@ 2009-02-14 21:35   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:35 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename inner scrope variable.

Fix this sparse warning:
  drivers/net/hamradio/yam.c:856:35: warning: symbol 'dev' shadows an earlier one

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/hamradio/yam.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/hamradio/yam.c b/drivers/net/hamradio/yam.c
index a54b865..500a40b 100644
--- a/drivers/net/hamradio/yam.c
+++ b/drivers/net/hamradio/yam.c
@@ -854,10 +854,10 @@ static int yam_open(struct net_device *dev)
 
 	/* Reset overruns for all ports - FPGA programming makes overruns */
 	for (i = 0; i < NR_PORTS; i++) {
-		struct net_device *dev = yam_devs[i];
+		struct net_device *yam_dev = yam_devs[i];
 
-		inb(LSR(dev->base_addr));
-		dev->stats.rx_fifo_errors = 0;
+		inb(LSR(yam_dev->base_addr));
+		yam_dev->stats.rx_fifo_errors = 0;
 	}
 
 	printk(KERN_INFO "%s at iobase 0x%lx irq %u uart %s\n", dev->name, dev->base_addr, dev->irq,


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

* [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:36   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:36 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/hamradio/hdlcdrv.c:274:34: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:279:47: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:288:39: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:300:47: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 include/linux/hdlcdrv.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/linux/hdlcdrv.h b/include/linux/hdlcdrv.h
index 0821bac..c010b4a 100644
--- a/include/linux/hdlcdrv.h
+++ b/include/linux/hdlcdrv.h
@@ -215,7 +215,7 @@ struct hdlcdrv_state {
 
 	struct hdlcdrv_hdlctx {
 		struct hdlcdrv_hdlcbuffer hbuf;
-		long in_hdlc_tx;
+		unsigned long in_hdlc_tx;
 		/*
 		 * 0 = send flags
 		 * 1 = send txtail (flags)


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

* [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix
@ 2009-02-14 21:36   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:36 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/hamradio/hdlcdrv.c:274:34: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:279:47: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:288:39: warning: incorrect type in argument 2 (different signedness)
  drivers/net/hamradio/hdlcdrv.c:300:47: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 include/linux/hdlcdrv.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/linux/hdlcdrv.h b/include/linux/hdlcdrv.h
index 0821bac..c010b4a 100644
--- a/include/linux/hdlcdrv.h
+++ b/include/linux/hdlcdrv.h
@@ -215,7 +215,7 @@ struct hdlcdrv_state {
 
 	struct hdlcdrv_hdlctx {
 		struct hdlcdrv_hdlcbuffer hbuf;
-		long in_hdlc_tx;
+		unsigned long in_hdlc_tx;
 		/*
 		 * 0 = send flags
 		 * 1 = send txtail (flags)


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

* [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:38   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:38 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as far inner as possible.

Fix this sparse warning:
  drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
  drivers/net/igb/igb_main.c:1855:16: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/igb/igb_main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index f8c2919..1885e20 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -1852,7 +1852,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	struct e1000_hw *hw = &adapter->hw;
 	u32 rctl, rxcsum;
 	u32 rxdctl;
-	int i, j;
+	int i;
 
 	/* disable receives while setting up the descriptors */
 	rctl = rd32(E1000_RCTL);
@@ -1867,7 +1867,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	 * the Base and Length of the Rx Descriptor Ring */
 	for (i = 0; i < adapter->num_rx_queues; i++) {
 		struct igb_ring *ring = &(adapter->rx_ring[i]);
-		j = ring->reg_idx;
+		int j = ring->reg_idx;
 		rdba = ring->dma;
 		wr32(E1000_RDBAL(j),
 				rdba & 0x00000000ffffffffULL);


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

* [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an
@ 2009-02-14 21:38   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:38 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as far inner as possible.

Fix this sparse warning:
  drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
  drivers/net/igb/igb_main.c:1855:16: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/igb/igb_main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index f8c2919..1885e20 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -1852,7 +1852,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	struct e1000_hw *hw = &adapter->hw;
 	u32 rctl, rxcsum;
 	u32 rxdctl;
-	int i, j;
+	int i;
 
 	/* disable receives while setting up the descriptors */
 	rctl = rd32(E1000_RCTL);
@@ -1867,7 +1867,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	 * the Base and Length of the Rx Descriptor Ring */
 	for (i = 0; i < adapter->num_rx_queues; i++) {
 		struct igb_ring *ring = &(adapter->rx_ring[i]);
-		j = ring->reg_idx;
+		int j = ring->reg_idx;
 		rdba = ring->dma;
 		wr32(E1000_RDBAL(j),
 				rdba & 0x00000000ffffffffULL);


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

* [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:38   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:38 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbol static.

Fix this sparse warning:
  drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ixgbe/ixgbe_82598.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/ixgbe/ixgbe_82598.c b/drivers/net/ixgbe/ixgbe_82598.c
index 525bd87..51dba1c 100644
--- a/drivers/net/ixgbe/ixgbe_82598.c
+++ b/drivers/net/ixgbe/ixgbe_82598.c
@@ -56,7 +56,7 @@ static s32 ixgbe_read_i2c_eeprom_82598(struct ixgbe_hw *hw, u8 byte_offset,
  *  Read PCIe configuration space, and get the MSI-X vector count from
  *  the capabilities table.
  **/
-u16 ixgbe_get_pcie_msix_count_82598(struct ixgbe_hw *hw)
+static u16 ixgbe_get_pcie_msix_count_82598(struct ixgbe_hw *hw)
 {
 	struct ixgbe_adapter *adapter = hw->back;
 	u16 msix_count;


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

* [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be
@ 2009-02-14 21:38   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:38 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbol static.

Fix this sparse warning:
  drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/ixgbe/ixgbe_82598.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/ixgbe/ixgbe_82598.c b/drivers/net/ixgbe/ixgbe_82598.c
index 525bd87..51dba1c 100644
--- a/drivers/net/ixgbe/ixgbe_82598.c
+++ b/drivers/net/ixgbe/ixgbe_82598.c
@@ -56,7 +56,7 @@ static s32 ixgbe_read_i2c_eeprom_82598(struct ixgbe_hw *hw, u8 byte_offset,
  *  Read PCIe configuration space, and get the MSI-X vector count from
  *  the capabilities table.
  **/
-u16 ixgbe_get_pcie_msix_count_82598(struct ixgbe_hw *hw)
+static u16 ixgbe_get_pcie_msix_count_82598(struct ixgbe_hw *hw)
 {
 	struct ixgbe_adapter *adapter = hw->back;
 	u16 msix_count;


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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
  2009-02-14 21:29     ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
@ 2009-02-14 21:38       ` Cyrill Gorcunov
  -1 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-14 21:38 UTC (permalink / raw)
  To: Hannes Eder, netdev, kernel-janitors, linux-kernel

[Cyrill Gorcunov - Sun, Feb 15, 2009 at 12:29:48AM +0300]
| [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
| | Fix this sparse warnings:
| |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
| |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
| |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
| | 
| | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
| ...
| 
| Thanks Hannes,
| 
| Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
| 
| 	- Cyrill -

Btw I think the same fix could be applied on
drivers/net/tun.c (if you have time for :)

	- Cyrill -

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix
@ 2009-02-14 21:38       ` Cyrill Gorcunov
  0 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-14 21:38 UTC (permalink / raw)
  To: Hannes Eder, netdev, kernel-janitors, linux-kernel

[Cyrill Gorcunov - Sun, Feb 15, 2009 at 12:29:48AM +0300]
| [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
| | Fix this sparse warnings:
| |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
| |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
| |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
| | 
| | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
| ...
| 
| Thanks Hannes,
| 
| Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
| 
| 	- Cyrill -

Btw I think the same fix could be applied on
drivers/net/tun.c (if you have time for :)

	- Cyrill -

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

* [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:39   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:39 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it prefix the message with KERN_INFO.

Fix this warnings:
  drivers/net/pcmcia/axnet_cs.c:1716: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/pcmcia/axnet_cs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/pcmcia/axnet_cs.c b/drivers/net/pcmcia/axnet_cs.c
index 0afa720..871ad29 100644
--- a/drivers/net/pcmcia/axnet_cs.c
+++ b/drivers/net/pcmcia/axnet_cs.c
@@ -861,7 +861,7 @@ module_exit(exit_axnet_cs);
 
   */
 
-static const char *version_8390 =
+static const char version_8390[] = KERN_INFO \
     "8390.c:v1.10cvs 9/23/94 Donald Becker (becker@scyld.com)\n";
 
 #include <linux/bitops.h>


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

* [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string
@ 2009-02-14 21:39   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:39 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it prefix the message with KERN_INFO.

Fix this warnings:
  drivers/net/pcmcia/axnet_cs.c:1716: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/pcmcia/axnet_cs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/pcmcia/axnet_cs.c b/drivers/net/pcmcia/axnet_cs.c
index 0afa720..871ad29 100644
--- a/drivers/net/pcmcia/axnet_cs.c
+++ b/drivers/net/pcmcia/axnet_cs.c
@@ -861,7 +861,7 @@ module_exit(exit_axnet_cs);
 
   */
 
-static const char *version_8390 +static const char version_8390[] = KERN_INFO \
     "8390.c:v1.10cvs 9/23/94 Donald Becker (becker@scyld.com)\n";
 
 #include <linux/bitops.h>


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

* [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:41   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:41 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as close to their usage as possible.

Fix this sparse warning:
  drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
  drivers/net/sfc/tenxpress.c:575:30: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/tenxpress.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/net/sfc/tenxpress.c b/drivers/net/sfc/tenxpress.c
index ac9eeab..5b0f451 100644
--- a/drivers/net/sfc/tenxpress.c
+++ b/drivers/net/sfc/tenxpress.c
@@ -572,15 +572,14 @@ static void tenxpress_phy_reconfigure(struct efx_nic *efx)
 static void tenxpress_phy_poll(struct efx_nic *efx)
 {
 	struct tenxpress_phy_data *phy_data = efx->phy_data;
-	bool change = false, link_ok;
-	unsigned link_fc;
+	bool change = false;
 
 	if (efx->phy_type == PHY_TYPE_SFX7101) {
-		link_ok = sfx7101_link_ok(efx);
+		bool link_ok = sfx7101_link_ok(efx);
 		if (link_ok != efx->link_up) {
 			change = true;
 		} else {
-			link_fc = mdio_clause45_get_pause(efx);
+			unsigned int link_fc = mdio_clause45_get_pause(efx);
 			if (link_fc != efx->link_fc)
 				change = true;
 		}


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

* [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an
@ 2009-02-14 21:41   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:41 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move variable declaration as close to their usage as possible.

Fix this sparse warning:
  drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
  drivers/net/sfc/tenxpress.c:575:30: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/tenxpress.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/net/sfc/tenxpress.c b/drivers/net/sfc/tenxpress.c
index ac9eeab..5b0f451 100644
--- a/drivers/net/sfc/tenxpress.c
+++ b/drivers/net/sfc/tenxpress.c
@@ -572,15 +572,14 @@ static void tenxpress_phy_reconfigure(struct efx_nic *efx)
 static void tenxpress_phy_poll(struct efx_nic *efx)
 {
 	struct tenxpress_phy_data *phy_data = efx->phy_data;
-	bool change = false, link_ok;
-	unsigned link_fc;
+	bool change = false;
 
 	if (efx->phy_type = PHY_TYPE_SFX7101) {
-		link_ok = sfx7101_link_ok(efx);
+		bool link_ok = sfx7101_link_ok(efx);
 		if (link_ok != efx->link_up) {
 			change = true;
 		} else {
-			link_fc = mdio_clause45_get_pause(efx);
+			unsigned int link_fc = mdio_clause45_get_pause(efx);
 			if (link_fc != efx->link_fc)
 				change = true;
 		}


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

* [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:42   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:42 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Include header file and include the function under the same
condition as in the header file.  If CONFIG_SFS_MTD is not defined
than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
'static inline' with an empty function body in the header file.

Fix this sparse warnings:
  drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/mtd.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
index 665cafb..94c9ed8 100644
--- a/drivers/net/sfc/mtd.c
+++ b/drivers/net/sfc/mtd.c
@@ -15,6 +15,7 @@
 #define EFX_DRIVER_NAME "sfc_mtd"
 #include "net_driver.h"
 #include "spi.h"
+#include "efx.h"
 
 #define EFX_SPI_VERIFY_BUF_LEN 16
 
@@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
 	return;
 }
 
+#ifdef CONFIG_SFC_MTD
 void efx_mtd_remove(struct efx_nic *efx)
 {
 	if (efx->spi_flash && efx->spi_flash->mtd) {
@@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
 
 	return 0;
 }
+#endif /* CONFIG_SFC_MTD */


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

* [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be
@ 2009-02-14 21:42   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:42 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Include header file and include the function under the same
condition as in the header file.  If CONFIG_SFS_MTD is not defined
than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
'static inline' with an empty function body in the header file.

Fix this sparse warnings:
  drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/mtd.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
index 665cafb..94c9ed8 100644
--- a/drivers/net/sfc/mtd.c
+++ b/drivers/net/sfc/mtd.c
@@ -15,6 +15,7 @@
 #define EFX_DRIVER_NAME "sfc_mtd"
 #include "net_driver.h"
 #include "spi.h"
+#include "efx.h"
 
 #define EFX_SPI_VERIFY_BUF_LEN 16
 
@@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
 	return;
 }
 
+#ifdef CONFIG_SFC_MTD
 void efx_mtd_remove(struct efx_nic *efx)
 {
 	if (efx->spi_flash && efx->spi_flash->mtd) {
@@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
 
 	return 0;
 }
+#endif /* CONFIG_SFC_MTD */


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

* [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:43   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:43 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move function declarations to header file.

Fix this sparse warnings:
  drivers/net/skfp/cfm.c:146:6: warning: symbol 'all_selection_criteria' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:186:6: warning: symbol 'mac1_irq' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:284:6: warning: symbol 'read_address' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:323:6: warning: symbol 'init_board' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:72:24: warning: symbol 'fddi_broadcast' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:679:6: warning: symbol 'mac2_irq' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:805:6: warning: symbol 'mac3_irq' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:856:5: warning: symbol 'init_fplus' was not declared. Should it be static?
  drivers/net/skfp/pcmplc.c:404:6: warning: symbol 'init_plc' was not declared. Should it be static?
  drivers/net/skfp/pcmplc.c:1592:5: warning: symbol 'pcm_status_twisted' was not declared. Should it be static?
  drivers/net/skfp/smtinit.c:68:5: warning: symbol 'init_smt' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/skfp/h/smc.h  |   17 +++++++++++++++++
 drivers/net/skfp/hwmtm.c  |    9 ---------
 drivers/net/skfp/pcmplc.c |    3 ---
 drivers/net/skfp/skfddi.c |    3 ---
 drivers/net/skfp/smt.c    |   10 ----------
 5 files changed, 17 insertions(+), 25 deletions(-)

diff --git a/drivers/net/skfp/h/smc.h b/drivers/net/skfp/h/smc.h
index 9432591..1758d95 100644
--- a/drivers/net/skfp/h/smc.h
+++ b/drivers/net/skfp/h/smc.h
@@ -467,5 +467,22 @@ struct s_smc {
 #endif	/* DEBUG_BRD && DEBUG */
 } ;
 
+extern const struct fddi_addr fddi_broadcast;
+
+extern void all_selection_criteria(struct s_smc *smc);
+extern void card_stop(struct s_smc *smc);
+extern void init_board(struct s_smc *smc, u_char *mac_addr);
+extern int init_fplus(struct s_smc *smc);
+extern void init_plc(struct s_smc *smc);
+extern int init_smt(struct s_smc *smc, u_char * mac_addr);
+extern void mac1_irq(struct s_smc *smc, u_short stu, u_short stl);
+extern void mac2_irq(struct s_smc *smc, u_short code_s2u, u_short code_s2l);
+extern void mac3_irq(struct s_smc *smc, u_short code_s3u, u_short code_s3l);
+extern int pcm_status_twisted(struct s_smc *smc);
+extern void plc1_irq(struct s_smc *smc);
+extern void plc2_irq(struct s_smc *smc);
+extern void read_address(struct s_smc *smc, u_char * mac_addr);
+extern void timer_irq(struct s_smc *smc);
+
 #endif	/* _SCMECM_ */
 
diff --git a/drivers/net/skfp/hwmtm.c b/drivers/net/skfp/hwmtm.c
index 4218e97..d322f1b 100644
--- a/drivers/net/skfp/hwmtm.c
+++ b/drivers/net/skfp/hwmtm.c
@@ -97,23 +97,15 @@ static void mac_drv_clear_txd(struct s_smc *smc);
 
 extern void* mac_drv_get_space(struct s_smc *smc, unsigned int size);
 extern void* mac_drv_get_desc_mem(struct s_smc *smc, unsigned int size);
-extern void init_board(struct s_smc *smc, u_char *mac_addr);
 extern void mac_drv_fill_rxd(struct s_smc *smc);
-extern void plc1_irq(struct s_smc *smc);
 extern void mac_drv_tx_complete(struct s_smc *smc,
 				volatile struct s_smt_fp_txd *txd);
-extern void plc2_irq(struct s_smc *smc);
-extern void mac1_irq(struct s_smc *smc, u_short stu, u_short stl);
-extern void mac2_irq(struct s_smc *smc, u_short code_s2u, u_short code_s2l);
-extern void mac3_irq(struct s_smc *smc, u_short code_s3u, u_short code_s3l);
-extern void timer_irq(struct s_smc *smc);
 extern void mac_drv_rx_complete(struct s_smc *smc,
 				volatile struct s_smt_fp_rxd *rxd,
 				int frag_count, int len);
 extern void mac_drv_requeue_rxd(struct s_smc *smc, 
 				volatile struct s_smt_fp_rxd *rxd,
 				int frag_count);
-extern void init_plc(struct s_smc *smc);
 extern void mac_drv_clear_rxd(struct s_smc *smc,
 			      volatile struct s_smt_fp_rxd *rxd, int frag_count);
 
@@ -136,7 +128,6 @@ extern void dma_complete(struct s_smc *smc, volatile union s_fp_descr *descr,
 			 int flag);
 #endif
 
-extern int init_fplus(struct s_smc *smc);
 extern int mac_drv_rx_init(struct s_smc *smc, int len, int fc, char *look_ahead,
 			   int la_len);
 
diff --git a/drivers/net/skfp/pcmplc.c b/drivers/net/skfp/pcmplc.c
index 74e129f..f1df2ec 100644
--- a/drivers/net/skfp/pcmplc.c
+++ b/drivers/net/skfp/pcmplc.c
@@ -198,9 +198,6 @@ static int plc_imsk_na = PL_PCM_CODE | PL_TRACE_PROP | PL_PCM_BREAK |
 static const int plc_imsk_act = PL_PCM_CODE | PL_TRACE_PROP | PL_PCM_BREAK |
 			PL_PCM_ENABLED | PL_SELF_TEST | PL_EBUF_ERR;
 
-/* external functions */
-void all_selection_criteria(struct s_smc *smc);
-
 /* internal functions */
 static void pcm_fsm(struct s_smc *smc, struct s_phy *phy, int cmd);
 static void pc_rcode_actions(struct s_smc *smc, int bit, struct s_phy *phy);
diff --git a/drivers/net/skfp/skfddi.c b/drivers/net/skfp/skfddi.c
index 9a00e55..e14aec0 100644
--- a/drivers/net/skfp/skfddi.c
+++ b/drivers/net/skfp/skfddi.c
@@ -135,14 +135,11 @@ void dump_data(unsigned char *Data, int length);
 
 // External functions from the hardware module
 extern u_int mac_drv_check_space(void);
-extern void read_address(struct s_smc *smc, u_char * mac_addr);
-extern void card_stop(struct s_smc *smc);
 extern int mac_drv_init(struct s_smc *smc);
 extern void hwm_tx_frag(struct s_smc *smc, char far * virt, u_long phys,
 			int len, int frame_status);
 extern int hwm_tx_init(struct s_smc *smc, u_char fc, int frag_count,
 		       int frame_len, int frame_status);
-extern int init_smt(struct s_smc *smc, u_char * mac_addr);
 extern void fddi_isr(struct s_smc *smc);
 extern void hwm_rx_frag(struct s_smc *smc, char far * virt, u_long phys,
 			int len, int frame_status);
diff --git a/drivers/net/skfp/smt.c b/drivers/net/skfp/smt.c
index 805383b..83d16fe 100644
--- a/drivers/net/skfp/smt.c
+++ b/drivers/net/skfp/smt.c
@@ -55,16 +55,6 @@ static const struct fddi_addr SMT_Unknown = {
 } ;
 
 /*
- * external variables
- */
-extern const struct fddi_addr fddi_broadcast ;
-
-/*
- * external functions
- */
-int pcm_status_twisted(struct s_smc *smc);
-
-/*
  * function prototypes
  */
 #ifdef	LITTLE_ENDIAN


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

* [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be
@ 2009-02-14 21:43   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:43 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Move function declarations to header file.

Fix this sparse warnings:
  drivers/net/skfp/cfm.c:146:6: warning: symbol 'all_selection_criteria' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:186:6: warning: symbol 'mac1_irq' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:284:6: warning: symbol 'read_address' was not declared. Should it be static?
  drivers/net/skfp/drvfbi.c:323:6: warning: symbol 'init_board' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:72:24: warning: symbol 'fddi_broadcast' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:679:6: warning: symbol 'mac2_irq' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:805:6: warning: symbol 'mac3_irq' was not declared. Should it be static?
  drivers/net/skfp/fplustm.c:856:5: warning: symbol 'init_fplus' was not declared. Should it be static?
  drivers/net/skfp/pcmplc.c:404:6: warning: symbol 'init_plc' was not declared. Should it be static?
  drivers/net/skfp/pcmplc.c:1592:5: warning: symbol 'pcm_status_twisted' was not declared. Should it be static?
  drivers/net/skfp/smtinit.c:68:5: warning: symbol 'init_smt' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/skfp/h/smc.h  |   17 +++++++++++++++++
 drivers/net/skfp/hwmtm.c  |    9 ---------
 drivers/net/skfp/pcmplc.c |    3 ---
 drivers/net/skfp/skfddi.c |    3 ---
 drivers/net/skfp/smt.c    |   10 ----------
 5 files changed, 17 insertions(+), 25 deletions(-)

diff --git a/drivers/net/skfp/h/smc.h b/drivers/net/skfp/h/smc.h
index 9432591..1758d95 100644
--- a/drivers/net/skfp/h/smc.h
+++ b/drivers/net/skfp/h/smc.h
@@ -467,5 +467,22 @@ struct s_smc {
 #endif	/* DEBUG_BRD && DEBUG */
 } ;
 
+extern const struct fddi_addr fddi_broadcast;
+
+extern void all_selection_criteria(struct s_smc *smc);
+extern void card_stop(struct s_smc *smc);
+extern void init_board(struct s_smc *smc, u_char *mac_addr);
+extern int init_fplus(struct s_smc *smc);
+extern void init_plc(struct s_smc *smc);
+extern int init_smt(struct s_smc *smc, u_char * mac_addr);
+extern void mac1_irq(struct s_smc *smc, u_short stu, u_short stl);
+extern void mac2_irq(struct s_smc *smc, u_short code_s2u, u_short code_s2l);
+extern void mac3_irq(struct s_smc *smc, u_short code_s3u, u_short code_s3l);
+extern int pcm_status_twisted(struct s_smc *smc);
+extern void plc1_irq(struct s_smc *smc);
+extern void plc2_irq(struct s_smc *smc);
+extern void read_address(struct s_smc *smc, u_char * mac_addr);
+extern void timer_irq(struct s_smc *smc);
+
 #endif	/* _SCMECM_ */
 
diff --git a/drivers/net/skfp/hwmtm.c b/drivers/net/skfp/hwmtm.c
index 4218e97..d322f1b 100644
--- a/drivers/net/skfp/hwmtm.c
+++ b/drivers/net/skfp/hwmtm.c
@@ -97,23 +97,15 @@ static void mac_drv_clear_txd(struct s_smc *smc);
 
 extern void* mac_drv_get_space(struct s_smc *smc, unsigned int size);
 extern void* mac_drv_get_desc_mem(struct s_smc *smc, unsigned int size);
-extern void init_board(struct s_smc *smc, u_char *mac_addr);
 extern void mac_drv_fill_rxd(struct s_smc *smc);
-extern void plc1_irq(struct s_smc *smc);
 extern void mac_drv_tx_complete(struct s_smc *smc,
 				volatile struct s_smt_fp_txd *txd);
-extern void plc2_irq(struct s_smc *smc);
-extern void mac1_irq(struct s_smc *smc, u_short stu, u_short stl);
-extern void mac2_irq(struct s_smc *smc, u_short code_s2u, u_short code_s2l);
-extern void mac3_irq(struct s_smc *smc, u_short code_s3u, u_short code_s3l);
-extern void timer_irq(struct s_smc *smc);
 extern void mac_drv_rx_complete(struct s_smc *smc,
 				volatile struct s_smt_fp_rxd *rxd,
 				int frag_count, int len);
 extern void mac_drv_requeue_rxd(struct s_smc *smc, 
 				volatile struct s_smt_fp_rxd *rxd,
 				int frag_count);
-extern void init_plc(struct s_smc *smc);
 extern void mac_drv_clear_rxd(struct s_smc *smc,
 			      volatile struct s_smt_fp_rxd *rxd, int frag_count);
 
@@ -136,7 +128,6 @@ extern void dma_complete(struct s_smc *smc, volatile union s_fp_descr *descr,
 			 int flag);
 #endif
 
-extern int init_fplus(struct s_smc *smc);
 extern int mac_drv_rx_init(struct s_smc *smc, int len, int fc, char *look_ahead,
 			   int la_len);
 
diff --git a/drivers/net/skfp/pcmplc.c b/drivers/net/skfp/pcmplc.c
index 74e129f..f1df2ec 100644
--- a/drivers/net/skfp/pcmplc.c
+++ b/drivers/net/skfp/pcmplc.c
@@ -198,9 +198,6 @@ static int plc_imsk_na = PL_PCM_CODE | PL_TRACE_PROP | PL_PCM_BREAK |
 static const int plc_imsk_act = PL_PCM_CODE | PL_TRACE_PROP | PL_PCM_BREAK |
 			PL_PCM_ENABLED | PL_SELF_TEST | PL_EBUF_ERR;
 
-/* external functions */
-void all_selection_criteria(struct s_smc *smc);
-
 /* internal functions */
 static void pcm_fsm(struct s_smc *smc, struct s_phy *phy, int cmd);
 static void pc_rcode_actions(struct s_smc *smc, int bit, struct s_phy *phy);
diff --git a/drivers/net/skfp/skfddi.c b/drivers/net/skfp/skfddi.c
index 9a00e55..e14aec0 100644
--- a/drivers/net/skfp/skfddi.c
+++ b/drivers/net/skfp/skfddi.c
@@ -135,14 +135,11 @@ void dump_data(unsigned char *Data, int length);
 
 // External functions from the hardware module
 extern u_int mac_drv_check_space(void);
-extern void read_address(struct s_smc *smc, u_char * mac_addr);
-extern void card_stop(struct s_smc *smc);
 extern int mac_drv_init(struct s_smc *smc);
 extern void hwm_tx_frag(struct s_smc *smc, char far * virt, u_long phys,
 			int len, int frame_status);
 extern int hwm_tx_init(struct s_smc *smc, u_char fc, int frag_count,
 		       int frame_len, int frame_status);
-extern int init_smt(struct s_smc *smc, u_char * mac_addr);
 extern void fddi_isr(struct s_smc *smc);
 extern void hwm_rx_frag(struct s_smc *smc, char far * virt, u_long phys,
 			int len, int frame_status);
diff --git a/drivers/net/skfp/smt.c b/drivers/net/skfp/smt.c
index 805383b..83d16fe 100644
--- a/drivers/net/skfp/smt.c
+++ b/drivers/net/skfp/smt.c
@@ -55,16 +55,6 @@ static const struct fddi_addr SMT_Unknown = {
 } ;
 
 /*
- * external variables
- */
-extern const struct fddi_addr fddi_broadcast ;
-
-/*
- * external functions
- */
-int pcm_status_twisted(struct s_smc *smc);
-
-/*
  * function prototypes
  */
 #ifdef	LITTLE_ENDIAN


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

* [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:44   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:44 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]'.

Fix this warnings:
  drivers/net/tokenring/smctr.c:3644: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/smctr.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
index 50eb29c..5a3ff20 100644
--- a/drivers/net/tokenring/smctr.c
+++ b/drivers/net/tokenring/smctr.c
@@ -61,7 +61,8 @@
 
 #include "smctr.h"               /* Our Stuff */
 
-static char version[] __initdata = KERN_INFO "smctr.c: v1.4 7/12/00 by jschlst@samba.org\n";
+static const char version[] __initdata =
+	KERN_INFO "smctr.c: v1.4 7/12/00 by jschlst@samba.org\n";
 static const char cardname[] = "smctr";
 
 


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

* [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string
@ 2009-02-14 21:44   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:44 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]'.

Fix this warnings:
  drivers/net/tokenring/smctr.c:3644: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/smctr.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
index 50eb29c..5a3ff20 100644
--- a/drivers/net/tokenring/smctr.c
+++ b/drivers/net/tokenring/smctr.c
@@ -61,7 +61,8 @@
 
 #include "smctr.h"               /* Our Stuff */
 
-static char version[] __initdata = KERN_INFO "smctr.c: v1.4 7/12/00 by jschlst@samba.org\n";
+static const char version[] __initdata +	KERN_INFO "smctr.c: v1.4 7/12/00 by jschlst@samba.org\n";
 static const char cardname[] = "smctr";
 
 


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

* [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:44   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:44 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant variables.

Fix this sparse warnings:
  drivers/net/tokenring/lanstreamer.c:619:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tokenring/lanstreamer.c:589:13: originally declared here
  drivers/net/tokenring/madgemc.c:695:34: warning: symbol 'tp' shadows an earlier one
  drivers/net/tokenring/madgemc.c:689:26: originally declared here
  drivers/net/tokenring/olympic.c:702:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tokenring/olympic.c:440:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/lanstreamer.c |    2 --
 drivers/net/tokenring/madgemc.c     |    2 --
 drivers/net/tokenring/olympic.c     |    1 -
 3 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/drivers/net/tokenring/lanstreamer.c b/drivers/net/tokenring/lanstreamer.c
index 0b2b792..f309b8f 100644
--- a/drivers/net/tokenring/lanstreamer.c
+++ b/drivers/net/tokenring/lanstreamer.c
@@ -616,8 +616,6 @@ static int streamer_open(struct net_device *dev)
 	printk("SISR Mask = %04x\n", readw(streamer_mmio + SISR_MASK));
 #endif
 	do {
-		int i;
-
 		for (i = 0; i < SRB_COMMAND_SIZE; i += 2) {
 			writew(0, streamer_mmio + LAPDINC);
 		}
diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/madgemc.c
index 917b4d2..1933081 100644
--- a/drivers/net/tokenring/madgemc.c
+++ b/drivers/net/tokenring/madgemc.c
@@ -692,8 +692,6 @@ static int madgemc_mcaproc(char *buf, int slot, void *d)
 	
 	len += sprintf(buf+len, "-------\n");
 	if (curcard) {
-		struct net_local *tp = netdev_priv(dev);
-		
 		len += sprintf(buf+len, "Card Revision: %d\n", curcard->cardrev);
 		len += sprintf(buf+len, "RAM Size: %dkb\n", curcard->ramsize);
 		len += sprintf(buf+len, "Cable type: %s\n", (curcard->cabletype)?"STP/DB9":"UTP/RJ-45");
diff --git a/drivers/net/tokenring/olympic.c b/drivers/net/tokenring/olympic.c
index 77dc9da..d068a9d 100644
--- a/drivers/net/tokenring/olympic.c
+++ b/drivers/net/tokenring/olympic.c
@@ -699,7 +699,6 @@ static int olympic_open(struct net_device *dev)
 	if (olympic_priv->olympic_network_monitor) { 
 		u8 __iomem *oat;
 		u8 __iomem *opt;
-		int i;
 		u8 addr[6];
 		oat = (olympic_priv->olympic_lap + olympic_priv->olympic_addr_table_addr);
 		opt = (olympic_priv->olympic_lap + olympic_priv->olympic_parms_addr);


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

* [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol
@ 2009-02-14 21:44   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:44 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Remove redundant variables.

Fix this sparse warnings:
  drivers/net/tokenring/lanstreamer.c:619:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tokenring/lanstreamer.c:589:13: originally declared here
  drivers/net/tokenring/madgemc.c:695:34: warning: symbol 'tp' shadows an earlier one
  drivers/net/tokenring/madgemc.c:689:26: originally declared here
  drivers/net/tokenring/olympic.c:702:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tokenring/olympic.c:440:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/lanstreamer.c |    2 --
 drivers/net/tokenring/madgemc.c     |    2 --
 drivers/net/tokenring/olympic.c     |    1 -
 3 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/drivers/net/tokenring/lanstreamer.c b/drivers/net/tokenring/lanstreamer.c
index 0b2b792..f309b8f 100644
--- a/drivers/net/tokenring/lanstreamer.c
+++ b/drivers/net/tokenring/lanstreamer.c
@@ -616,8 +616,6 @@ static int streamer_open(struct net_device *dev)
 	printk("SISR Mask = %04x\n", readw(streamer_mmio + SISR_MASK));
 #endif
 	do {
-		int i;
-
 		for (i = 0; i < SRB_COMMAND_SIZE; i += 2) {
 			writew(0, streamer_mmio + LAPDINC);
 		}
diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/madgemc.c
index 917b4d2..1933081 100644
--- a/drivers/net/tokenring/madgemc.c
+++ b/drivers/net/tokenring/madgemc.c
@@ -692,8 +692,6 @@ static int madgemc_mcaproc(char *buf, int slot, void *d)
 	
 	len += sprintf(buf+len, "-------\n");
 	if (curcard) {
-		struct net_local *tp = netdev_priv(dev);
-		
 		len += sprintf(buf+len, "Card Revision: %d\n", curcard->cardrev);
 		len += sprintf(buf+len, "RAM Size: %dkb\n", curcard->ramsize);
 		len += sprintf(buf+len, "Cable type: %s\n", (curcard->cabletype)?"STP/DB9":"UTP/RJ-45");
diff --git a/drivers/net/tokenring/olympic.c b/drivers/net/tokenring/olympic.c
index 77dc9da..d068a9d 100644
--- a/drivers/net/tokenring/olympic.c
+++ b/drivers/net/tokenring/olympic.c
@@ -699,7 +699,6 @@ static int olympic_open(struct net_device *dev)
 	if (olympic_priv->olympic_network_monitor) { 
 		u8 __iomem *oat;
 		u8 __iomem *opt;
-		int i;
 		u8 addr[6];
 		oat = (olympic_priv->olympic_lap + olympic_priv->olympic_addr_table_addr);
 		opt = (olympic_priv->olympic_lap + olympic_priv->olympic_parms_addr);


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

* [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:46   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:46 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.

Fix this sparse warnings:
  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

Should the members be rearranged to avoid un-aligned access?

 drivers/net/tokenring/smctr.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
index 52df7dd..d98bc5b 100644
--- a/drivers/net/tokenring/smctr.h
+++ b/drivers/net/tokenring/smctr.h
@@ -977,7 +977,7 @@ typedef struct net_local {
 	__u8		monitor_state_ready;
 	__u16		ring_status;
 	__u8		ring_status_flags;
-	__u8		current_ring_status;
+	__u16		current_ring_status;
 	__u8		state;
 
 	__u8		join_state;


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

* [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast
@ 2009-02-14 21:46   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:46 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.

Fix this sparse warnings:
  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

Should the members be rearranged to avoid un-aligned access?

 drivers/net/tokenring/smctr.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
index 52df7dd..d98bc5b 100644
--- a/drivers/net/tokenring/smctr.h
+++ b/drivers/net/tokenring/smctr.h
@@ -977,7 +977,7 @@ typedef struct net_local {
 	__u8		monitor_state_ready;
 	__u16		ring_status;
 	__u8		ring_status_flags;
-	__u8		current_ring_status;
+	__u16		current_ring_status;
 	__u8		state;
 
 	__u8		join_state;


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

* [PATCH 32/43] drivers/net/tulip: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:46   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:46 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it add a KERN_INFO prefix.

Fix this warning:
  drivers/net/tulip/de4x5.c: In function 'de4x5_hw_init':
  drivers/net/tulip/de4x5.c:1268: warning: format not a string literal and no format arguments
  drivers/net/tulip/winbond-840.c: In function 'w840_init':
  drivers/net/tulip/winbond-840.c:1666: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tulip/de4x5.c       |    3 ++-
 drivers/net/tulip/winbond-840.c |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c
index 6418f74..98e8682 100644
--- a/drivers/net/tulip/de4x5.c
+++ b/drivers/net/tulip/de4x5.c
@@ -479,7 +479,8 @@
 
 #include "de4x5.h"
 
-static char version[] __devinitdata = "de4x5.c:V0.546 2001/02/22 davies@maniac.ultranet.com\n";
+static const char version[] __devinitdata =
+	KERN_INFO "de4x5.c:V0.546 2001/02/22 davies@maniac.ultranet.com\n";
 
 #define c_char const char
 
diff --git a/drivers/net/tulip/winbond-840.c b/drivers/net/tulip/winbond-840.c
index f467bf8..426b7c7 100644
--- a/drivers/net/tulip/winbond-840.c
+++ b/drivers/net/tulip/winbond-840.c
@@ -139,7 +139,7 @@ static int full_duplex[MAX_UNITS] = {-1, -1, -1, -1, -1, -1, -1, -1};
 #define PKT_BUF_SZ		1536	/* Size of each temporary Rx buffer.*/
 
 /* These identify the driver base version and may not be removed. */
-static char version[] =
+static const char version[] __initdata =
 KERN_INFO DRV_NAME ".c:v" DRV_VERSION " (2.4 port) " DRV_RELDATE "  Donald Becker <becker@scyld.com>\n"
 KERN_INFO "  http://www.scyld.com/network/drivers.html\n";
 


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

* [PATCH 32/43] drivers/net/tulip: fix warning: format not a string
@ 2009-02-14 21:46   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:46 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]' and while
being at it add a KERN_INFO prefix.

Fix this warning:
  drivers/net/tulip/de4x5.c: In function 'de4x5_hw_init':
  drivers/net/tulip/de4x5.c:1268: warning: format not a string literal and no format arguments
  drivers/net/tulip/winbond-840.c: In function 'w840_init':
  drivers/net/tulip/winbond-840.c:1666: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tulip/de4x5.c       |    3 ++-
 drivers/net/tulip/winbond-840.c |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c
index 6418f74..98e8682 100644
--- a/drivers/net/tulip/de4x5.c
+++ b/drivers/net/tulip/de4x5.c
@@ -479,7 +479,8 @@
 
 #include "de4x5.h"
 
-static char version[] __devinitdata = "de4x5.c:V0.546 2001/02/22 davies@maniac.ultranet.com\n";
+static const char version[] __devinitdata +	KERN_INFO "de4x5.c:V0.546 2001/02/22 davies@maniac.ultranet.com\n";
 
 #define c_char const char
 
diff --git a/drivers/net/tulip/winbond-840.c b/drivers/net/tulip/winbond-840.c
index f467bf8..426b7c7 100644
--- a/drivers/net/tulip/winbond-840.c
+++ b/drivers/net/tulip/winbond-840.c
@@ -139,7 +139,7 @@ static int full_duplex[MAX_UNITS] = {-1, -1, -1, -1, -1, -1, -1, -1};
 #define PKT_BUF_SZ		1536	/* Size of each temporary Rx buffer.*/
 
 /* These identify the driver base version and may not be removed. */
-static char version[] +static const char version[] __initdata  KERN_INFO DRV_NAME ".c:v" DRV_VERSION " (2.4 port) " DRV_RELDATE "  Donald Becker <becker@scyld.com>\n"
 KERN_INFO "  http://www.scyld.com/network/drivers.html\n";
 


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

* [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:47   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:47 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename a local variable resp. remove a redundant variable and
while being at it use more unform loop constructs.

Fix this sparse warning:
  drivers/net/tulip/de4x5.c:3944:13: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/de4x5.c:3938:9: originally declared here
  drivers/net/tulip/media.c:72:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/media.c:54:13: originally declared here
  drivers/net/tulip/media.c:134:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/media.c:117:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tulip/de4x5.c |    4 ++--
 drivers/net/tulip/media.c |    8 +++-----
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c
index 98e8682..6430a2e 100644
--- a/drivers/net/tulip/de4x5.c
+++ b/drivers/net/tulip/de4x5.c
@@ -3942,8 +3942,8 @@ PCI_signature(char *name, struct de4x5_private *lp)
 	strcpy(name, "DE434/5");
 	return status;
     } else {                           /* Search for a DEC name in the SROM */
-	int i = *((char *)&lp->srom + 19) * 3;
-	strncpy(name, (char *)&lp->srom + 26 + i, 8);
+	int tmp = *((char *)&lp->srom + 19) * 3;
+	strncpy(name, (char *)&lp->srom + 26 + tmp, 8);
     }
     name[8] = '\0';
     for (i=0; i<siglen; i++) {
diff --git a/drivers/net/tulip/media.c b/drivers/net/tulip/media.c
index 91cf9c8..daddfa5 100644
--- a/drivers/net/tulip/media.c
+++ b/drivers/net/tulip/media.c
@@ -69,11 +69,10 @@ int tulip_mdio_read(struct net_device *dev, int phy_id, int location)
 
 	spin_lock_irqsave(&tp->mii_lock, flags);
 	if (tp->chip_id == LC82C168) {
-		int i = 1000;
 		iowrite32(0x60020000 + (phy_id<<23) + (location<<18), ioaddr + 0xA0);
 		ioread32(ioaddr + 0xA0);
 		ioread32(ioaddr + 0xA0);
-		while (--i > 0) {
+		for (i = 1000; i >= 0; --i) {
 			barrier();
 			if ( ! ((retval = ioread32(ioaddr + 0xA0)) & 0x80000000))
 				break;
@@ -131,13 +130,12 @@ void tulip_mdio_write(struct net_device *dev, int phy_id, int location, int val)
 
 	spin_lock_irqsave(&tp->mii_lock, flags);
 	if (tp->chip_id == LC82C168) {
-		int i = 1000;
 		iowrite32(cmd, ioaddr + 0xA0);
-		do {
+		for (i = 1000; i >= 0; --i) {
 			barrier();
 			if ( ! (ioread32(ioaddr + 0xA0) & 0x80000000))
 				break;
-		} while (--i > 0);
+		}
 		spin_unlock_irqrestore(&tp->mii_lock, flags);
 		return;
 	}


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

* [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows
@ 2009-02-14 21:47   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:47 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename a local variable resp. remove a redundant variable and
while being at it use more unform loop constructs.

Fix this sparse warning:
  drivers/net/tulip/de4x5.c:3944:13: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/de4x5.c:3938:9: originally declared here
  drivers/net/tulip/media.c:72:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/media.c:54:13: originally declared here
  drivers/net/tulip/media.c:134:21: warning: symbol 'i' shadows an earlier one
  drivers/net/tulip/media.c:117:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tulip/de4x5.c |    4 ++--
 drivers/net/tulip/media.c |    8 +++-----
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/net/tulip/de4x5.c b/drivers/net/tulip/de4x5.c
index 98e8682..6430a2e 100644
--- a/drivers/net/tulip/de4x5.c
+++ b/drivers/net/tulip/de4x5.c
@@ -3942,8 +3942,8 @@ PCI_signature(char *name, struct de4x5_private *lp)
 	strcpy(name, "DE434/5");
 	return status;
     } else {                           /* Search for a DEC name in the SROM */
-	int i = *((char *)&lp->srom + 19) * 3;
-	strncpy(name, (char *)&lp->srom + 26 + i, 8);
+	int tmp = *((char *)&lp->srom + 19) * 3;
+	strncpy(name, (char *)&lp->srom + 26 + tmp, 8);
     }
     name[8] = '\0';
     for (i=0; i<siglen; i++) {
diff --git a/drivers/net/tulip/media.c b/drivers/net/tulip/media.c
index 91cf9c8..daddfa5 100644
--- a/drivers/net/tulip/media.c
+++ b/drivers/net/tulip/media.c
@@ -69,11 +69,10 @@ int tulip_mdio_read(struct net_device *dev, int phy_id, int location)
 
 	spin_lock_irqsave(&tp->mii_lock, flags);
 	if (tp->chip_id = LC82C168) {
-		int i = 1000;
 		iowrite32(0x60020000 + (phy_id<<23) + (location<<18), ioaddr + 0xA0);
 		ioread32(ioaddr + 0xA0);
 		ioread32(ioaddr + 0xA0);
-		while (--i > 0) {
+		for (i = 1000; i >= 0; --i) {
 			barrier();
 			if ( ! ((retval = ioread32(ioaddr + 0xA0)) & 0x80000000))
 				break;
@@ -131,13 +130,12 @@ void tulip_mdio_write(struct net_device *dev, int phy_id, int location, int val)
 
 	spin_lock_irqsave(&tp->mii_lock, flags);
 	if (tp->chip_id = LC82C168) {
-		int i = 1000;
 		iowrite32(cmd, ioaddr + 0xA0);
-		do {
+		for (i = 1000; i >= 0; --i) {
 			barrier();
 			if ( ! (ioread32(ioaddr + 0xA0) & 0x80000000))
 				break;
-		} while (--i > 0);
+		}
 		spin_unlock_irqrestore(&tp->mii_lock, flags);
 		return;
 	}


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

* [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:47   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:47 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbols static.

Fix this sparse warnings:
  drivers/net/usb/hso.c:1249:6: warning: symbol 'hso_unthrottle_tasklet' was not declared. Should it be static?
  drivers/net/usb/hso.c:1268:6: warning: symbol 'hso_unthrottle_workfunc' was not declared. Should it be static?
  drivers/net/usb/hso.c:1466:5: warning: symbol 'tiocmget_submit_urb' was not declared. Should it be static?
  drivers/net/usb/smsc95xx.c:62:5: warning: symbol 'turbo_mode' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/usb/hso.c      |   10 +++++-----
 drivers/net/usb/smsc95xx.c |    2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c
index e6d62fe..a074c16 100644
--- a/drivers/net/usb/hso.c
+++ b/drivers/net/usb/hso.c
@@ -1246,7 +1246,7 @@ static void hso_std_serial_read_bulk_callback(struct urb *urb)
  * This needs to be a tasklet otherwise we will
  * end up recursively calling this function.
  */
-void hso_unthrottle_tasklet(struct hso_serial *serial)
+static void hso_unthrottle_tasklet(struct hso_serial *serial)
 {
 	unsigned long flags;
 
@@ -1265,7 +1265,7 @@ static	void hso_unthrottle(struct tty_struct *tty)
 	tasklet_hi_schedule(&serial->unthrottle_tasklet);
 }
 
-void hso_unthrottle_workfunc(struct work_struct *work)
+static void hso_unthrottle_workfunc(struct work_struct *work)
 {
 	struct hso_serial *serial =
 	    container_of(work, struct hso_serial,
@@ -1464,9 +1464,9 @@ static int hso_serial_chars_in_buffer(struct tty_struct *tty)
 
 	return chars;
 }
-int tiocmget_submit_urb(struct hso_serial *serial,
-			struct hso_tiocmget  *tiocmget,
-			struct usb_device *usb)
+static int tiocmget_submit_urb(struct hso_serial *serial,
+			       struct hso_tiocmget *tiocmget,
+			       struct usb_device *usb)
 {
 	int result;
 
diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c
index 5b0b964..3e6155a 100644
--- a/drivers/net/usb/smsc95xx.c
+++ b/drivers/net/usb/smsc95xx.c
@@ -58,7 +58,7 @@ struct usb_context {
 	struct usbnet *dev;
 };
 
-int turbo_mode = true;
+static int turbo_mode = true;
 module_param(turbo_mode, bool, 0644);
 MODULE_PARM_DESC(turbo_mode, "Enable multiple frames per Rx transaction");
 


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

* [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be
@ 2009-02-14 21:47   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:47 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbols static.

Fix this sparse warnings:
  drivers/net/usb/hso.c:1249:6: warning: symbol 'hso_unthrottle_tasklet' was not declared. Should it be static?
  drivers/net/usb/hso.c:1268:6: warning: symbol 'hso_unthrottle_workfunc' was not declared. Should it be static?
  drivers/net/usb/hso.c:1466:5: warning: symbol 'tiocmget_submit_urb' was not declared. Should it be static?
  drivers/net/usb/smsc95xx.c:62:5: warning: symbol 'turbo_mode' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/usb/hso.c      |   10 +++++-----
 drivers/net/usb/smsc95xx.c |    2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c
index e6d62fe..a074c16 100644
--- a/drivers/net/usb/hso.c
+++ b/drivers/net/usb/hso.c
@@ -1246,7 +1246,7 @@ static void hso_std_serial_read_bulk_callback(struct urb *urb)
  * This needs to be a tasklet otherwise we will
  * end up recursively calling this function.
  */
-void hso_unthrottle_tasklet(struct hso_serial *serial)
+static void hso_unthrottle_tasklet(struct hso_serial *serial)
 {
 	unsigned long flags;
 
@@ -1265,7 +1265,7 @@ static	void hso_unthrottle(struct tty_struct *tty)
 	tasklet_hi_schedule(&serial->unthrottle_tasklet);
 }
 
-void hso_unthrottle_workfunc(struct work_struct *work)
+static void hso_unthrottle_workfunc(struct work_struct *work)
 {
 	struct hso_serial *serial  	    container_of(work, struct hso_serial,
@@ -1464,9 +1464,9 @@ static int hso_serial_chars_in_buffer(struct tty_struct *tty)
 
 	return chars;
 }
-int tiocmget_submit_urb(struct hso_serial *serial,
-			struct hso_tiocmget  *tiocmget,
-			struct usb_device *usb)
+static int tiocmget_submit_urb(struct hso_serial *serial,
+			       struct hso_tiocmget *tiocmget,
+			       struct usb_device *usb)
 {
 	int result;
 
diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c
index 5b0b964..3e6155a 100644
--- a/drivers/net/usb/smsc95xx.c
+++ b/drivers/net/usb/smsc95xx.c
@@ -58,7 +58,7 @@ struct usb_context {
 	struct usbnet *dev;
 };
 
-int turbo_mode = true;
+static int turbo_mode = true;
 module_param(turbo_mode, bool, 0644);
 MODULE_PARM_DESC(turbo_mode, "Enable multiple frames per Rx transaction");
 


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

* [PATCH 35/43] drivers/net/wan: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:48   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]'.

Fix this compilation warnings:
  drivers/net/wan/lapbether.c: In function 'lapbeth_init_driver':
  drivers/net/wan/lapbether.c:441: warning: format not a string literal and no format arguments
  drivers/net/wan/z85230.c: In function 'z85230_init_driver':
  drivers/net/wan/z85230.c:1782: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wan/lapbether.c |    3 ++-
 drivers/net/wan/z85230.c    |    3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wan/lapbether.c b/drivers/net/wan/lapbether.c
index da9dcf5..06beba4 100644
--- a/drivers/net/wan/lapbether.c
+++ b/drivers/net/wan/lapbether.c
@@ -430,7 +430,8 @@ static struct notifier_block lapbeth_dev_notifier = {
 	.notifier_call = lapbeth_device_event,
 };
 
-static char banner[] __initdata = KERN_INFO "LAPB Ethernet driver version 0.02\n";
+static const char banner[] __initdata =
+	KERN_INFO "LAPB Ethernet driver version 0.02\n";
 
 static int __init lapbeth_init_driver(void)
 {
diff --git a/drivers/net/wan/z85230.c b/drivers/net/wan/z85230.c
index 3d00971..ad4e79c 100644
--- a/drivers/net/wan/z85230.c
+++ b/drivers/net/wan/z85230.c
@@ -1775,7 +1775,8 @@ EXPORT_SYMBOL(z8530_queue_xmit);
 /*
  *	Module support
  */
-static char banner[] __initdata = KERN_INFO "Generic Z85C30/Z85230 interface driver v0.02\n";
+static const char banner[] __initdata =
+	KERN_INFO "Generic Z85C30/Z85230 interface driver v0.02\n";
 
 static int __init z85230_init_driver(void)
 {


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

* [PATCH 35/43] drivers/net/wan: fix warning: format not a string
@ 2009-02-14 21:48   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Use 'static const char[]' instead of 'static char[]'.

Fix this compilation warnings:
  drivers/net/wan/lapbether.c: In function 'lapbeth_init_driver':
  drivers/net/wan/lapbether.c:441: warning: format not a string literal and no format arguments
  drivers/net/wan/z85230.c: In function 'z85230_init_driver':
  drivers/net/wan/z85230.c:1782: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wan/lapbether.c |    3 ++-
 drivers/net/wan/z85230.c    |    3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wan/lapbether.c b/drivers/net/wan/lapbether.c
index da9dcf5..06beba4 100644
--- a/drivers/net/wan/lapbether.c
+++ b/drivers/net/wan/lapbether.c
@@ -430,7 +430,8 @@ static struct notifier_block lapbeth_dev_notifier = {
 	.notifier_call = lapbeth_device_event,
 };
 
-static char banner[] __initdata = KERN_INFO "LAPB Ethernet driver version 0.02\n";
+static const char banner[] __initdata +	KERN_INFO "LAPB Ethernet driver version 0.02\n";
 
 static int __init lapbeth_init_driver(void)
 {
diff --git a/drivers/net/wan/z85230.c b/drivers/net/wan/z85230.c
index 3d00971..ad4e79c 100644
--- a/drivers/net/wan/z85230.c
+++ b/drivers/net/wan/z85230.c
@@ -1775,7 +1775,8 @@ EXPORT_SYMBOL(z8530_queue_xmit);
 /*
  *	Module support
  */
-static char banner[] __initdata = KERN_INFO "Generic Z85C30/Z85230 interface driver v0.02\n";
+static const char banner[] __initdata +	KERN_INFO "Generic Z85C30/Z85230 interface driver v0.02\n";
 
 static int __init z85230_init_driver(void)
 {


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

* [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:48   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename function scope variable and while being at it fix some
coding style issues.

Fix this sparse warning:
  drivers/net/wan/sbni.c:1526:14: warning: symbol 'num' shadows an earlier one
  drivers/net/wan/sbni.c:160:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wan/sbni.c |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/drivers/net/wan/sbni.c b/drivers/net/wan/sbni.c
index 0aa28e1..78f7bc9 100644
--- a/drivers/net/wan/sbni.c
+++ b/drivers/net/wan/sbni.c
@@ -1520,17 +1520,18 @@ int __init init_module( void )
 }
 
 void
-cleanup_module( void )
+cleanup_module(void)
 {
-	struct net_device  *dev;
-	int  num;
+	int i;
 
-	for( num = 0;  num < SBNI_MAX_NUM_CARDS;  ++num )
-		if( (dev = sbni_cards[ num ]) != NULL ) {
-			unregister_netdev( dev );
-			release_region( dev->base_addr, SBNI_IO_EXTENT );
-			free_netdev( dev );
+	for (i = 0;  i < SBNI_MAX_NUM_CARDS;  ++i) {
+		struct net_device *dev = sbni_cards[i];
+		if (dev != NULL) {
+			unregister_netdev(dev);
+			release_region(dev->base_addr, SBNI_IO_EXTENT);
+			free_netdev(dev);
 		}
+	}
 }
 
 #else	/* MODULE */


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

* [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an
@ 2009-02-14 21:48   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Rename function scope variable and while being at it fix some
coding style issues.

Fix this sparse warning:
  drivers/net/wan/sbni.c:1526:14: warning: symbol 'num' shadows an earlier one
  drivers/net/wan/sbni.c:160:13: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wan/sbni.c |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/drivers/net/wan/sbni.c b/drivers/net/wan/sbni.c
index 0aa28e1..78f7bc9 100644
--- a/drivers/net/wan/sbni.c
+++ b/drivers/net/wan/sbni.c
@@ -1520,17 +1520,18 @@ int __init init_module( void )
 }
 
 void
-cleanup_module( void )
+cleanup_module(void)
 {
-	struct net_device  *dev;
-	int  num;
+	int i;
 
-	for( num = 0;  num < SBNI_MAX_NUM_CARDS;  ++num )
-		if( (dev = sbni_cards[ num ]) != NULL ) {
-			unregister_netdev( dev );
-			release_region( dev->base_addr, SBNI_IO_EXTENT );
-			free_netdev( dev );
+	for (i = 0;  i < SBNI_MAX_NUM_CARDS;  ++i) {
+		struct net_device *dev = sbni_cards[i];
+		if (dev != NULL) {
+			unregister_netdev(dev);
+			release_region(dev->base_addr, SBNI_IO_EXTENT);
+			free_netdev(dev);
 		}
+	}
 }
 
 #else	/* MODULE */


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

* [PATCH 37/43] drivers/net/wireless: fix sparse warning: context imbalance
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:48   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute function with __acquires(...) resp. __releases(...).

Fix this sparse warnings:
  drivers/net/wireless/strip.c:955:21: warning: context imbalance in 'strip_seq_start' - wrong count at exit
  drivers/net/wireless/strip.c:975:13: warning: context imbalance in 'strip_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/strip.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/wireless/strip.c b/drivers/net/wireless/strip.c
index d6bf8d2..39f525e 100644
--- a/drivers/net/wireless/strip.c
+++ b/drivers/net/wireless/strip.c
@@ -950,6 +950,7 @@ static struct strip *strip_get_idx(loff_t pos)
 }
 
 static void *strip_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(RCU)
 {
 	rcu_read_lock();
 	return *pos ? strip_get_idx(*pos - 1) : SEQ_START_TOKEN;
@@ -973,6 +974,7 @@ static void *strip_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void strip_seq_stop(struct seq_file *seq, void *v)
+	__releases(RCU)
 {
 	rcu_read_unlock();
 }


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

* [PATCH 37/43] drivers/net/wireless: fix sparse warning: context
@ 2009-02-14 21:48   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:48 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Attribute function with __acquires(...) resp. __releases(...).

Fix this sparse warnings:
  drivers/net/wireless/strip.c:955:21: warning: context imbalance in 'strip_seq_start' - wrong count at exit
  drivers/net/wireless/strip.c:975:13: warning: context imbalance in 'strip_seq_stop' - unexpected unlock

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/strip.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/wireless/strip.c b/drivers/net/wireless/strip.c
index d6bf8d2..39f525e 100644
--- a/drivers/net/wireless/strip.c
+++ b/drivers/net/wireless/strip.c
@@ -950,6 +950,7 @@ static struct strip *strip_get_idx(loff_t pos)
 }
 
 static void *strip_seq_start(struct seq_file *seq, loff_t *pos)
+	__acquires(RCU)
 {
 	rcu_read_lock();
 	return *pos ? strip_get_idx(*pos - 1) : SEQ_START_TOKEN;
@@ -973,6 +974,7 @@ static void *strip_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 }
 
 static void strip_seq_stop(struct seq_file *seq, void *v)
+	__releases(RCU)
 {
 	rcu_read_unlock();
 }


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

* [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:49   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact:
  Move variable closer to usage resp.
  remove redundant variables resp.
  rename function scope variable.

Fix this sparse warnings:
  drivers/net/wireless/airo.c:3840:29: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/airo.c:3847:29: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/airo.c:3861:21: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/wavelan.c:43:13: warning: symbol 'irq' shadows an earlier one
  drivers/net/wireless/wavelan.p.h:692:17: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/airo.c    |    4 +---
 drivers/net/wireless/wavelan.c |    8 ++++----
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c
index 308603e..220f00b 100644
--- a/drivers/net/wireless/airo.c
+++ b/drivers/net/wireless/airo.c
@@ -3748,7 +3748,6 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 	Cmd cmd;
 	Resp rsp;
 	int status;
-	int i;
 	SsidRid mySsid;
 	__le16 lastindex;
 	WepKeyRid wkr;
@@ -3790,6 +3789,7 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 	if (lock)
 		up(&ai->sem);
 	if (ai->config.len == 0) {
+		int i;
 		tdsRssiRid rssi_rid;
 		CapabilityRid cap_rid;
 
@@ -3837,14 +3837,12 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 		/* Check to see if there are any insmod configured
 		   rates to add */
 		if ( rates[0] ) {
-			int i = 0;
 			memset(ai->config.rates,0,sizeof(ai->config.rates));
 			for( i = 0; i < 8 && rates[i]; i++ ) {
 				ai->config.rates[i] = rates[i];
 			}
 		}
 		if ( basic_rate > 0 ) {
-			int i;
 			for( i = 0; i < 8; i++ ) {
 				if ( ai->config.rates[i] == basic_rate ||
 				     !ai->config.rates ) {
diff --git a/drivers/net/wireless/wavelan.c b/drivers/net/wireless/wavelan.c
index 8326793..688bdea 100644
--- a/drivers/net/wireless/wavelan.c
+++ b/drivers/net/wireless/wavelan.c
@@ -40,11 +40,11 @@ static u8 wv_irq_to_psa(int irq)
  */
 static int __init wv_psa_to_irq(u8 irqval)
 {
-	int irq;
+	int i;
 
-	for (irq = 0; irq < ARRAY_SIZE(irqvals); irq++)
-		if (irqvals[irq] == irqval)
-			return irq;
+	for (i = 0; i < ARRAY_SIZE(irqvals); i++)
+		if (irqvals[i] == irqval)
+			return i;
 
 	return -1;
 }


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

* [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol
@ 2009-02-14 21:49   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact:
  Move variable closer to usage resp.
  remove redundant variables resp.
  rename function scope variable.

Fix this sparse warnings:
  drivers/net/wireless/airo.c:3840:29: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/airo.c:3847:29: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/airo.c:3861:21: warning: symbol 'i' shadows an earlier one
  drivers/net/wireless/airo.c:3751:13: originally declared here
  drivers/net/wireless/wavelan.c:43:13: warning: symbol 'irq' shadows an earlier one
  drivers/net/wireless/wavelan.p.h:692:17: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/airo.c    |    4 +---
 drivers/net/wireless/wavelan.c |    8 ++++----
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c
index 308603e..220f00b 100644
--- a/drivers/net/wireless/airo.c
+++ b/drivers/net/wireless/airo.c
@@ -3748,7 +3748,6 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 	Cmd cmd;
 	Resp rsp;
 	int status;
-	int i;
 	SsidRid mySsid;
 	__le16 lastindex;
 	WepKeyRid wkr;
@@ -3790,6 +3789,7 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 	if (lock)
 		up(&ai->sem);
 	if (ai->config.len = 0) {
+		int i;
 		tdsRssiRid rssi_rid;
 		CapabilityRid cap_rid;
 
@@ -3837,14 +3837,12 @@ static u16 setup_card(struct airo_info *ai, u8 *mac, int lock)
 		/* Check to see if there are any insmod configured
 		   rates to add */
 		if ( rates[0] ) {
-			int i = 0;
 			memset(ai->config.rates,0,sizeof(ai->config.rates));
 			for( i = 0; i < 8 && rates[i]; i++ ) {
 				ai->config.rates[i] = rates[i];
 			}
 		}
 		if ( basic_rate > 0 ) {
-			int i;
 			for( i = 0; i < 8; i++ ) {
 				if ( ai->config.rates[i] = basic_rate ||
 				     !ai->config.rates ) {
diff --git a/drivers/net/wireless/wavelan.c b/drivers/net/wireless/wavelan.c
index 8326793..688bdea 100644
--- a/drivers/net/wireless/wavelan.c
+++ b/drivers/net/wireless/wavelan.c
@@ -40,11 +40,11 @@ static u8 wv_irq_to_psa(int irq)
  */
 static int __init wv_psa_to_irq(u8 irqval)
 {
-	int irq;
+	int i;
 
-	for (irq = 0; irq < ARRAY_SIZE(irqvals); irq++)
-		if (irqvals[irq] = irqval)
-			return irq;
+	for (i = 0; i < ARRAY_SIZE(irqvals); i++)
+		if (irqvals[i] = irqval)
+			return i;
 
 	return -1;
 }


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

* [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:49   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/wireless/airo.c:2102:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2126:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2167:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2191:21: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/airo.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c
index 220f00b..e64eab4 100644
--- a/drivers/net/wireless/airo.c
+++ b/drivers/net/wireless/airo.c
@@ -1161,7 +1161,7 @@ struct airo_info {
 	   use the high bit to mark whether it is in use. */
 #define MAX_FIDS 6
 #define MPI_MAX_FIDS 1
-	int                           fids[MAX_FIDS];
+	u32                           fids[MAX_FIDS];
 	ConfigRid config;
 	char keyindex; // Used with auto wep
 	char defindex; // Used with auto wep


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

* [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix
@ 2009-02-14 21:49   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/wireless/airo.c:2102:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2126:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2167:21: warning: incorrect type in initializer (different signedness)
  drivers/net/wireless/airo.c:2191:21: warning: incorrect type in initializer (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/airo.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c
index 220f00b..e64eab4 100644
--- a/drivers/net/wireless/airo.c
+++ b/drivers/net/wireless/airo.c
@@ -1161,7 +1161,7 @@ struct airo_info {
 	   use the high bit to mark whether it is in use. */
 #define MAX_FIDS 6
 #define MPI_MAX_FIDS 1
-	int                           fids[MAX_FIDS];
+	u32                           fids[MAX_FIDS];
 	ConfigRid config;
 	char keyindex; // Used with auto wep
 	char defindex; // Used with auto wep


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

* [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should it be static?
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:49   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbols static.

Fix this sparse warnings:
  drivers/net/wireless/ath9k/eeprom.c:1343:5: warning: symbol 'ath9k_hw_4k_get_spur_channel' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:1372:19: warning: symbol 'eep_4k_ops' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:2649:5: warning: symbol 'ath9k_hw_def_get_spur_channel' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:2678:19: warning: symbol 'eep_def_ops' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/ath9k/eeprom.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/ath9k/eeprom.c b/drivers/net/wireless/ath9k/eeprom.c
index c0359ad..b55e992 100644
--- a/drivers/net/wireless/ath9k/eeprom.c
+++ b/drivers/net/wireless/ath9k/eeprom.c
@@ -1340,7 +1340,7 @@ static u8 ath9k_hw_4k_get_num_ant_config(struct ath_hw *ah,
 	return 1;
 }
 
-u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
+static u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 {
 #define EEP_MAP4K_SPURCHAN \
 	(ah->eeprom.map4k.modalHeader.spurChans[i].spurChan)
@@ -1369,7 +1369,7 @@ u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 #undef EEP_MAP4K_SPURCHAN
 }
 
-struct eeprom_ops eep_4k_ops = {
+static struct eeprom_ops eep_4k_ops = {
 	.check_eeprom		= ath9k_hw_4k_check_eeprom,
 	.get_eeprom		= ath9k_hw_4k_get_eeprom,
 	.fill_eeprom		= ath9k_hw_4k_fill_eeprom,
@@ -2646,7 +2646,7 @@ static u16 ath9k_hw_def_get_eeprom_antenna_cfg(struct ath_hw *ah,
 	return pModal->antCtrlCommon & 0xFFFF;
 }
 
-u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
+static u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 {
 #define EEP_DEF_SPURCHAN \
 	(ah->eeprom.def.modalHeader[is2GHz].spurChans[i].spurChan)
@@ -2675,7 +2675,7 @@ u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 #undef EEP_DEF_SPURCHAN
 }
 
-struct eeprom_ops eep_def_ops = {
+static struct eeprom_ops eep_def_ops = {
 	.check_eeprom		= ath9k_hw_def_check_eeprom,
 	.get_eeprom		= ath9k_hw_def_get_eeprom,
 	.fill_eeprom		= ath9k_hw_def_fill_eeprom,


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

* [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should
@ 2009-02-14 21:49   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Impact: Make symbols static.

Fix this sparse warnings:
  drivers/net/wireless/ath9k/eeprom.c:1343:5: warning: symbol 'ath9k_hw_4k_get_spur_channel' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:1372:19: warning: symbol 'eep_4k_ops' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:2649:5: warning: symbol 'ath9k_hw_def_get_spur_channel' was not declared. Should it be static?
  drivers/net/wireless/ath9k/eeprom.c:2678:19: warning: symbol 'eep_def_ops' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/ath9k/eeprom.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/ath9k/eeprom.c b/drivers/net/wireless/ath9k/eeprom.c
index c0359ad..b55e992 100644
--- a/drivers/net/wireless/ath9k/eeprom.c
+++ b/drivers/net/wireless/ath9k/eeprom.c
@@ -1340,7 +1340,7 @@ static u8 ath9k_hw_4k_get_num_ant_config(struct ath_hw *ah,
 	return 1;
 }
 
-u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
+static u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 {
 #define EEP_MAP4K_SPURCHAN \
 	(ah->eeprom.map4k.modalHeader.spurChans[i].spurChan)
@@ -1369,7 +1369,7 @@ u16 ath9k_hw_4k_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 #undef EEP_MAP4K_SPURCHAN
 }
 
-struct eeprom_ops eep_4k_ops = {
+static struct eeprom_ops eep_4k_ops = {
 	.check_eeprom		= ath9k_hw_4k_check_eeprom,
 	.get_eeprom		= ath9k_hw_4k_get_eeprom,
 	.fill_eeprom		= ath9k_hw_4k_fill_eeprom,
@@ -2646,7 +2646,7 @@ static u16 ath9k_hw_def_get_eeprom_antenna_cfg(struct ath_hw *ah,
 	return pModal->antCtrlCommon & 0xFFFF;
 }
 
-u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
+static u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 {
 #define EEP_DEF_SPURCHAN \
 	(ah->eeprom.def.modalHeader[is2GHz].spurChans[i].spurChan)
@@ -2675,7 +2675,7 @@ u16 ath9k_hw_def_get_spur_channel(struct ath_hw *ah, u16 i, bool is2GHz)
 #undef EEP_DEF_SPURCHAN
 }
 
-struct eeprom_ops eep_def_ops = {
+static struct eeprom_ops eep_def_ops = {
 	.check_eeprom		= ath9k_hw_def_check_eeprom,
 	.get_eeprom		= ath9k_hw_def_get_eeprom,
 	.fill_eeprom		= ath9k_hw_def_fill_eeprom,


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

* [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a string literal and no ...
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:50   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this compilation warning:
  drivers/net/wireless/b43/main.c: In function 'b43_print_fw_helptext':
  drivers/net/wireless/b43/main.c:1971: warning: format not a string literal and no format arguments
  drivers/net/wireless/b43/main.c:1973: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/b43/main.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c
index dbb8765..7116ab6 100644
--- a/drivers/net/wireless/b43/main.c
+++ b/drivers/net/wireless/b43/main.c
@@ -1961,12 +1961,12 @@ static void b43_release_firmware(struct b43_wldev *dev)
 
 static void b43_print_fw_helptext(struct b43_wl *wl, bool error)
 {
-	const char *text;
+	const char text[] =
+		"You must go to " \
+		"http://wireless.kernel.org/en/users/Drivers/b43#devicefirmware " \
+		"and download the correct firmware for this driver version. " \
+		"Please carefully read all instructions on this website.\n";
 
-	text = "You must go to "
-	       "http://wireless.kernel.org/en/users/Drivers/b43#devicefirmware "
-	       "and download the correct firmware for this driver version. "
-	       "Please carefully read all instructions on this website.\n";
 	if (error)
 		b43err(wl, text);
 	else


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

* [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a
@ 2009-02-14 21:50   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this compilation warning:
  drivers/net/wireless/b43/main.c: In function 'b43_print_fw_helptext':
  drivers/net/wireless/b43/main.c:1971: warning: format not a string literal and no format arguments
  drivers/net/wireless/b43/main.c:1973: warning: format not a string literal and no format arguments

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/b43/main.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c
index dbb8765..7116ab6 100644
--- a/drivers/net/wireless/b43/main.c
+++ b/drivers/net/wireless/b43/main.c
@@ -1961,12 +1961,12 @@ static void b43_release_firmware(struct b43_wldev *dev)
 
 static void b43_print_fw_helptext(struct b43_wl *wl, bool error)
 {
-	const char *text;
+	const char text[] +		"You must go to " \
+		"http://wireless.kernel.org/en/users/Drivers/b43#devicefirmware " \
+		"and download the correct firmware for this driver version. " \
+		"Please carefully read all instructions on this website.\n";
 
-	text = "You must go to "
-	       "http://wireless.kernel.org/en/users/Drivers/b43#devicefirmware "
-	       "and download the correct firmware for this driver version. "
-	       "Please carefully read all instructions on this website.\n";
 	if (error)
 		b43err(wl, text);
 	else


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

* [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:50   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/wireless/ipw2x00/ipw2100.c:1930:43: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1938:76: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1946:67: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1953:72: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4071:73: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4078:43: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4084:67: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:7141:73: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:8317:48: warning: incorrect type in argument 4 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/ipw2x00/ipw2100.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wireless/ipw2x00/ipw2100.c
index 9170c23..fc6a0b3 100644
--- a/drivers/net/wireless/ipw2x00/ipw2100.c
+++ b/drivers/net/wireless/ipw2x00/ipw2100.c
@@ -1910,7 +1910,8 @@ static void isr_indicate_associated(struct ipw2100_priv *priv, u32 status)
 {
 
 #define MAC_ASSOCIATION_READ_DELAY (HZ)
-	int ret, len, essid_len;
+	int ret;
+	unsigned int len, essid_len;
 	char essid[IW_ESSID_MAX_SIZE];
 	u32 txrate;
 	u32 chan;
@@ -4058,7 +4059,7 @@ static ssize_t show_bssinfo(struct device *d, struct device_attribute *attr,
 	u8 bssid[ETH_ALEN];
 	u32 chan = 0;
 	char *out = buf;
-	int length;
+	unsigned int length;
 	int ret;
 
 	if (priv->status & STATUS_RF_KILL_MASK)
@@ -7122,7 +7123,7 @@ static int ipw2100_wx_get_rate(struct net_device *dev,
 {
 	struct ipw2100_priv *priv = ieee80211_priv(dev);
 	int val;
-	int len = sizeof(val);
+	unsigned int len = sizeof(val);
 	int err = 0;
 
 	if (!(priv->status & STATUS_ENABLED) ||
@@ -8297,7 +8298,7 @@ static void ipw2100_wx_event_work(struct work_struct *work)
 	struct ipw2100_priv *priv =
 		container_of(work, struct ipw2100_priv, wx_event_work.work);
 	union iwreq_data wrqu;
-	int len = ETH_ALEN;
+	unsigned int len = ETH_ALEN;
 
 	if (priv->status & STATUS_STOPPING)
 		return;


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

* [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix
@ 2009-02-14 21:50   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix this sparse warnings:
  drivers/net/wireless/ipw2x00/ipw2100.c:1930:43: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1938:76: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1946:67: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:1953:72: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4071:73: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4078:43: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:4084:67: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:7141:73: warning: incorrect type in argument 4 (different signedness)
  drivers/net/wireless/ipw2x00/ipw2100.c:8317:48: warning: incorrect type in argument 4 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/ipw2x00/ipw2100.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wireless/ipw2x00/ipw2100.c
index 9170c23..fc6a0b3 100644
--- a/drivers/net/wireless/ipw2x00/ipw2100.c
+++ b/drivers/net/wireless/ipw2x00/ipw2100.c
@@ -1910,7 +1910,8 @@ static void isr_indicate_associated(struct ipw2100_priv *priv, u32 status)
 {
 
 #define MAC_ASSOCIATION_READ_DELAY (HZ)
-	int ret, len, essid_len;
+	int ret;
+	unsigned int len, essid_len;
 	char essid[IW_ESSID_MAX_SIZE];
 	u32 txrate;
 	u32 chan;
@@ -4058,7 +4059,7 @@ static ssize_t show_bssinfo(struct device *d, struct device_attribute *attr,
 	u8 bssid[ETH_ALEN];
 	u32 chan = 0;
 	char *out = buf;
-	int length;
+	unsigned int length;
 	int ret;
 
 	if (priv->status & STATUS_RF_KILL_MASK)
@@ -7122,7 +7123,7 @@ static int ipw2100_wx_get_rate(struct net_device *dev,
 {
 	struct ipw2100_priv *priv = ieee80211_priv(dev);
 	int val;
-	int len = sizeof(val);
+	unsigned int len = sizeof(val);
 	int err = 0;
 
 	if (!(priv->status & STATUS_ENABLED) ||
@@ -8297,7 +8298,7 @@ static void ipw2100_wx_event_work(struct work_struct *work)
 	struct ipw2100_priv *priv  		container_of(work, struct ipw2100_priv, wx_event_work.work);
 	union iwreq_data wrqu;
-	int len = ETH_ALEN;
+	unsigned int len = ETH_ALEN;
 
 	if (priv->status & STATUS_STOPPING)
 		return;


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

* [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix signedness
  2009-02-14 21:11 ` Hannes Eder
@ 2009-02-14 21:50   ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix sparse warning:
  drivers/net/wireless/prism54/isl_ioctl.c:2997:32: warning: incorrect type in argument 2 (different signedness)
  drivers/net/wireless/prism54/oid_mgt.c:712:42: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/prism54/isl_ioctl.c |    3 ++-
 drivers/net/wireless/prism54/oid_mgt.c   |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/prism54/isl_ioctl.c b/drivers/net/wireless/prism54/isl_ioctl.c
index 57a150a..4c97c6a 100644
--- a/drivers/net/wireless/prism54/isl_ioctl.c
+++ b/drivers/net/wireless/prism54/isl_ioctl.c
@@ -2981,7 +2981,8 @@ prism54_set_spy(struct net_device *ndev,
 		union iwreq_data *uwrq, char *extra)
 {
 	islpci_private *priv = netdev_priv(ndev);
-	u32 u, oid = OID_INL_CONFIG;
+	u32 u;
+	enum oid_num_t oid = OID_INL_CONFIG;
 
 	down_write(&priv->mib_sem);
 	mgt_get(priv, OID_INL_CONFIG, &u);
diff --git a/drivers/net/wireless/prism54/oid_mgt.c b/drivers/net/wireless/prism54/oid_mgt.c
index 57a4ac3..1187e61 100644
--- a/drivers/net/wireless/prism54/oid_mgt.c
+++ b/drivers/net/wireless/prism54/oid_mgt.c
@@ -698,7 +698,7 @@ int
 mgt_commit(islpci_private *priv)
 {
 	int rvalue;
-	u32 u;
+	enum oid_num_t u;
 
 	if (islpci_get_state(priv) < PRV_STATE_INIT)
 		return 0;


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

* [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix
@ 2009-02-14 21:50   ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:50 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel

Fix sparse warning:
  drivers/net/wireless/prism54/isl_ioctl.c:2997:32: warning: incorrect type in argument 2 (different signedness)
  drivers/net/wireless/prism54/oid_mgt.c:712:42: warning: incorrect type in argument 2 (different signedness)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/wireless/prism54/isl_ioctl.c |    3 ++-
 drivers/net/wireless/prism54/oid_mgt.c   |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/prism54/isl_ioctl.c b/drivers/net/wireless/prism54/isl_ioctl.c
index 57a150a..4c97c6a 100644
--- a/drivers/net/wireless/prism54/isl_ioctl.c
+++ b/drivers/net/wireless/prism54/isl_ioctl.c
@@ -2981,7 +2981,8 @@ prism54_set_spy(struct net_device *ndev,
 		union iwreq_data *uwrq, char *extra)
 {
 	islpci_private *priv = netdev_priv(ndev);
-	u32 u, oid = OID_INL_CONFIG;
+	u32 u;
+	enum oid_num_t oid = OID_INL_CONFIG;
 
 	down_write(&priv->mib_sem);
 	mgt_get(priv, OID_INL_CONFIG, &u);
diff --git a/drivers/net/wireless/prism54/oid_mgt.c b/drivers/net/wireless/prism54/oid_mgt.c
index 57a4ac3..1187e61 100644
--- a/drivers/net/wireless/prism54/oid_mgt.c
+++ b/drivers/net/wireless/prism54/oid_mgt.c
@@ -698,7 +698,7 @@ int
 mgt_commit(islpci_private *priv)
 {
 	int rvalue;
-	u32 u;
+	enum oid_num_t u;
 
 	if (islpci_get_state(priv) < PRV_STATE_INIT)
 		return 0;


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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix  signedness
  2009-02-14 21:38       ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
  (?)
@ 2009-02-14 21:57         ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:57 UTC (permalink / raw)
  To: Cyrill Gorcunov; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, Feb 14, 2009 at 10:38 PM, Cyrill Gorcunov <gorcunov@gmail.com> wrote:
> [Cyrill Gorcunov - Sun, Feb 15, 2009 at 12:29:48AM +0300]
> | [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
> | | Fix this sparse warnings:
> | |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
> | |
> | | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> | ...
> |
> | Thanks Hannes,
> |
> | Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
> |
> |       - Cyrill -
>
> Btw I think the same fix could be applied on
> drivers/net/tun.c (if you have time for :)

This was fixed by this commit:
commit 745417e20684e4951afcabfe74583a3884e54980
Author: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Date:   Sun Jan 4 17:14:46 2009 -0800

which is in the linux-next tree.

BTW, how can I check from which tree this commit came into the linux-next tree?

-Hannes

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
@ 2009-02-14 21:57         ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:57 UTC (permalink / raw)
  To: Cyrill Gorcunov; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, Feb 14, 2009 at 10:38 PM, Cyrill Gorcunov <gorcunov@gmail.com> wrote:
> [Cyrill Gorcunov - Sun, Feb 15, 2009 at 12:29:48AM +0300]
> | [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
> | | Fix this sparse warnings:
> | |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
> | |
> | | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> | ...
> |
> | Thanks Hannes,
> |
> | Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
> |
> |       - Cyrill -
>
> Btw I think the same fix could be applied on
> drivers/net/tun.c (if you have time for :)

This was fixed by this commit:
commit 745417e20684e4951afcabfe74583a3884e54980
Author: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Date:   Sun Jan 4 17:14:46 2009 -0800

which is in the linux-next tree.

BTW, how can I check from which tree this commit came into the linux-next tree?

-Hannes

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix
@ 2009-02-14 21:57         ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-14 21:57 UTC (permalink / raw)
  To: Cyrill Gorcunov; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, Feb 14, 2009 at 10:38 PM, Cyrill Gorcunov <gorcunov@gmail.com> wrote:
> [Cyrill Gorcunov - Sun, Feb 15, 2009 at 12:29:48AM +0300]
> | [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
> | | Fix this sparse warnings:
> | |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
> | |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
> | |
> | | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> | ...
> |
> | Thanks Hannes,
> |
> | Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
> |
> |       - Cyrill -
>
> Btw I think the same fix could be applied on
> drivers/net/tun.c (if you have time for :)

This was fixed by this commit:
commit 745417e20684e4951afcabfe74583a3884e54980
Author: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Date:   Sun Jan 4 17:14:46 2009 -0800

which is in the linux-next tree.

BTW, how can I check from which tree this commit came into the linux-next tree?

-Hannes

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

* Re: [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
  2009-02-14 21:46   ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
@ 2009-02-14 23:24     ` Al Viro
  -1 siblings, 0 replies; 231+ messages in thread
From: Al Viro @ 2009-02-14 23:24 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, Feb 14, 2009 at 10:46:24PM +0100, Hannes Eder wrote:
> Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Um, no.  Here's a better question: does *anything* use ->current_ring_status
at all?  Answer: no.  Next question: did anything use it in the past?
git log -p drivers/net/tokenging/smctr.c in historical trees shows that
it had always been defined that way and that it had never been used at
all.

So how about removing the damn field completely?  Or asking the driver's
author what the hell had it been about?

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

* Re: [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast
@ 2009-02-14 23:24     ` Al Viro
  0 siblings, 0 replies; 231+ messages in thread
From: Al Viro @ 2009-02-14 23:24 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, Feb 14, 2009 at 10:46:24PM +0100, Hannes Eder wrote:
> Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Um, no.  Here's a better question: does *anything* use ->current_ring_status
at all?  Answer: no.  Next question: did anything use it in the past?
git log -p drivers/net/tokenging/smctr.c in historical trees shows that
it had always been defined that way and that it had never been used at
all.

So how about removing the damn field completely?  Or asking the driver's
author what the hell had it been about?

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
  2009-02-14 21:57         ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness Hannes Eder
@ 2009-02-15  8:08           ` Cyrill Gorcunov
  -1 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-15  8:08 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

[Hannes Eder - Sat, Feb 14, 2009 at 10:57:24PM +0100]
...
| > Btw I think the same fix could be applied on
| > drivers/net/tun.c (if you have time for :)
| 
| This was fixed by this commit:
| commit 745417e20684e4951afcabfe74583a3884e54980
| Author: Gerrit Renker <gerrit@erg.abdn.ac.uk>
| Date:   Sun Jan 4 17:14:46 2009 -0800
| 
| which is in the linux-next tree.

Ah, good to know, thanks!

| 
| BTW, how can I check from which tree this commit came into the linux-next tree?
| 
| -Hannes
| 

Not sure if it possible to find. if the commit was pulled without
additional comments -- the only thing could be obtained -- is commit
id itself. You better to ask someone who knows git well, not me :)

	- Cyrill -

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix
@ 2009-02-15  8:08           ` Cyrill Gorcunov
  0 siblings, 0 replies; 231+ messages in thread
From: Cyrill Gorcunov @ 2009-02-15  8:08 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

[Hannes Eder - Sat, Feb 14, 2009 at 10:57:24PM +0100]
...
| > Btw I think the same fix could be applied on
| > drivers/net/tun.c (if you have time for :)
| 
| This was fixed by this commit:
| commit 745417e20684e4951afcabfe74583a3884e54980
| Author: Gerrit Renker <gerrit@erg.abdn.ac.uk>
| Date:   Sun Jan 4 17:14:46 2009 -0800
| 
| which is in the linux-next tree.

Ah, good to know, thanks!

| 
| BTW, how can I check from which tree this commit came into the linux-next tree?
| 
| -Hannes
| 

Not sure if it possible to find. if the commit was pulled without
additional comments -- the only thing could be obtained -- is commit
id itself. You better to ask someone who knows git well, not me :)

	- Cyrill -

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

* Re: [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast  truncates bits from const value
  2009-02-14 23:24     ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast Al Viro
  (?)
@ 2009-02-15 11:47       ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 11:47 UTC (permalink / raw)
  To: Al Viro, Jay Schulist; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 12:24 AM, Al Viro <viro@zeniv.linux.org.uk> wrote:
> On Sat, Feb 14, 2009 at 10:46:24PM +0100, Hannes Eder wrote:
>> Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.
>>
>> Fix this sparse warnings:
>>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Um, no.  Here's a better question: does *anything* use ->current_ring_status
> at all?  Answer: no.  Next question: did anything use it in the past?
> git log -p drivers/net/tokenging/smctr.c in historical trees shows that
> it had always been defined that way and that it had never been used at
> all.
>
> So how about removing the damn field completely?  Or asking the driver's
> author what the hell had it been about?
>

I vote for removing the field, I prepare a patch for this.

Comments?

-Hannes

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

* Re: [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
@ 2009-02-15 11:47       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 11:47 UTC (permalink / raw)
  To: Al Viro, Jay Schulist; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 12:24 AM, Al Viro <viro@zeniv.linux.org.uk> wrote:
> On Sat, Feb 14, 2009 at 10:46:24PM +0100, Hannes Eder wrote:
>> Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.
>>
>> Fix this sparse warnings:
>>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Um, no.  Here's a better question: does *anything* use ->current_ring_status
> at all?  Answer: no.  Next question: did anything use it in the past?
> git log -p drivers/net/tokenging/smctr.c in historical trees shows that
> it had always been defined that way and that it had never been used at
> all.
>
> So how about removing the damn field completely?  Or asking the driver's
> author what the hell had it been about?
>

I vote for removing the field, I prepare a patch for this.

Comments?

-Hannes

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

* Re: [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast
@ 2009-02-15 11:47       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 11:47 UTC (permalink / raw)
  To: Al Viro, Jay Schulist; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 12:24 AM, Al Viro <viro@zeniv.linux.org.uk> wrote:
> On Sat, Feb 14, 2009 at 10:46:24PM +0100, Hannes Eder wrote:
>> Impact: Use '__u16' instead of '__u8', this possibly fixes a bug.
>>
>> Fix this sparse warnings:
>>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Um, no.  Here's a better question: does *anything* use ->current_ring_status
> at all?  Answer: no.  Next question: did anything use it in the past?
> git log -p drivers/net/tokenging/smctr.c in historical trees shows that
> it had always been defined that way and that it had never been used at
> all.
>
> So how about removing the damn field completely?  Or asking the driver's
> author what the hell had it been about?
>

I vote for removing the field, I prepare a patch for this.

Comments?

-Hannes

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

* [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
  2009-02-15 11:47       ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
@ 2009-02-15 12:13         ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 12:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, Jay Schulist, Al Viro

Impact: Remove the write-only field 'current_ring_status' completely.

Fix this sparse warnings:
  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/smctr.c |   10 ----------
 drivers/net/tokenring/smctr.h |    1 -
 2 files changed, 0 insertions(+), 11 deletions(-)

diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
index 5a3ff20..e66eb8a 100644
--- a/drivers/net/tokenring/smctr.c
+++ b/drivers/net/tokenring/smctr.c
@@ -4393,52 +4393,42 @@ static int smctr_ring_status_chg(struct net_device *dev)
         {
                 case RING_RECOVERY:
                         printk(KERN_INFO "%s: Ring Recovery\n", dev->name);
-                        tp->current_ring_status |= RING_RECOVERY;
                         break;
 
                 case SINGLE_STATION:
                         printk(KERN_INFO "%s: Single Statinon\n", dev->name);
-                        tp->current_ring_status |= SINGLE_STATION;
                         break;
 
                 case COUNTER_OVERFLOW:
                         printk(KERN_INFO "%s: Counter Overflow\n", dev->name);
-                        tp->current_ring_status |= COUNTER_OVERFLOW;
                         break;
 
                 case REMOVE_RECEIVED:
                         printk(KERN_INFO "%s: Remove Received\n", dev->name);
-                        tp->current_ring_status |= REMOVE_RECEIVED;
                         break;
 
                 case AUTO_REMOVAL_ERROR:
                         printk(KERN_INFO "%s: Auto Remove Error\n", dev->name);
-                        tp->current_ring_status |= AUTO_REMOVAL_ERROR;
                         break;
 
                 case LOBE_WIRE_FAULT:
                         printk(KERN_INFO "%s: Lobe Wire Fault\n", dev->name);
-                        tp->current_ring_status |= LOBE_WIRE_FAULT;
                         break;
 
                 case TRANSMIT_BEACON:
                         printk(KERN_INFO "%s: Transmit Beacon\n", dev->name);
-                        tp->current_ring_status |= TRANSMIT_BEACON;
                         break;
 
                 case SOFT_ERROR:
                         printk(KERN_INFO "%s: Soft Error\n", dev->name);
-                        tp->current_ring_status |= SOFT_ERROR;
                         break;
 
                 case HARD_ERROR:
                         printk(KERN_INFO "%s: Hard Error\n", dev->name);
-                        tp->current_ring_status |= HARD_ERROR;
                         break;
 
                 case SIGNAL_LOSS:
                         printk(KERN_INFO "%s: Signal Loss\n", dev->name);
-                        tp->current_ring_status |= SIGNAL_LOSS;
                         break;
 
                 default:
diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
index 52df7dd..6e5700a 100644
--- a/drivers/net/tokenring/smctr.h
+++ b/drivers/net/tokenring/smctr.h
@@ -977,7 +977,6 @@ typedef struct net_local {
 	__u8		monitor_state_ready;
 	__u16		ring_status;
 	__u8		ring_status_flags;
-	__u8		current_ring_status;
 	__u8		state;
 
 	__u8		join_state;


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

* [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast
@ 2009-02-15 12:13         ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 12:13 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, Jay Schulist, Al Viro

Impact: Remove the write-only field 'current_ring_status' completely.

Fix this sparse warnings:
  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/tokenring/smctr.c |   10 ----------
 drivers/net/tokenring/smctr.h |    1 -
 2 files changed, 0 insertions(+), 11 deletions(-)

diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
index 5a3ff20..e66eb8a 100644
--- a/drivers/net/tokenring/smctr.c
+++ b/drivers/net/tokenring/smctr.c
@@ -4393,52 +4393,42 @@ static int smctr_ring_status_chg(struct net_device *dev)
         {
                 case RING_RECOVERY:
                         printk(KERN_INFO "%s: Ring Recovery\n", dev->name);
-                        tp->current_ring_status |= RING_RECOVERY;
                         break;
 
                 case SINGLE_STATION:
                         printk(KERN_INFO "%s: Single Statinon\n", dev->name);
-                        tp->current_ring_status |= SINGLE_STATION;
                         break;
 
                 case COUNTER_OVERFLOW:
                         printk(KERN_INFO "%s: Counter Overflow\n", dev->name);
-                        tp->current_ring_status |= COUNTER_OVERFLOW;
                         break;
 
                 case REMOVE_RECEIVED:
                         printk(KERN_INFO "%s: Remove Received\n", dev->name);
-                        tp->current_ring_status |= REMOVE_RECEIVED;
                         break;
 
                 case AUTO_REMOVAL_ERROR:
                         printk(KERN_INFO "%s: Auto Remove Error\n", dev->name);
-                        tp->current_ring_status |= AUTO_REMOVAL_ERROR;
                         break;
 
                 case LOBE_WIRE_FAULT:
                         printk(KERN_INFO "%s: Lobe Wire Fault\n", dev->name);
-                        tp->current_ring_status |= LOBE_WIRE_FAULT;
                         break;
 
                 case TRANSMIT_BEACON:
                         printk(KERN_INFO "%s: Transmit Beacon\n", dev->name);
-                        tp->current_ring_status |= TRANSMIT_BEACON;
                         break;
 
                 case SOFT_ERROR:
                         printk(KERN_INFO "%s: Soft Error\n", dev->name);
-                        tp->current_ring_status |= SOFT_ERROR;
                         break;
 
                 case HARD_ERROR:
                         printk(KERN_INFO "%s: Hard Error\n", dev->name);
-                        tp->current_ring_status |= HARD_ERROR;
                         break;
 
                 case SIGNAL_LOSS:
                         printk(KERN_INFO "%s: Signal Loss\n", dev->name);
-                        tp->current_ring_status |= SIGNAL_LOSS;
                         break;
 
                 default:
diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
index 52df7dd..6e5700a 100644
--- a/drivers/net/tokenring/smctr.h
+++ b/drivers/net/tokenring/smctr.h
@@ -977,7 +977,6 @@ typedef struct net_local {
 	__u8		monitor_state_ready;
 	__u16		ring_status;
 	__u8		ring_status_flags;
-	__u8		current_ring_status;
 	__u8		state;
 
 	__u8		join_state;


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

* Re: [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
  2009-02-14 21:14   ` [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain Hannes Eder
@ 2009-02-15 14:00     ` Florian Fainelli
  -1 siblings, 0 replies; 231+ messages in thread
From: Florian Fainelli @ 2009-02-15 14:00 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hello Hannes,

Le Saturday 14 February 2009 22:14:04 Hannes Eder, vous avez écrit :
> Fix this sparse warnings:
>   drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
>   drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer

Good catch, thanks.
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Florian Fainelli <florian@openwrt.org>
-- 
Best regards, Florian Fainelli
Email : florian@openwrt.org
http://openwrt.org
-------------------------------

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

* Re: [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
@ 2009-02-15 14:00     ` Florian Fainelli
  0 siblings, 0 replies; 231+ messages in thread
From: Florian Fainelli @ 2009-02-15 14:00 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hello Hannes,

Le Saturday 14 February 2009 22:14:04 Hannes Eder, vous avez écrit :
> Fix this sparse warnings:
>   drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
>   drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer

Good catch, thanks.
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Florian Fainelli <florian@openwrt.org>
-- 
Best regards, Florian Fainelli
Email : florian@openwrt.org
http://openwrt.org
-------------------------------

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:12   ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-15 14:04     ` walter harms
  -1 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-15 14:04 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hi Hannes,
it is ok to replace a fixed boarder with ARRAY_SIZE()
in this special case i would success the following additional cleanup
(untestet !!)


static int set_free_irq(struct net_device *dev)
{
 int irqlist[] = {15,11,10,12,5,9,3,4}, i;

        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
                        dev->irq = irqlist[i];
                        return 0;
            }
        return -1;
}

....

if (dev->irq < 2) {
         if ( set_free_irq(dev) < 0) {
                printk(" unable to get IRQ %d.\n", dev->irq);
                retval = -EAGAIN;
                goto out;
        }

for me this looks more readable.

getting a free interrupt from a list mus be a common problem ? I am not in driver programming
perhaps such a code is already in place somewhere  ?

comments ?

re,
 wh


Hannes Eder schrieb:
> Impact: Remove redundant inner scope variable and while being at it
> make use of ARRAY_SIZE instead of a hardcoded number.
> 
> Fix this sparse warning:
>   drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
>   drivers/net/e2100.c:181:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/e2100.c |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/net/e2100.c b/drivers/net/e2100.c
> index b07ba19..d2f6ee1 100644
> --- a/drivers/net/e2100.c
> +++ b/drivers/net/e2100.c
> @@ -216,13 +216,13 @@ static int __init e21_probe1(struct net_device *dev, int ioaddr)
>  		printk(" %02X", station_addr[i]);
>  
>  	if (dev->irq < 2) {
> -		int irqlist[] = {15,11,10,12,5,9,3,4}, i;
> -		for (i = 0; i < 8; i++)
> +		int irqlist[] = {15, 11, 10, 12, 5, 9, 3, 4};
> +		for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>  			if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>  				dev->irq = irqlist[i];
>  				break;
>  			}
> -		if (i >= 8) {
> +		if (i >= ARRAY_SIZE(irqlist)) {
>  			printk(" unable to get IRQ %d.\n", dev->irq);
>  			retval = -EAGAIN;
>  			goto out;
> 
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
> 
> 

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol
@ 2009-02-15 14:04     ` walter harms
  0 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-15 14:04 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hi Hannes,
it is ok to replace a fixed boarder with ARRAY_SIZE()
in this special case i would success the following additional cleanup
(untestet !!)


static int set_free_irq(struct net_device *dev)
{
 int irqlist[] = {15,11,10,12,5,9,3,4}, i;

        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
                        dev->irq = irqlist[i];
                        return 0;
            }
        return -1;
}

....

if (dev->irq < 2) {
         if ( set_free_irq(dev) < 0) {
                printk(" unable to get IRQ %d.\n", dev->irq);
                retval = -EAGAIN;
                goto out;
        }

for me this looks more readable.

getting a free interrupt from a list mus be a common problem ? I am not in driver programming
perhaps such a code is already in place somewhere  ?

comments ?

re,
 wh


Hannes Eder schrieb:
> Impact: Remove redundant inner scope variable and while being at it
> make use of ARRAY_SIZE instead of a hardcoded number.
> 
> Fix this sparse warning:
>   drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
>   drivers/net/e2100.c:181:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/e2100.c |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/net/e2100.c b/drivers/net/e2100.c
> index b07ba19..d2f6ee1 100644
> --- a/drivers/net/e2100.c
> +++ b/drivers/net/e2100.c
> @@ -216,13 +216,13 @@ static int __init e21_probe1(struct net_device *dev, int ioaddr)
>  		printk(" %02X", station_addr[i]);
>  
>  	if (dev->irq < 2) {
> -		int irqlist[] = {15,11,10,12,5,9,3,4}, i;
> -		for (i = 0; i < 8; i++)
> +		int irqlist[] = {15, 11, 10, 12, 5, 9, 3, 4};
> +		for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>  			if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>  				dev->irq = irqlist[i];
>  				break;
>  			}
> -		if (i >= 8) {
> +		if (i >= ARRAY_SIZE(irqlist)) {
>  			printk(" unable to get IRQ %d.\n", dev->irq);
>  			retval = -EAGAIN;
>  			goto out;
> 
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
> 
> 

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:16   ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-15 14:14     ` walter harms
  -1 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-15 14:14 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel



Hannes Eder schrieb:
> Impact: Move variable declaration as close to usage as possible.
> 
> Fix this sparse warning:
>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/cxgb3/cxgb3_main.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
> index f2c7cc3..0f6062a 100644
> --- a/drivers/net/cxgb3/cxgb3_main.c
> +++ b/drivers/net/cxgb3/cxgb3_main.c
> @@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
>  
>  static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>  {
> -	int cap;
>  	struct port_info *p = netdev_priv(dev);
>  	struct link_config *lc = &p->link_config;
>  
> @@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>  		 * being requested.
>  		 */
>  		if (cmd->autoneg == AUTONEG_DISABLE) {
> -			cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
> +			int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>  			if (lc->supported & cap)
>  				return 0;
>  		}
> 

Hello Hannes,
it seems that "cap" can be dropped completely.

if (lc->supported & speed_duplex_to_caps(cmd->speed, cmd->duplex) )
	return 0;


re,
 wh

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows
@ 2009-02-15 14:14     ` walter harms
  0 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-15 14:14 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel



Hannes Eder schrieb:
> Impact: Move variable declaration as close to usage as possible.
> 
> Fix this sparse warning:
>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/cxgb3/cxgb3_main.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
> index f2c7cc3..0f6062a 100644
> --- a/drivers/net/cxgb3/cxgb3_main.c
> +++ b/drivers/net/cxgb3/cxgb3_main.c
> @@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
>  
>  static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>  {
> -	int cap;
>  	struct port_info *p = netdev_priv(dev);
>  	struct link_config *lc = &p->link_config;
>  
> @@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>  		 * being requested.
>  		 */
>  		if (cmd->autoneg = AUTONEG_DISABLE) {
> -			cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
> +			int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>  			if (lc->supported & cap)
>  				return 0;
>  		}
> 

Hello Hannes,
it seems that "cap" can be dropped completely.

if (lc->supported & speed_duplex_to_caps(cmd->speed, cmd->duplex) )
	return 0;


re,
 wh

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol  shadows an earlier one
  2009-02-15 14:04     ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol walter harms
  (?)
@ 2009-02-15 19:57       ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 19:57 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:04 PM, walter harms <wharms@bfs.de> wrote:
> Hi Hannes,
> it is ok to replace a fixed boarder with ARRAY_SIZE()
> in this special case i would success the following additional cleanup
> (untestet !!)
>
>
> static int set_free_irq(struct net_device *dev)
> {
>  int irqlist[] = {15,11,10,12,5,9,3,4}, i;
>
>        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>                        dev->irq = irqlist[i];
>                        return 0;
>            }
>        return -1;
> }
>
> ....
>
> if (dev->irq < 2) {
>         if ( set_free_irq(dev) < 0) {
>                printk(" unable to get IRQ %d.\n", dev->irq);
>                retval = -EAGAIN;
>                goto out;
>        }
>
> for me this looks more readable.
>
> getting a free interrupt from a list mus be a common problem ? I am not in driver programming
> perhaps such a code is already in place somewhere  ?

I am a great fan of refactoring but in that case I would just leave it
as is.  If extracting a method I would extract a little more here.

Best,
Hannes

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
@ 2009-02-15 19:57       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 19:57 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:04 PM, walter harms <wharms@bfs.de> wrote:
> Hi Hannes,
> it is ok to replace a fixed boarder with ARRAY_SIZE()
> in this special case i would success the following additional cleanup
> (untestet !!)
>
>
> static int set_free_irq(struct net_device *dev)
> {
>  int irqlist[] = {15,11,10,12,5,9,3,4}, i;
>
>        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>                        dev->irq = irqlist[i];
>                        return 0;
>            }
>        return -1;
> }
>
> ....
>
> if (dev->irq < 2) {
>         if ( set_free_irq(dev) < 0) {
>                printk(" unable to get IRQ %d.\n", dev->irq);
>                retval = -EAGAIN;
>                goto out;
>        }
>
> for me this looks more readable.
>
> getting a free interrupt from a list mus be a common problem ? I am not in driver programming
> perhaps such a code is already in place somewhere  ?

I am a great fan of refactoring but in that case I would just leave it
as is.  If extracting a method I would extract a little more here.

Best,
Hannes

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol
@ 2009-02-15 19:57       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 19:57 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:04 PM, walter harms <wharms@bfs.de> wrote:
> Hi Hannes,
> it is ok to replace a fixed boarder with ARRAY_SIZE()
> in this special case i would success the following additional cleanup
> (untestet !!)
>
>
> static int set_free_irq(struct net_device *dev)
> {
>  int irqlist[] = {15,11,10,12,5,9,3,4}, i;
>
>        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>                        dev->irq = irqlist[i];
>                        return 0;
>            }
>        return -1;
> }
>
> ....
>
> if (dev->irq < 2) {
>         if ( set_free_irq(dev) < 0) {
>                printk(" unable to get IRQ %d.\n", dev->irq);
>                retval = -EAGAIN;
>                goto out;
>        }
>
> for me this looks more readable.
>
> getting a free interrupt from a list mus be a common problem ? I am not in driver programming
> perhaps such a code is already in place somewhere  ?

I am a great fan of refactoring but in that case I would just leave it
as is.  If extracting a method I would extract a little more here.

Best,
Hannes

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol  shadows an earlier one
  2009-02-15 14:14     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows walter harms
  (?)
@ 2009-02-15 20:10       ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 20:10 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:14 PM, walter harms <wharms@bfs.de> wrote:
> Hannes Eder schrieb:
>> Impact: Move variable declaration as close to usage as possible.
>>
>> Fix this sparse warning:
>>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/cxgb3/cxgb3_main.c |    3 +--
>>  1 files changed, 1 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
>> index f2c7cc3..0f6062a 100644
>> --- a/drivers/net/cxgb3/cxgb3_main.c
>> +++ b/drivers/net/cxgb3/cxgb3_main.c
>> @@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
>>
>>  static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>  {
>> -     int cap;
>>       struct port_info *p = netdev_priv(dev);
>>       struct link_config *lc = &p->link_config;
>>
>> @@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>                * being requested.
>>                */
>>               if (cmd->autoneg == AUTONEG_DISABLE) {
>> -                     cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>> +                     int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>>                       if (lc->supported & cap)
>>                               return 0;
>>               }
>>
>
> Hello Hannes,
> it seems that "cap" can be dropped completely.
>
> if (lc->supported & speed_duplex_to_caps(cmd->speed, cmd->duplex) )
>        return 0;

Hi Walter,

You are right, but we would hit the 80 characters per line limit,
90 in this case, and a similar construct is used a few lines
below so I suggest to leave it this way.

-Hannes

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
@ 2009-02-15 20:10       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 20:10 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:14 PM, walter harms <wharms@bfs.de> wrote:
> Hannes Eder schrieb:
>> Impact: Move variable declaration as close to usage as possible.
>>
>> Fix this sparse warning:
>>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/cxgb3/cxgb3_main.c |    3 +--
>>  1 files changed, 1 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
>> index f2c7cc3..0f6062a 100644
>> --- a/drivers/net/cxgb3/cxgb3_main.c
>> +++ b/drivers/net/cxgb3/cxgb3_main.c
>> @@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
>>
>>  static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>  {
>> -     int cap;
>>       struct port_info *p = netdev_priv(dev);
>>       struct link_config *lc = &p->link_config;
>>
>> @@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>                * being requested.
>>                */
>>               if (cmd->autoneg == AUTONEG_DISABLE) {
>> -                     cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>> +                     int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>>                       if (lc->supported & cap)
>>                               return 0;
>>               }
>>
>
> Hello Hannes,
> it seems that "cap" can be dropped completely.
>
> if (lc->supported & speed_duplex_to_caps(cmd->speed, cmd->duplex) )
>        return 0;

Hi Walter,

You are right, but we would hit the 80 characters per line limit,
90 in this case, and a similar construct is used a few lines
below so I suggest to leave it this way.

-Hannes

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol
@ 2009-02-15 20:10       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-15 20:10 UTC (permalink / raw)
  To: wharms; +Cc: netdev, kernel-janitors, linux-kernel

On Sun, Feb 15, 2009 at 3:14 PM, walter harms <wharms@bfs.de> wrote:
> Hannes Eder schrieb:
>> Impact: Move variable declaration as close to usage as possible.
>>
>> Fix this sparse warning:
>>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/cxgb3/cxgb3_main.c |    3 +--
>>  1 files changed, 1 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
>> index f2c7cc3..0f6062a 100644
>> --- a/drivers/net/cxgb3/cxgb3_main.c
>> +++ b/drivers/net/cxgb3/cxgb3_main.c
>> @@ -1565,7 +1565,6 @@ static int speed_duplex_to_caps(int speed, int duplex)
>>
>>  static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>  {
>> -     int cap;
>>       struct port_info *p = netdev_priv(dev);
>>       struct link_config *lc = &p->link_config;
>>
>> @@ -1575,7 +1574,7 @@ static int set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
>>                * being requested.
>>                */
>>               if (cmd->autoneg = AUTONEG_DISABLE) {
>> -                     cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>> +                     int cap = speed_duplex_to_caps(cmd->speed, cmd->duplex);
>>                       if (lc->supported & cap)
>>                               return 0;
>>               }
>>
>
> Hello Hannes,
> it seems that "cap" can be dropped completely.
>
> if (lc->supported & speed_duplex_to_caps(cmd->speed, cmd->duplex) )
>        return 0;

Hi Walter,

You are right, but we would hit the 80 characters per line limit,
90 in this case, and a similar construct is used a few lines
below so I suggest to leave it this way.

-Hannes

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:16   ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-15 21:30     ` Divy Le Ray
  -1 siblings, 0 replies; 231+ messages in thread
From: Divy Le Ray @ 2009-02-15 21:30 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Impact: Move variable declaration as close to usage as possible.
>
> Fix this sparse warning:
>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>   
Acked-by: Divy Le Ray <divy@chelsio.com>

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows
@ 2009-02-15 21:30     ` Divy Le Ray
  0 siblings, 0 replies; 231+ messages in thread
From: Divy Le Ray @ 2009-02-15 21:30 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Impact: Move variable declaration as close to usage as possible.
>
> Fix this sparse warning:
>   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>   
Acked-by: Divy Le Ray <divy@chelsio.com>

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

* Re: [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness
  2009-02-14 21:16   ` Hannes Eder
@ 2009-02-15 21:32     ` Divy Le Ray
  -1 siblings, 0 replies; 231+ messages in thread
From: Divy Le Ray @ 2009-02-15 21:32 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Fix this sparse warning:
>   drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>   
Acked-by: Divy Le Ray <divy@chelsio.com>

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

* Re: [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness
@ 2009-02-15 21:32     ` Divy Le Ray
  0 siblings, 0 replies; 231+ messages in thread
From: Divy Le Ray @ 2009-02-15 21:32 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Fix this sparse warning:
>   drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>   
Acked-by: Divy Le Ray <divy@chelsio.com>

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static?
  2009-02-14 21:42   ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be Hannes Eder
  (?)
@ 2009-02-16  0:37   ` Ben Hutchings
  2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
  -1 siblings, 1 reply; 231+ messages in thread
From: Ben Hutchings @ 2009-02-16  0:37 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Impact: Include header file and include the function under the same
> condition as in the header file.  If CONFIG_SFS_MTD is not defined
> than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
> 'static inline' with an empty function body in the header file.
> 
> Fix this sparse warnings:
>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/sfc/mtd.c |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
> index 665cafb..94c9ed8 100644
> --- a/drivers/net/sfc/mtd.c
> +++ b/drivers/net/sfc/mtd.c
> @@ -15,6 +15,7 @@
>  #define EFX_DRIVER_NAME "sfc_mtd"
>  #include "net_driver.h"
>  #include "spi.h"
> +#include "efx.h"
>  
>  #define EFX_SPI_VERIFY_BUF_LEN 16
>  

OK, but...

> @@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
>  	return;
>  }
>  
> +#ifdef CONFIG_SFC_MTD
>  void efx_mtd_remove(struct efx_nic *efx)
>  {
>  	if (efx->spi_flash && efx->spi_flash->mtd) {
> @@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
>  
>  	return 0;
>  }
> +#endif /* CONFIG_SFC_MTD */

This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.

Ben.

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

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

* Re: [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:41   ` [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an Hannes Eder
@ 2009-02-16  0:38     ` Ben Hutchings
  -1 siblings, 0 replies; 231+ messages in thread
From: Ben Hutchings @ 2009-02-16  0:38 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Impact: Move variable declaration as close to their usage as possible.
> 
> Fix this sparse warning:
>   drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
>   drivers/net/sfc/tenxpress.c:575:30: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
Acked-by: Ben Hutchings <bhutchings@solarflare.com>
> ---
>  drivers/net/sfc/tenxpress.c |    7 +++----
>  1 files changed, 3 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/net/sfc/tenxpress.c b/drivers/net/sfc/tenxpress.c
> index ac9eeab..5b0f451 100644
> --- a/drivers/net/sfc/tenxpress.c
> +++ b/drivers/net/sfc/tenxpress.c
> @@ -572,15 +572,14 @@ static void tenxpress_phy_reconfigure(struct efx_nic *efx)
>  static void tenxpress_phy_poll(struct efx_nic *efx)
>  {
>  	struct tenxpress_phy_data *phy_data = efx->phy_data;
> -	bool change = false, link_ok;
> -	unsigned link_fc;
> +	bool change = false;
>  
>  	if (efx->phy_type == PHY_TYPE_SFX7101) {
> -		link_ok = sfx7101_link_ok(efx);
> +		bool link_ok = sfx7101_link_ok(efx);
>  		if (link_ok != efx->link_up) {
>  			change = true;
>  		} else {
> -			link_fc = mdio_clause45_get_pause(efx);
> +			unsigned int link_fc = mdio_clause45_get_pause(efx);
>  			if (link_fc != efx->link_fc)
>  				change = true;
>  		}
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

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

* Re: [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
@ 2009-02-16  0:38     ` Ben Hutchings
  0 siblings, 0 replies; 231+ messages in thread
From: Ben Hutchings @ 2009-02-16  0:38 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

Hannes Eder wrote:
> Impact: Move variable declaration as close to their usage as possible.
> 
> Fix this sparse warning:
>   drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
>   drivers/net/sfc/tenxpress.c:575:30: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
Acked-by: Ben Hutchings <bhutchings@solarflare.com>
> ---
>  drivers/net/sfc/tenxpress.c |    7 +++----
>  1 files changed, 3 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/net/sfc/tenxpress.c b/drivers/net/sfc/tenxpress.c
> index ac9eeab..5b0f451 100644
> --- a/drivers/net/sfc/tenxpress.c
> +++ b/drivers/net/sfc/tenxpress.c
> @@ -572,15 +572,14 @@ static void tenxpress_phy_reconfigure(struct efx_nic *efx)
>  static void tenxpress_phy_poll(struct efx_nic *efx)
>  {
>  	struct tenxpress_phy_data *phy_data = efx->phy_data;
> -	bool change = false, link_ok;
> -	unsigned link_fc;
> +	bool change = false;
>  
>  	if (efx->phy_type = PHY_TYPE_SFX7101) {
> -		link_ok = sfx7101_link_ok(efx);
> +		bool link_ok = sfx7101_link_ok(efx);
>  		if (link_ok != efx->link_up) {
>  			change = true;
>  		} else {
> -			link_fc = mdio_clause45_get_pause(efx);
> +			unsigned int link_fc = mdio_clause45_get_pause(efx);
>  			if (link_fc != efx->link_fc)
>  				change = true;
>  		}
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

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

* Re: [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness
  2009-02-14 21:15   ` Hannes Eder
@ 2009-02-16  2:20     ` Jay Cliburn
  -1 siblings, 0 replies; 231+ messages in thread
From: Jay Cliburn @ 2009-02-16  2:20 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, 14 Feb 2009 22:15:17 +0100
Hannes Eder <hannes@hanneseder.net> wrote:

> Impact: While being at it: statics do not need to be initialized with 0.
> 
> Fix this sparse warnings:
>   drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Jay Cliburn <jcliburn@gmail.com>

> ---
>  drivers/net/atlx/atl1.c |    2 +-
>  drivers/net/atlx/atl2.c |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c
> index c0ceee0..43fc1b2 100644
> --- a/drivers/net/atlx/atl1.c
> +++ b/drivers/net/atlx/atl1.c
> @@ -105,7 +105,7 @@
>   * Default Value: 100 (200us)
>   */
>  static int __devinitdata int_mod_timer[ATL1_MAX_NIC+1] = ATL1_PARAM_INIT;
> -static int num_int_mod_timer;
> +static unsigned int num_int_mod_timer;
>  module_param_array_named(int_mod_timer, int_mod_timer, int,
>  	&num_int_mod_timer, 0);
>  MODULE_PARM_DESC(int_mod_timer, "Interrupt moderator timer");
> diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c
> index bc39449..9fe06c3 100644
> --- a/drivers/net/atlx/atl2.c
> +++ b/drivers/net/atlx/atl2.c
> @@ -2854,7 +2854,7 @@ static void atl2_force_ps(struct atl2_hw *hw)
>  #else
>  #define ATL2_PARAM(X, desc) \
>      static int __devinitdata X[ATL2_MAX_NIC+1] = ATL2_PARAM_INIT; \
> -    static int num_##X = 0; \
> +    static unsigned int num_##X; \
>      module_param_array_named(X, X, int, &num_##X, 0); \
>      MODULE_PARM_DESC(X, desc);
>  #endif
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix
@ 2009-02-16  2:20     ` Jay Cliburn
  0 siblings, 0 replies; 231+ messages in thread
From: Jay Cliburn @ 2009-02-16  2:20 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

On Sat, 14 Feb 2009 22:15:17 +0100
Hannes Eder <hannes@hanneseder.net> wrote:

> Impact: While being at it: statics do not need to be initialized with 0.
> 
> Fix this sparse warnings:
>   drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Jay Cliburn <jcliburn@gmail.com>

> ---
>  drivers/net/atlx/atl1.c |    2 +-
>  drivers/net/atlx/atl2.c |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c
> index c0ceee0..43fc1b2 100644
> --- a/drivers/net/atlx/atl1.c
> +++ b/drivers/net/atlx/atl1.c
> @@ -105,7 +105,7 @@
>   * Default Value: 100 (200us)
>   */
>  static int __devinitdata int_mod_timer[ATL1_MAX_NIC+1] = ATL1_PARAM_INIT;
> -static int num_int_mod_timer;
> +static unsigned int num_int_mod_timer;
>  module_param_array_named(int_mod_timer, int_mod_timer, int,
>  	&num_int_mod_timer, 0);
>  MODULE_PARM_DESC(int_mod_timer, "Interrupt moderator timer");
> diff --git a/drivers/net/atlx/atl2.c b/drivers/net/atlx/atl2.c
> index bc39449..9fe06c3 100644
> --- a/drivers/net/atlx/atl2.c
> +++ b/drivers/net/atlx/atl2.c
> @@ -2854,7 +2854,7 @@ static void atl2_force_ps(struct atl2_hw *hw)
>  #else
>  #define ATL2_PARAM(X, desc) \
>      static int __devinitdata X[ATL2_MAX_NIC+1] = ATL2_PARAM_INIT; \
> -    static int num_##X = 0; \
> +    static unsigned int num_##X; \
>      module_param_array_named(X, X, int, &num_##X, 0); \
>      MODULE_PARM_DESC(X, desc);
>  #endif
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static?
  2009-02-14 21:38   ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be Hannes Eder
@ 2009-02-16  6:48     ` Waskiewicz Jr, Peter P
  -1 siblings, 0 replies; 231+ messages in thread
From: Waskiewicz Jr, Peter P @ 2009-02-16  6:48 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

> Impact: Make symbol static.
> 
> Fix this sparse warning:
>   drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>

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

* Re: [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it
@ 2009-02-16  6:48     ` Waskiewicz Jr, Peter P
  0 siblings, 0 replies; 231+ messages in thread
From: Waskiewicz Jr, Peter P @ 2009-02-16  6:48 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel

> Impact: Make symbol static.
> 
> Fix this sparse warning:
>   drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be  static?
  2009-02-16  0:37   ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Ben Hutchings
  2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
@ 2009-02-16  9:38       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16  9:38 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: netdev, kernel-janitors, linux-kernel

On Mon, Feb 16, 2009 at 1:37 AM, Ben Hutchings
<bhutchings@solarflare.com> wrote:
> Hannes Eder wrote:
>> Impact: Include header file and include the function under the same
>> condition as in the header file.  If CONFIG_SFS_MTD is not defined
>> than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
>> 'static inline' with an empty function body in the header file.
>>
>> Fix this sparse warnings:
>>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/sfc/mtd.c |    3 +++
>>  1 files changed, 3 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
>> index 665cafb..94c9ed8 100644
>> --- a/drivers/net/sfc/mtd.c
>> +++ b/drivers/net/sfc/mtd.c
>> @@ -15,6 +15,7 @@
>>  #define EFX_DRIVER_NAME "sfc_mtd"
>>  #include "net_driver.h"
>>  #include "spi.h"
>> +#include "efx.h"
>>
>>  #define EFX_SPI_VERIFY_BUF_LEN 16
>>
>
> OK, but...
>
>> @@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
>>       return;
>>  }
>>
>> +#ifdef CONFIG_SFC_MTD
>>  void efx_mtd_remove(struct efx_nic *efx)
>>  {
>>       if (efx->spi_flash && efx->spi_flash->mtd) {
>> @@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
>>
>>       return 0;
>>  }
>> +#endif /* CONFIG_SFC_MTD */
>
> This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.

Even better than. It's actually not wrong, just done twice, so we can
omit it, thank you Ben. I'll send an update.

Hannes

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static?
@ 2009-02-16  9:38       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16  9:38 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: netdev, kernel-janitors, linux-kernel

On Mon, Feb 16, 2009 at 1:37 AM, Ben Hutchings
<bhutchings@solarflare.com> wrote:
> Hannes Eder wrote:
>> Impact: Include header file and include the function under the same
>> condition as in the header file.  If CONFIG_SFS_MTD is not defined
>> than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
>> 'static inline' with an empty function body in the header file.
>>
>> Fix this sparse warnings:
>>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/sfc/mtd.c |    3 +++
>>  1 files changed, 3 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
>> index 665cafb..94c9ed8 100644
>> --- a/drivers/net/sfc/mtd.c
>> +++ b/drivers/net/sfc/mtd.c
>> @@ -15,6 +15,7 @@
>>  #define EFX_DRIVER_NAME "sfc_mtd"
>>  #include "net_driver.h"
>>  #include "spi.h"
>> +#include "efx.h"
>>
>>  #define EFX_SPI_VERIFY_BUF_LEN 16
>>
>
> OK, but...
>
>> @@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
>>       return;
>>  }
>>
>> +#ifdef CONFIG_SFC_MTD
>>  void efx_mtd_remove(struct efx_nic *efx)
>>  {
>>       if (efx->spi_flash && efx->spi_flash->mtd) {
>> @@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
>>
>>       return 0;
>>  }
>> +#endif /* CONFIG_SFC_MTD */
>
> This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.

Even better than. It's actually not wrong, just done twice, so we can
omit it, thank you Ben. I'll send an update.

Hannes

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be
@ 2009-02-16  9:38       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16  9:38 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: netdev, kernel-janitors, linux-kernel

On Mon, Feb 16, 2009 at 1:37 AM, Ben Hutchings
<bhutchings@solarflare.com> wrote:
> Hannes Eder wrote:
>> Impact: Include header file and include the function under the same
>> condition as in the header file.  If CONFIG_SFS_MTD is not defined
>> than the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
>> 'static inline' with an empty function body in the header file.
>>
>> Fix this sparse warnings:
>>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
>>
>> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
>> ---
>>  drivers/net/sfc/mtd.c |    3 +++
>>  1 files changed, 3 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
>> index 665cafb..94c9ed8 100644
>> --- a/drivers/net/sfc/mtd.c
>> +++ b/drivers/net/sfc/mtd.c
>> @@ -15,6 +15,7 @@
>>  #define EFX_DRIVER_NAME "sfc_mtd"
>>  #include "net_driver.h"
>>  #include "spi.h"
>> +#include "efx.h"
>>
>>  #define EFX_SPI_VERIFY_BUF_LEN 16
>>
>
> OK, but...
>
>> @@ -201,6 +202,7 @@ static void efx_mtd_sync(struct mtd_info *mtd)
>>       return;
>>  }
>>
>> +#ifdef CONFIG_SFC_MTD
>>  void efx_mtd_remove(struct efx_nic *efx)
>>  {
>>       if (efx->spi_flash && efx->spi_flash->mtd) {
>> @@ -266,3 +268,4 @@ int efx_mtd_probe(struct efx_nic *efx)
>>
>>       return 0;
>>  }
>> +#endif /* CONFIG_SFC_MTD */
>
> This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.

Even better than. It's actually not wrong, just done twice, so we can
omit it, thank you Ben. I'll send an update.

Hannes

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

* [PATCH] drivers/net/sfc: fix sparse warnings: Should it be static?
  2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
@ 2009-02-16  9:54         ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16  9:54 UTC (permalink / raw)
  To: netdev; +Cc: Ben Hutchings, kernel-janitors, linux-kernel

Impact: Include the header file.  If CONFIG_SFC_MTD is not defined
then the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
'static inline' with an empty function body in the header file, but
the the whole file mtd.c is not built in this case.

Fix this sparse warnings:
  drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/mtd.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
index 665cafb..820c233 100644
--- a/drivers/net/sfc/mtd.c
+++ b/drivers/net/sfc/mtd.c
@@ -15,6 +15,7 @@
 #define EFX_DRIVER_NAME "sfc_mtd"
 #include "net_driver.h"
 #include "spi.h"
+#include "efx.h"
 
 #define EFX_SPI_VERIFY_BUF_LEN 16
 


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

* [PATCH] drivers/net/sfc: fix sparse warnings: Should it be static?
@ 2009-02-16  9:54         ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16  9:54 UTC (permalink / raw)
  To: netdev; +Cc: Ben Hutchings, kernel-janitors, linux-kernel

Impact: Include the header file.  If CONFIG_SFC_MTD is not defined
then the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
'static inline' with an empty function body in the header file, but
the the whole file mtd.c is not built in this case.

Fix this sparse warnings:
  drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
  drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 drivers/net/sfc/mtd.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/net/sfc/mtd.c b/drivers/net/sfc/mtd.c
index 665cafb..820c233 100644
--- a/drivers/net/sfc/mtd.c
+++ b/drivers/net/sfc/mtd.c
@@ -15,6 +15,7 @@
 #define EFX_DRIVER_NAME "sfc_mtd"
 #include "net_driver.h"
 #include "spi.h"
+#include "efx.h"
 
 #define EFX_SPI_VERIFY_BUF_LEN 16
 


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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
  2009-02-15 19:57       ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
@ 2009-02-16  9:58         ` walter harms
  -1 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-16  9:58 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel



Hannes Eder schrieb:
> On Sun, Feb 15, 2009 at 3:04 PM, walter harms <wharms@bfs.de> wrote:
>> Hi Hannes,
>> it is ok to replace a fixed boarder with ARRAY_SIZE()
>> in this special case i would success the following additional cleanup
>> (untestet !!)
>>
>>
>> static int set_free_irq(struct net_device *dev)
>> {
>>  int irqlist[] = {15,11,10,12,5,9,3,4}, i;
>>
>>        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>>           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>>                        dev->irq = irqlist[i];
>>                        return 0;
>>            }
>>        return -1;
>> }
>>
>> ....
>>
>> if (dev->irq < 2) {
>>         if ( set_free_irq(dev) < 0) {
>>                printk(" unable to get IRQ %d.\n", dev->irq);
>>                retval = -EAGAIN;
>>                goto out;
>>        }
>>
>> for me this looks more readable.
>>
>> getting a free interrupt from a list mus be a common problem ? I am not in driver programming
>> perhaps such a code is already in place somewhere  ?
> 
> I am a great fan of refactoring but in that case I would just leave it
> as is.  If extracting a method I would extract a little more here.
> 

Me too,
i hope the driver maintainer reads it and will react accordingly.

re,
 wh


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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol
@ 2009-02-16  9:58         ` walter harms
  0 siblings, 0 replies; 231+ messages in thread
From: walter harms @ 2009-02-16  9:58 UTC (permalink / raw)
  To: Hannes Eder; +Cc: netdev, kernel-janitors, linux-kernel



Hannes Eder schrieb:
> On Sun, Feb 15, 2009 at 3:04 PM, walter harms <wharms@bfs.de> wrote:
>> Hi Hannes,
>> it is ok to replace a fixed boarder with ARRAY_SIZE()
>> in this special case i would success the following additional cleanup
>> (untestet !!)
>>
>>
>> static int set_free_irq(struct net_device *dev)
>> {
>>  int irqlist[] = {15,11,10,12,5,9,3,4}, i;
>>
>>        for (i = 0; i < ARRAY_SIZE(irqlist); i++)
>>           if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
>>                        dev->irq = irqlist[i];
>>                        return 0;
>>            }
>>        return -1;
>> }
>>
>> ....
>>
>> if (dev->irq < 2) {
>>         if ( set_free_irq(dev) < 0) {
>>                printk(" unable to get IRQ %d.\n", dev->irq);
>>                retval = -EAGAIN;
>>                goto out;
>>        }
>>
>> for me this looks more readable.
>>
>> getting a free interrupt from a list mus be a common problem ? I am not in driver programming
>> perhaps such a code is already in place somewhere  ?
> 
> I am a great fan of refactoring but in that case I would just leave it
> as is.  If extracting a method I would extract a little more here.
> 

Me too,
i hope the driver maintainer reads it and will react accordingly.

re,
 wh


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

* Re: [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast  truncates bits from const value
  2009-02-15 12:13         ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
  (?)
@ 2009-02-16 17:29           ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16 17:29 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, Jay Schulist, Al Viro

On Sun, Feb 15, 2009 at 1:13 PM, Hannes Eder <hannes@hanneseder.net> wrote:
> Impact: Remove the write-only field 'current_ring_status' completely.
>
> Fix this sparse warnings:
>  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/tokenring/smctr.c |   10 ----------
>  drivers/net/tokenring/smctr.h |    1 -
>  2 files changed, 0 insertions(+), 11 deletions(-)
>
> diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
> index 5a3ff20..e66eb8a 100644
> --- a/drivers/net/tokenring/smctr.c
> +++ b/drivers/net/tokenring/smctr.c
> @@ -4393,52 +4393,42 @@ static int smctr_ring_status_chg(struct net_device *dev)
>         {
>                 case RING_RECOVERY:
>                         printk(KERN_INFO "%s: Ring Recovery\n", dev->name);
> -                        tp->current_ring_status |= RING_RECOVERY;
>                         break;
>
>                 case SINGLE_STATION:
>                         printk(KERN_INFO "%s: Single Statinon\n", dev->name);
> -                        tp->current_ring_status |= SINGLE_STATION;
>                         break;
>
>                 case COUNTER_OVERFLOW:
>                         printk(KERN_INFO "%s: Counter Overflow\n", dev->name);
> -                        tp->current_ring_status |= COUNTER_OVERFLOW;
>                         break;
>
>                 case REMOVE_RECEIVED:
>                         printk(KERN_INFO "%s: Remove Received\n", dev->name);
> -                        tp->current_ring_status |= REMOVE_RECEIVED;
>                         break;
>
>                 case AUTO_REMOVAL_ERROR:
>                         printk(KERN_INFO "%s: Auto Remove Error\n", dev->name);
> -                        tp->current_ring_status |= AUTO_REMOVAL_ERROR;
>                         break;
>
>                 case LOBE_WIRE_FAULT:
>                         printk(KERN_INFO "%s: Lobe Wire Fault\n", dev->name);
> -                        tp->current_ring_status |= LOBE_WIRE_FAULT;
>                         break;
>
>                 case TRANSMIT_BEACON:
>                         printk(KERN_INFO "%s: Transmit Beacon\n", dev->name);
> -                        tp->current_ring_status |= TRANSMIT_BEACON;
>                         break;
>
>                 case SOFT_ERROR:
>                         printk(KERN_INFO "%s: Soft Error\n", dev->name);
> -                        tp->current_ring_status |= SOFT_ERROR;
>                         break;
>
>                 case HARD_ERROR:
>                         printk(KERN_INFO "%s: Hard Error\n", dev->name);
> -                        tp->current_ring_status |= HARD_ERROR;
>                         break;
>
>                 case SIGNAL_LOSS:
>                         printk(KERN_INFO "%s: Signal Loss\n", dev->name);
> -                        tp->current_ring_status |= SIGNAL_LOSS;
>                         break;
>
>                 default:
> diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
> index 52df7dd..6e5700a 100644
> --- a/drivers/net/tokenring/smctr.h
> +++ b/drivers/net/tokenring/smctr.h
> @@ -977,7 +977,6 @@ typedef struct net_local {
>        __u8            monitor_state_ready;
>        __u16           ring_status;
>        __u8            ring_status_flags;
> -       __u8            current_ring_status;
>        __u8            state;
>
>        __u8            join_state;
>
>

forwarding a mail from Jay Schulist:

On Mon, Feb 16, 2009 at 4:17 PM, Jay Schulist <jjschlst@gmail.com> wrote:
> Hello,
> I'm at this email these days. That field was likely a hold-over from
> the original port of their windows driver to Linux, it has never been
> used that I know of. Removing it looks like a fine solution to me.
>
> Jay

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

* Re: [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
@ 2009-02-16 17:29           ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16 17:29 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, Jay Schulist, Al Viro

On Sun, Feb 15, 2009 at 1:13 PM, Hannes Eder <hannes@hanneseder.net> wrote:
> Impact: Remove the write-only field 'current_ring_status' completely.
>
> Fix this sparse warnings:
>  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/tokenring/smctr.c |   10 ----------
>  drivers/net/tokenring/smctr.h |    1 -
>  2 files changed, 0 insertions(+), 11 deletions(-)
>
> diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
> index 5a3ff20..e66eb8a 100644
> --- a/drivers/net/tokenring/smctr.c
> +++ b/drivers/net/tokenring/smctr.c
> @@ -4393,52 +4393,42 @@ static int smctr_ring_status_chg(struct net_device *dev)
>         {
>                 case RING_RECOVERY:
>                         printk(KERN_INFO "%s: Ring Recovery\n", dev->name);
> -                        tp->current_ring_status |= RING_RECOVERY;
>                         break;
>
>                 case SINGLE_STATION:
>                         printk(KERN_INFO "%s: Single Statinon\n", dev->name);
> -                        tp->current_ring_status |= SINGLE_STATION;
>                         break;
>
>                 case COUNTER_OVERFLOW:
>                         printk(KERN_INFO "%s: Counter Overflow\n", dev->name);
> -                        tp->current_ring_status |= COUNTER_OVERFLOW;
>                         break;
>
>                 case REMOVE_RECEIVED:
>                         printk(KERN_INFO "%s: Remove Received\n", dev->name);
> -                        tp->current_ring_status |= REMOVE_RECEIVED;
>                         break;
>
>                 case AUTO_REMOVAL_ERROR:
>                         printk(KERN_INFO "%s: Auto Remove Error\n", dev->name);
> -                        tp->current_ring_status |= AUTO_REMOVAL_ERROR;
>                         break;
>
>                 case LOBE_WIRE_FAULT:
>                         printk(KERN_INFO "%s: Lobe Wire Fault\n", dev->name);
> -                        tp->current_ring_status |= LOBE_WIRE_FAULT;
>                         break;
>
>                 case TRANSMIT_BEACON:
>                         printk(KERN_INFO "%s: Transmit Beacon\n", dev->name);
> -                        tp->current_ring_status |= TRANSMIT_BEACON;
>                         break;
>
>                 case SOFT_ERROR:
>                         printk(KERN_INFO "%s: Soft Error\n", dev->name);
> -                        tp->current_ring_status |= SOFT_ERROR;
>                         break;
>
>                 case HARD_ERROR:
>                         printk(KERN_INFO "%s: Hard Error\n", dev->name);
> -                        tp->current_ring_status |= HARD_ERROR;
>                         break;
>
>                 case SIGNAL_LOSS:
>                         printk(KERN_INFO "%s: Signal Loss\n", dev->name);
> -                        tp->current_ring_status |= SIGNAL_LOSS;
>                         break;
>
>                 default:
> diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
> index 52df7dd..6e5700a 100644
> --- a/drivers/net/tokenring/smctr.h
> +++ b/drivers/net/tokenring/smctr.h
> @@ -977,7 +977,6 @@ typedef struct net_local {
>        __u8            monitor_state_ready;
>        __u16           ring_status;
>        __u8            ring_status_flags;
> -       __u8            current_ring_status;
>        __u8            state;
>
>        __u8            join_state;
>
>

forwarding a mail from Jay Schulist:

On Mon, Feb 16, 2009 at 4:17 PM, Jay Schulist <jjschlst@gmail.com> wrote:
> Hello,
> I'm at this email these days. That field was likely a hold-over from
> the original port of their windows driver to Linux, it has never been
> used that I know of. Removing it looks like a fine solution to me.
>
> Jay

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

* Re: [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast
@ 2009-02-16 17:29           ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-16 17:29 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, Jay Schulist, Al Viro

On Sun, Feb 15, 2009 at 1:13 PM, Hannes Eder <hannes@hanneseder.net> wrote:
> Impact: Remove the write-only field 'current_ring_status' completely.
>
> Fix this sparse warnings:
>  drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>  drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>  drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>  drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>  drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>  drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>  drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
>
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ---
>  drivers/net/tokenring/smctr.c |   10 ----------
>  drivers/net/tokenring/smctr.h |    1 -
>  2 files changed, 0 insertions(+), 11 deletions(-)
>
> diff --git a/drivers/net/tokenring/smctr.c b/drivers/net/tokenring/smctr.c
> index 5a3ff20..e66eb8a 100644
> --- a/drivers/net/tokenring/smctr.c
> +++ b/drivers/net/tokenring/smctr.c
> @@ -4393,52 +4393,42 @@ static int smctr_ring_status_chg(struct net_device *dev)
>         {
>                 case RING_RECOVERY:
>                         printk(KERN_INFO "%s: Ring Recovery\n", dev->name);
> -                        tp->current_ring_status |= RING_RECOVERY;
>                         break;
>
>                 case SINGLE_STATION:
>                         printk(KERN_INFO "%s: Single Statinon\n", dev->name);
> -                        tp->current_ring_status |= SINGLE_STATION;
>                         break;
>
>                 case COUNTER_OVERFLOW:
>                         printk(KERN_INFO "%s: Counter Overflow\n", dev->name);
> -                        tp->current_ring_status |= COUNTER_OVERFLOW;
>                         break;
>
>                 case REMOVE_RECEIVED:
>                         printk(KERN_INFO "%s: Remove Received\n", dev->name);
> -                        tp->current_ring_status |= REMOVE_RECEIVED;
>                         break;
>
>                 case AUTO_REMOVAL_ERROR:
>                         printk(KERN_INFO "%s: Auto Remove Error\n", dev->name);
> -                        tp->current_ring_status |= AUTO_REMOVAL_ERROR;
>                         break;
>
>                 case LOBE_WIRE_FAULT:
>                         printk(KERN_INFO "%s: Lobe Wire Fault\n", dev->name);
> -                        tp->current_ring_status |= LOBE_WIRE_FAULT;
>                         break;
>
>                 case TRANSMIT_BEACON:
>                         printk(KERN_INFO "%s: Transmit Beacon\n", dev->name);
> -                        tp->current_ring_status |= TRANSMIT_BEACON;
>                         break;
>
>                 case SOFT_ERROR:
>                         printk(KERN_INFO "%s: Soft Error\n", dev->name);
> -                        tp->current_ring_status |= SOFT_ERROR;
>                         break;
>
>                 case HARD_ERROR:
>                         printk(KERN_INFO "%s: Hard Error\n", dev->name);
> -                        tp->current_ring_status |= HARD_ERROR;
>                         break;
>
>                 case SIGNAL_LOSS:
>                         printk(KERN_INFO "%s: Signal Loss\n", dev->name);
> -                        tp->current_ring_status |= SIGNAL_LOSS;
>                         break;
>
>                 default:
> diff --git a/drivers/net/tokenring/smctr.h b/drivers/net/tokenring/smctr.h
> index 52df7dd..6e5700a 100644
> --- a/drivers/net/tokenring/smctr.h
> +++ b/drivers/net/tokenring/smctr.h
> @@ -977,7 +977,6 @@ typedef struct net_local {
>        __u8            monitor_state_ready;
>        __u16           ring_status;
>        __u8            ring_status_flags;
> -       __u8            current_ring_status;
>        __u8            state;
>
>        __u8            join_state;
>
>

forwarding a mail from Jay Schulist:

On Mon, Feb 16, 2009 at 4:17 PM, Jay Schulist <jjschlst@gmail.com> wrote:
> Hello,
> I'm at this email these days. That field was likely a hold-over from
> the original port of their windows driver to Linux, it has never been
> used that I know of. Removing it looks like a fine solution to me.
>
> Jay

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

* Re: [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:11   ` [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:11:55 +0100

> Impact: Move variable declaration to a more inner scope.
> 
> Fix this sparse warning:
>   drivers/net/at1700.c:846:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/at1700.c:831:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:11:55 +0100

> Impact: Move variable declaration to a more inner scope.
> 
> Fix this sparse warning:
>   drivers/net/at1700.c:846:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/at1700.c:831:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:12   ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:10 +0100

> Impact: Remove redundant inner scope variable and while being at it
> make use of ARRAY_SIZE instead of a hardcoded number.
> 
> Fix this sparse warning:
>   drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
>   drivers/net/e2100.c:181:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:10 +0100

> Impact: Remove redundant inner scope variable and while being at it
> make use of ARRAY_SIZE instead of a hardcoded number.
> 
> Fix this sparse warning:
>   drivers/net/e2100.c:219:56: warning: symbol 'i' shadows an earlier one
>   drivers/net/e2100.c:181:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one
  2009-02-14 21:12   ` [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:23 +0100

> Impact: Remove redundant variable declaration or move them to a more
> inner scope.
> 
> Fix this sparse warnings:
>   drivers/net/ni65.c:900:37: warning: symbol 'p' shadows an earlier one
>   drivers/net/ni65.c:874:21: originally declared here
>   drivers/net/ni65.c:925:21: warning: symbol 'p' shadows an earlier one
>   drivers/net/ni65.c:874:21: originally declared here
>   drivers/net/ni65.c:945:29: warning: symbol 'k' shadows an earlier one
>   drivers/net/ni65.c:926:15: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:23 +0100

> Impact: Remove redundant variable declaration or move them to a more
> inner scope.
> 
> Fix this sparse warnings:
>   drivers/net/ni65.c:900:37: warning: symbol 'p' shadows an earlier one
>   drivers/net/ni65.c:874:21: originally declared here
>   drivers/net/ni65.c:925:21: warning: symbol 'p' shadows an earlier one
>   drivers/net/ni65.c:874:21: originally declared here
>   drivers/net/ni65.c:945:29: warning: symbol 'k' shadows an earlier one
>   drivers/net/ni65.c:926:15: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix signedness
  2009-02-14 21:12   ` [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:36 +0100

> Fix this sparse warnings:
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:36 +0100

> Fix this sparse warnings:
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/ns83820.c:479:36: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:12   ` [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:48 +0100

> Impact: Move variable declaration to a more inner scope.
> 
> Fix this sparse warning:
>   drivers/net/niu.c:2399:21: warning: symbol 'err' shadows an earlier one
>   drivers/net/niu.c:2287:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:12:48 +0100

> Impact: Move variable declaration to a more inner scope.
> 
> Fix this sparse warning:
>   drivers/net/niu.c:2399:21: warning: symbol 'err' shadows an earlier one
>   drivers/net/niu.c:2287:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix signedness
  2009-02-14 21:13   ` Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:13:24 +0100

> Impact: Besides from fixing the signedness issue remove some
> whitespace to obey to the 80 character limit.
> 
> Fix this sparse warnings:
>   drivers/net/lance.c:399:19: warning: incorrect type in assignment (different signedness)
>   drivers/net/lance.c:654:29: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:13:24 +0100

> Impact: Besides from fixing the signedness issue remove some
> whitespace to obey to the 80 character limit.
> 
> Fix this sparse warnings:
>   drivers/net/lance.c:399:19: warning: incorrect type in assignment (different signedness)
>   drivers/net/lance.c:654:29: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix signedness
  2009-02-14 21:13   ` Hannes Eder
@ 2009-02-18  1:21     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:13:39 +0100

> Fix this sparse warnings:
>   drivers/net/ni65.c:488:36: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix
@ 2009-02-18  1:21     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:21 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:13:39 +0100

> Fix this sparse warnings:
>   drivers/net/ni65.c:488:36: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness
  2009-02-14 21:29     ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
@ 2009-02-18  1:22       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: gorcunov; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Cyrill Gorcunov <gorcunov@gmail.com>
Date: Sun, 15 Feb 2009 00:29:48 +0300

> [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
> | Fix this sparse warnings:
> |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
> |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
> |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
> | 
> | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ...
> 
> Thanks Hannes,
> 
> Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>

Applied.

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

* Re: [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix
@ 2009-02-18  1:22       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: gorcunov; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Cyrill Gorcunov <gorcunov@gmail.com>
Date: Sun, 15 Feb 2009 00:29:48 +0300

> [Hannes Eder - Sat, Feb 14, 2009 at 10:13:52PM +0100]
> | Fix this sparse warnings:
> |   drivers/net/ppp_generic.c:919:43: warning: incorrect type in argument 1 (different signedness)
> |   drivers/net/pppoe.c:1195:43: warning: incorrect type in argument 1 (different signedness)
> |   drivers/net/pppol2tp.c:2666:43: warning: incorrect type in argument 1 (different signedness)
> | 
> | Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> ...
> 
> Thanks Hannes,
> 
> Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>

Applied.

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

* Re: [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer
  2009-02-15 14:00     ` Florian Fainelli
@ 2009-02-18  1:22       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: florian; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Florian Fainelli <florian@openwrt.org>
Date: Sun, 15 Feb 2009 15:00:06 +0100

> Hello Hannes,
> 
> Le Saturday 14 February 2009 22:14:04 Hannes Eder, vous avez écrit :
> > Fix this sparse warnings:
> >   drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
> >   drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer
> 
> Good catch, thanks.
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> 
> Acked-by: Florian Fainelli <florian@openwrt.org>

Applied.

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

* Re: [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using
@ 2009-02-18  1:22       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: florian; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Florian Fainelli <florian@openwrt.org>
Date: Sun, 15 Feb 2009 15:00:06 +0100

> Hello Hannes,
> 
> Le Saturday 14 February 2009 22:14:04 Hannes Eder, vous avez écrit :
> > Fix this sparse warnings:
> >   drivers/net/r6040.c:487:31: warning: Using plain integer as NULL pointer
> >   drivers/net/r6040.c:492:31: warning: Using plain integer as NULL pointer
> 
> Good catch, thanks.
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> 
> Acked-by: Florian Fainelli <florian@openwrt.org>

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

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

* Re: [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:14   ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:22     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:31 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/s2io.c:7184:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol
@ 2009-02-18  1:22     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:22 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:31 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/s2io.c:7184:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:14   ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:26     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:31 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/s2io.c:7184:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol
@ 2009-02-18  1:26     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:31 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/s2io.c:7223:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/s2io.c:7184:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:14   ` [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:26     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:45 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/arcnet/arcnet.c:383:21: warning: symbol 'count' shadows an earlier one
>   drivers/net/arcnet/arcnet.c:375:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol
@ 2009-02-18  1:26     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:45 +0100

> Impact: Remove redundant inner scope variable.
> 
> Fix this sparse warning:
>   drivers/net/arcnet/arcnet.c:383:21: warning: symbol 'count' shadows an earlier one
>   drivers/net/arcnet/arcnet.c:375:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix signedness
  2009-02-14 21:14   ` Hannes Eder
@ 2009-02-18  1:26     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:58 +0100

> Fix this sparse warnings:
>   drivers/net/atl1e/atl1e_main.c:716:39: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/atl1e/atl1e_param.c:57:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:68:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:81:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:92:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix
@ 2009-02-18  1:26     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:14:58 +0100

> Fix this sparse warnings:
>   drivers/net/atl1e/atl1e_main.c:716:39: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/atl1e/atl1e_param.c:57:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:68:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:81:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atl1e/atl1e_param.c:92:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness
  2009-02-14 21:15   ` Hannes Eder
@ 2009-02-18  1:26     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:17 +0100

> Impact: While being at it: statics do not need to be initialized with 0.
> 
> Fix this sparse warnings:
>   drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix
@ 2009-02-18  1:26     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:26 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:17 +0100

> Impact: While being at it: statics do not need to be initialized with 0.
> 
> Fix this sparse warnings:
>   drivers/net/atlx/atl1.c:109:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2870:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2880:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2894:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2904:1: warning: incorrect type in initializer (different signedness)
>   drivers/net/atlx/atl2.c:2913:1: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context imbalance
  2009-02-14 21:15   ` [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context Hannes Eder
@ 2009-02-18  1:27     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:33 +0100

> Impact: Attribute functions with __acquires(...) and/or __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/bonding/bond_alb.c:1675:9: warning: context imbalance in 'bond_alb_handle_active_change' - unexpected unlock
>   drivers/net/bonding/bond_alb.c:1742:9: warning: context imbalance in 'bond_alb_set_mac_address' - unexpected unlock
>   drivers/net/bonding/bond_main.c:1025:17: warning: context imbalance in 'bond_do_fail_over_mac' - unexpected unlock
>   drivers/net/bonding/bond_main.c:3195:13: warning: context imbalance in 'bond_info_seq_start' - wrong count at exit
>   drivers/net/bonding/bond_main.c:3234:13: warning: context imbalance in 'bond_info_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 14/43] drivers/net/bonding: fix sparse warnings:
@ 2009-02-18  1:27     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:33 +0100

> Impact: Attribute functions with __acquires(...) and/or __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/bonding/bond_alb.c:1675:9: warning: context imbalance in 'bond_alb_handle_active_change' - unexpected unlock
>   drivers/net/bonding/bond_alb.c:1742:9: warning: context imbalance in 'bond_alb_set_mac_address' - unexpected unlock
>   drivers/net/bonding/bond_main.c:1025:17: warning: context imbalance in 'bond_do_fail_over_mac' - unexpected unlock
>   drivers/net/bonding/bond_main.c:3195:13: warning: context imbalance in 'bond_info_seq_start' - wrong count at exit
>   drivers/net/bonding/bond_main.c:3234:13: warning: context imbalance in 'bond_info_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:15   ` [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  1:27     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:49 +0100

> Impact: Rename function scope variable.
> 
> Fix this sparse warning:
>   drivers/net/bonding/bond_main.c:4704:13: warning: symbol 'mode' shadows an earlier one
>   drivers/net/bonding/bond_main.c:95:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol
@ 2009-02-18  1:27     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:15:49 +0100

> Impact: Rename function scope variable.
> 
> Fix this sparse warning:
>   drivers/net/bonding/bond_main.c:4704:13: warning: symbol 'mode' shadows an earlier one
>   drivers/net/bonding/bond_main.c:95:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one
  2009-02-15 21:30     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows Divy Le Ray
@ 2009-02-18  1:27       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: divy; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Divy Le Ray <divy@chelsio.com>
Date: Sun, 15 Feb 2009 13:30:34 -0800

> Hannes Eder wrote:
> > Impact: Move variable declaration as close to usage as possible.
> >
> > Fix this sparse warning:
> >   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> >   
> Acked-by: Divy Le Ray <divy@chelsio.com>

Applied.

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

* Re: [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol
@ 2009-02-18  1:27       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: divy; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Divy Le Ray <divy@chelsio.com>
Date: Sun, 15 Feb 2009 13:30:34 -0800

> Hannes Eder wrote:
> > Impact: Move variable declaration as close to usage as possible.
> >
> > Fix this sparse warning:
> >   drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> >   
> Acked-by: Divy Le Ray <divy@chelsio.com>

Applied.

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

* Re: [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness
  2009-02-15 21:32     ` Divy Le Ray
@ 2009-02-18  1:27       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: divy; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Divy Le Ray <divy@chelsio.com>
Date: Sun, 15 Feb 2009 13:32:07 -0800

> Hannes Eder wrote:
> > Fix this sparse warning:
> >   drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> >   
> Acked-by: Divy Le Ray <divy@chelsio.com>

Applied.

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

* Re: [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix
@ 2009-02-18  1:27       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: divy; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Divy Le Ray <divy@chelsio.com>
Date: Sun, 15 Feb 2009 13:32:07 -0800

> Hannes Eder wrote:
> > Fix this sparse warning:
> >   drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness)
> >
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> >   
> Acked-by: Divy Le Ray <divy@chelsio.com>

Applied.

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

* Re: [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be static?
  2009-02-14 21:32   ` [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be Hannes Eder
@ 2009-02-18  1:27     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:32:25 +0100

> Impact: Make symbol static.
> 
> Fix this sparse warning:
>   drivers/net/e1000e/82571.c:1229:5: warning: symbol 'e1000_check_for_serdes_link_82571' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should
@ 2009-02-18  1:27     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:32:25 +0100

> Impact: Make symbol static.
> 
> Fix this sparse warning:
>   drivers/net/e1000e/82571.c:1229:5: warning: symbol 'e1000_check_for_serdes_link_82571' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string literal and no ...
  2009-02-14 21:33   ` [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string Hannes Eder
@ 2009-02-18  1:27     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:33:21 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it fix an issue in 'mkiss_init_driver', where in case of an
> error the status code was not passed to printk.
> 
> Fix this warnings:
>   drivers/net/hamradio/6pack.c: In function 'sixpack_init_driver':
>   drivers/net/hamradio/6pack.c:802: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/bpqether.c: In function 'bpq_init_driver':
>   drivers/net/hamradio/bpqether.c:609: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/mkiss.c: In function 'mkiss_init_driver':
>   drivers/net/hamradio/mkiss.c:988: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/mkiss.c:991: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/scc.c: In function 'scc_init_driver':
>   drivers/net/hamradio/scc.c:2109: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/yam.c: In function 'yam_init_driver':
>   drivers/net/hamradio/yam.c:1094: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 19/43] drivers/net/hamradio: fix warning: format not a
@ 2009-02-18  1:27     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:27 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:33:21 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it fix an issue in 'mkiss_init_driver', where in case of an
> error the status code was not passed to printk.
> 
> Fix this warnings:
>   drivers/net/hamradio/6pack.c: In function 'sixpack_init_driver':
>   drivers/net/hamradio/6pack.c:802: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/bpqether.c: In function 'bpq_init_driver':
>   drivers/net/hamradio/bpqether.c:609: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/mkiss.c: In function 'mkiss_init_driver':
>   drivers/net/hamradio/mkiss.c:988: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/mkiss.c:991: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/scc.c: In function 'scc_init_driver':
>   drivers/net/hamradio/scc.c:2109: warning: format not a string literal and no format arguments
>   drivers/net/hamradio/yam.c: In function 'yam_init_driver':
>   drivers/net/hamradio/yam.c:1094: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context imbalance
  2009-02-14 21:34   ` [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context Hannes Eder
@ 2009-02-18  1:38     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:34:52 +0100

> Impact: Attribute functions with __acquires(...) resp. __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/hamradio/bpqether.c:387:13: warning: context imbalance in 'bpq_seq_start' - wrong count at exit
>   drivers/net/hamradio/bpqether.c:419:13: warning: context imbalance in 'bpq_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 20/43] drivers/net/hamradio: fix sparse warning:
@ 2009-02-18  1:38     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:34:52 +0100

> Impact: Attribute functions with __acquires(...) resp. __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/hamradio/bpqether.c:387:13: warning: context imbalance in 'bpq_seq_start' - wrong count at exit
>   drivers/net/hamradio/bpqether.c:419:13: warning: context imbalance in 'bpq_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:35   ` [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol Hannes Eder
@ 2009-02-18  1:38     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:35:35 +0100

> Impact: Rename inner scrope variable.
> 
> Fix this sparse warning:
>   drivers/net/hamradio/yam.c:856:35: warning: symbol 'dev' shadows an earlier one
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol
@ 2009-02-18  1:38     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:35:35 +0100

> Impact: Rename inner scrope variable.
> 
> Fix this sparse warning:
>   drivers/net/hamradio/yam.c:856:35: warning: symbol 'dev' shadows an earlier one
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix signedness
  2009-02-14 21:36   ` [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix Hannes Eder
@ 2009-02-18  1:38     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:36:20 +0100

> Fix this sparse warnings:
>   drivers/net/hamradio/hdlcdrv.c:274:34: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:279:47: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:288:39: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:300:47: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix
@ 2009-02-18  1:38     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:38 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:36:20 +0100

> Fix this sparse warnings:
>   drivers/net/hamradio/hdlcdrv.c:274:34: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:279:47: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:288:39: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/hamradio/hdlcdrv.c:300:47: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:38   ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an Hannes Eder
@ 2009-02-18  1:39     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:38:08 +0100

> Impact: Move variable declaration as far inner as possible.
> 
> Fix this sparse warning:
>   drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
>   drivers/net/igb/igb_main.c:1855:16: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

There have been some changes recently to the igb driver so
this patch no longer applies.

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

* Re: [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol
@ 2009-02-18  1:39     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:38:08 +0100

> Impact: Move variable declaration as far inner as possible.
> 
> Fix this sparse warning:
>   drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
>   drivers/net/igb/igb_main.c:1855:16: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

There have been some changes recently to the igb driver so
this patch no longer applies.

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

* Re: [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static?
  2009-02-16  6:48     ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it Waskiewicz Jr, Peter P
@ 2009-02-18  1:39       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: peter.p.waskiewicz.jr; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: "Waskiewicz Jr, Peter P" <peter.p.waskiewicz.jr@intel.com>
Date: Sun, 15 Feb 2009 22:48:51 -0800 (Pacific Standard Time)

> > Impact: Make symbol static.
> > 
> > Fix this sparse warning:
> >   drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?
> > 
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> 
> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>

Applied.

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

* Re: [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it
@ 2009-02-18  1:39       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: peter.p.waskiewicz.jr; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: "Waskiewicz Jr, Peter P" <peter.p.waskiewicz.jr@intel.com>
Date: Sun, 15 Feb 2009 22:48:51 -0800 (Pacific Standard Time)

> > Impact: Make symbol static.
> > 
> > Fix this sparse warning:
> >   drivers/net/ixgbe/ixgbe_82598.c:59:5: warning: symbol 'ixgbe_get_pcie_msix_count_82598' was not declared. Should it be static?
> > 
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> 
> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>

Applied.

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

* Re: [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string literal and no ...
  2009-02-14 21:39   ` [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string Hannes Eder
@ 2009-02-18  1:39     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:39:23 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it prefix the message with KERN_INFO.
> 
> Fix this warnings:
>   drivers/net/pcmcia/axnet_cs.c:1716: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a
@ 2009-02-18  1:39     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:39:23 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it prefix the message with KERN_INFO.
> 
> Fix this warnings:
>   drivers/net/pcmcia/axnet_cs.c:1716: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one
  2009-02-16  0:38     ` Ben Hutchings
@ 2009-02-18  1:39       ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: bhutchings; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Ben Hutchings <bhutchings@solarflare.com>
Date: Mon, 16 Feb 2009 00:38:20 +0000

> Hannes Eder wrote:
> > Impact: Move variable declaration as close to their usage as possible.
> > 
> > Fix this sparse warning:
> >   drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
> >   drivers/net/sfc/tenxpress.c:575:30: originally declared here
> > 
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> Acked-by: Ben Hutchings <bhutchings@solarflare.com>

Applied.

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

* Re: [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol
@ 2009-02-18  1:39       ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: bhutchings; +Cc: hannes, netdev, kernel-janitors, linux-kernel

From: Ben Hutchings <bhutchings@solarflare.com>
Date: Mon, 16 Feb 2009 00:38:20 +0000

> Hannes Eder wrote:
> > Impact: Move variable declaration as close to their usage as possible.
> > 
> > Fix this sparse warning:
> >   drivers/net/sfc/tenxpress.c:589:22: warning: symbol 'link_ok' shadows an earlier one
> >   drivers/net/sfc/tenxpress.c:575:30: originally declared here
> > 
> > Signed-off-by: Hannes Eder <hannes@hanneseder.net>
> Acked-by: Ben Hutchings <bhutchings@solarflare.com>

Applied.

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static?
  2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
@ 2009-02-18  1:39         ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: bhutchings, netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Mon, 16 Feb 2009 10:38:26 +0100

> On Mon, Feb 16, 2009 at 1:37 AM, Ben Hutchings
> <bhutchings@solarflare.com> wrote:
> > This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.
> 
> Even better than. It's actually not wrong, just done twice, so we can
> omit it, thank you Ben. I'll send an update.

Ok, I'll skip over this patch.

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

* Re: [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it
@ 2009-02-18  1:39         ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:39 UTC (permalink / raw)
  To: hannes; +Cc: bhutchings, netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Mon, 16 Feb 2009 10:38:26 +0100

> On Mon, Feb 16, 2009 at 1:37 AM, Ben Hutchings
> <bhutchings@solarflare.com> wrote:
> > This is wrong.  The entire file is conditional on CONFIG_SFC_MTD.
> 
> Even better than. It's actually not wrong, just done twice, so we can
> omit it, thank you Ben. I'll send an update.

Ok, I'll skip over this patch.

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

* Re: [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be static?
  2009-02-14 21:43   ` [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be Hannes Eder
@ 2009-02-18  1:40     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:40 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:43:15 +0100

> Impact: Move function declarations to header file.
> 
> Fix this sparse warnings:
>   drivers/net/skfp/cfm.c:146:6: warning: symbol 'all_selection_criteria' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:186:6: warning: symbol 'mac1_irq' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:284:6: warning: symbol 'read_address' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:323:6: warning: symbol 'init_board' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:72:24: warning: symbol 'fddi_broadcast' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:679:6: warning: symbol 'mac2_irq' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:805:6: warning: symbol 'mac3_irq' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:856:5: warning: symbol 'init_fplus' was not declared. Should it be static?
>   drivers/net/skfp/pcmplc.c:404:6: warning: symbol 'init_plc' was not declared. Should it be static?
>   drivers/net/skfp/pcmplc.c:1592:5: warning: symbol 'pcm_status_twisted' was not declared. Should it be static?
>   drivers/net/skfp/smtinit.c:68:5: warning: symbol 'init_smt' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it
@ 2009-02-18  1:40     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:40 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:43:15 +0100

> Impact: Move function declarations to header file.
> 
> Fix this sparse warnings:
>   drivers/net/skfp/cfm.c:146:6: warning: symbol 'all_selection_criteria' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:186:6: warning: symbol 'mac1_irq' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:284:6: warning: symbol 'read_address' was not declared. Should it be static?
>   drivers/net/skfp/drvfbi.c:323:6: warning: symbol 'init_board' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:72:24: warning: symbol 'fddi_broadcast' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:679:6: warning: symbol 'mac2_irq' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:805:6: warning: symbol 'mac3_irq' was not declared. Should it be static?
>   drivers/net/skfp/fplustm.c:856:5: warning: symbol 'init_fplus' was not declared. Should it be static?
>   drivers/net/skfp/pcmplc.c:404:6: warning: symbol 'init_plc' was not declared. Should it be static?
>   drivers/net/skfp/pcmplc.c:1592:5: warning: symbol 'pcm_status_twisted' was not declared. Should it be static?
>   drivers/net/skfp/smtinit.c:68:5: warning: symbol 'init_smt' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string literal and no ...
  2009-02-14 21:44   ` [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string Hannes Eder
@ 2009-02-18  1:40     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:40 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:44:19 +0100

> Impact: Use 'static const char[]' instead of 'static char[]'.
> 
> Fix this warnings:
>   drivers/net/tokenring/smctr.c:3644: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 29/43] drivers/net/tokenring: fix warning: format not a
@ 2009-02-18  1:40     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:40 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:44:19 +0100

> Impact: Use 'static const char[]' instead of 'static char[]'.
> 
> Fix this warnings:
>   drivers/net/tokenring/smctr.c:3644: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:44   ` [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol Hannes Eder
@ 2009-02-18  1:41     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:41 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:44:44 +0100

> Impact: Remove redundant variables.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/lanstreamer.c:619:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tokenring/lanstreamer.c:589:13: originally declared here
>   drivers/net/tokenring/madgemc.c:695:34: warning: symbol 'tp' shadows an earlier one
>   drivers/net/tokenring/madgemc.c:689:26: originally declared here
>   drivers/net/tokenring/olympic.c:702:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tokenring/olympic.c:440:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 30/43] drivers/net/tokenring: fix sparse warning:
@ 2009-02-18  1:41     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  1:41 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:44:44 +0100

> Impact: Remove redundant variables.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/lanstreamer.c:619:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tokenring/lanstreamer.c:589:13: originally declared here
>   drivers/net/tokenring/madgemc.c:695:34: warning: symbol 'tp' shadows an earlier one
>   drivers/net/tokenring/madgemc.c:689:26: originally declared here
>   drivers/net/tokenring/olympic.c:702:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tokenring/olympic.c:440:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 32/43] drivers/net/tulip: fix warning: format not a string literal and no ...
  2009-02-14 21:46   ` [PATCH 32/43] drivers/net/tulip: fix warning: format not a string Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:46:59 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it add a KERN_INFO prefix.
> 
> Fix this warning:
>   drivers/net/tulip/de4x5.c: In function 'de4x5_hw_init':
>   drivers/net/tulip/de4x5.c:1268: warning: format not a string literal and no format arguments
>   drivers/net/tulip/winbond-840.c: In function 'w840_init':
>   drivers/net/tulip/winbond-840.c:1666: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 32/43] drivers/net/tulip: fix warning: format not a
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:46:59 +0100

> Impact: Use 'static const char[]' instead of 'static char[]' and while
> being at it add a KERN_INFO prefix.
> 
> Fix this warning:
>   drivers/net/tulip/de4x5.c: In function 'de4x5_hw_init':
>   drivers/net/tulip/de4x5.c:1268: warning: format not a string literal and no format arguments
>   drivers/net/tulip/winbond-840.c: In function 'w840_init':
>   drivers/net/tulip/winbond-840.c:1666: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:47   ` [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:47:30 +0100

> Impact: Rename a local variable resp. remove a redundant variable and
> while being at it use more unform loop constructs.
> 
> Fix this sparse warning:
>   drivers/net/tulip/de4x5.c:3944:13: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/de4x5.c:3938:9: originally declared here
>   drivers/net/tulip/media.c:72:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/media.c:54:13: originally declared here
>   drivers/net/tulip/media.c:134:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/media.c:117:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:47:30 +0100

> Impact: Rename a local variable resp. remove a redundant variable and
> while being at it use more unform loop constructs.
> 
> Fix this sparse warning:
>   drivers/net/tulip/de4x5.c:3944:13: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/de4x5.c:3938:9: originally declared here
>   drivers/net/tulip/media.c:72:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/media.c:54:13: originally declared here
>   drivers/net/tulip/media.c:134:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/tulip/media.c:117:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be static?
  2009-02-14 21:47   ` [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:47:47 +0100

> Impact: Make symbols static.
> 
> Fix this sparse warnings:
>   drivers/net/usb/hso.c:1249:6: warning: symbol 'hso_unthrottle_tasklet' was not declared. Should it be static?
>   drivers/net/usb/hso.c:1268:6: warning: symbol 'hso_unthrottle_workfunc' was not declared. Should it be static?
>   drivers/net/usb/hso.c:1466:5: warning: symbol 'tiocmget_submit_urb' was not declared. Should it be static?
>   drivers/net/usb/smsc95xx.c:62:5: warning: symbol 'turbo_mode' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:47:47 +0100

> Impact: Make symbols static.
> 
> Fix this sparse warnings:
>   drivers/net/usb/hso.c:1249:6: warning: symbol 'hso_unthrottle_tasklet' was not declared. Should it be static?
>   drivers/net/usb/hso.c:1268:6: warning: symbol 'hso_unthrottle_workfunc' was not declared. Should it be static?
>   drivers/net/usb/hso.c:1466:5: warning: symbol 'tiocmget_submit_urb' was not declared. Should it be static?
>   drivers/net/usb/smsc95xx.c:62:5: warning: symbol 'turbo_mode' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 35/43] drivers/net/wan: fix warning: format not a string literal and no ...
  2009-02-14 21:48   ` [PATCH 35/43] drivers/net/wan: fix warning: format not a string Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:07 +0100

> Impact: Use 'static const char[]' instead of 'static char[]'.
> 
> Fix this compilation warnings:
>   drivers/net/wan/lapbether.c: In function 'lapbeth_init_driver':
>   drivers/net/wan/lapbether.c:441: warning: format not a string literal and no format arguments
>   drivers/net/wan/z85230.c: In function 'z85230_init_driver':
>   drivers/net/wan/z85230.c:1782: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 35/43] drivers/net/wan: fix warning: format not a
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:07 +0100

> Impact: Use 'static const char[]' instead of 'static char[]'.
> 
> Fix this compilation warnings:
>   drivers/net/wan/lapbether.c: In function 'lapbeth_init_driver':
>   drivers/net/wan/lapbether.c:441: warning: format not a string literal and no format arguments
>   drivers/net/wan/z85230.c: In function 'z85230_init_driver':
>   drivers/net/wan/z85230.c:1782: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an earlier one
  2009-02-14 21:48   ` [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:25 +0100

> Impact: Rename function scope variable and while being at it fix some
> coding style issues.
> 
> Fix this sparse warning:
>   drivers/net/wan/sbni.c:1526:14: warning: symbol 'num' shadows an earlier one
>   drivers/net/wan/sbni.c:160:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:25 +0100

> Impact: Rename function scope variable and while being at it fix some
> coding style issues.
> 
> Fix this sparse warning:
>   drivers/net/wan/sbni.c:1526:14: warning: symbol 'num' shadows an earlier one
>   drivers/net/wan/sbni.c:160:13: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 37/43] drivers/net/wireless: fix sparse warning: context imbalance
  2009-02-14 21:48   ` [PATCH 37/43] drivers/net/wireless: fix sparse warning: context Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:44 +0100

> Impact: Attribute function with __acquires(...) resp. __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/wireless/strip.c:955:21: warning: context imbalance in 'strip_seq_start' - wrong count at exit
>   drivers/net/wireless/strip.c:975:13: warning: context imbalance in 'strip_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 37/43] drivers/net/wireless: fix sparse warning:
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:48:44 +0100

> Impact: Attribute function with __acquires(...) resp. __releases(...).
> 
> Fix this sparse warnings:
>   drivers/net/wireless/strip.c:955:21: warning: context imbalance in 'strip_seq_start' - wrong count at exit
>   drivers/net/wireless/strip.c:975:13: warning: context imbalance in 'strip_seq_stop' - unexpected unlock
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one
  2009-02-14 21:49   ` [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:09 +0100

> Impact:
>   Move variable closer to usage resp.
>   remove redundant variables resp.
>   rename function scope variable.
> 
> Fix this sparse warnings:
>   drivers/net/wireless/airo.c:3840:29: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/airo.c:3847:29: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/airo.c:3861:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/wavelan.c:43:13: warning: symbol 'irq' shadows an earlier one
>   drivers/net/wireless/wavelan.p.h:692:17: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 38/43] drivers/net/wireless: fix sparse warnings:
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:09 +0100

> Impact:
>   Move variable closer to usage resp.
>   remove redundant variables resp.
>   rename function scope variable.
> 
> Fix this sparse warnings:
>   drivers/net/wireless/airo.c:3840:29: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/airo.c:3847:29: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/airo.c:3861:21: warning: symbol 'i' shadows an earlier one
>   drivers/net/wireless/airo.c:3751:13: originally declared here
>   drivers/net/wireless/wavelan.c:43:13: warning: symbol 'irq' shadows an earlier one
>   drivers/net/wireless/wavelan.p.h:692:17: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix signedness
  2009-02-14 21:49   ` [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:26 +0100

> Fix this sparse warnings:
>   drivers/net/wireless/airo.c:2102:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2126:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2167:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2191:21: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.



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

* Re: [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:26 +0100

> Fix this sparse warnings:
>   drivers/net/wireless/airo.c:2102:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2126:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2167:21: warning: incorrect type in initializer (different signedness)
>   drivers/net/wireless/airo.c:2191:21: warning: incorrect type in initializer (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.



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

* Re: [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should it be static?
  2009-02-14 21:49   ` [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should Hannes Eder
@ 2009-02-18  3:35     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:48 +0100

> Impact: Make symbols static.
> 
> Fix this sparse warnings:
>   drivers/net/wireless/ath9k/eeprom.c:1343:5: warning: symbol 'ath9k_hw_4k_get_spur_channel' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:1372:19: warning: symbol 'eep_4k_ops' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:2649:5: warning: symbol 'ath9k_hw_def_get_spur_channel' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:2678:19: warning: symbol 'eep_def_ops' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings:
@ 2009-02-18  3:35     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:35 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:49:48 +0100

> Impact: Make symbols static.
> 
> Fix this sparse warnings:
>   drivers/net/wireless/ath9k/eeprom.c:1343:5: warning: symbol 'ath9k_hw_4k_get_spur_channel' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:1372:19: warning: symbol 'eep_4k_ops' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:2649:5: warning: symbol 'ath9k_hw_def_get_spur_channel' was not declared. Should it be static?
>   drivers/net/wireless/ath9k/eeprom.c:2678:19: warning: symbol 'eep_def_ops' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a string literal and no ...
  2009-02-14 21:50   ` [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a Hannes Eder
@ 2009-02-18  3:49     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:06 +0100

> Fix this compilation warning:
>   drivers/net/wireless/b43/main.c: In function 'b43_print_fw_helptext':
>   drivers/net/wireless/b43/main.c:1971: warning: format not a string literal and no format arguments
>   drivers/net/wireless/b43/main.c:1973: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 41/43] drivers/net/wireless/b43: fix warning: format
@ 2009-02-18  3:49     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:06 +0100

> Fix this compilation warning:
>   drivers/net/wireless/b43/main.c: In function 'b43_print_fw_helptext':
>   drivers/net/wireless/b43/main.c:1971: warning: format not a string literal and no format arguments
>   drivers/net/wireless/b43/main.c:1973: warning: format not a string literal and no format arguments
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness
  2009-02-14 21:50   ` [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix Hannes Eder
@ 2009-02-18  3:49     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:26 +0100

> Fix this sparse warnings:
>   drivers/net/wireless/ipw2x00/ipw2100.c:1930:43: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1938:76: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1946:67: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1953:72: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4071:73: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4078:43: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4084:67: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:7141:73: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:8317:48: warning: incorrect type in argument 4 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse
@ 2009-02-18  3:49     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:26 +0100

> Fix this sparse warnings:
>   drivers/net/wireless/ipw2x00/ipw2100.c:1930:43: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1938:76: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1946:67: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:1953:72: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4071:73: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4078:43: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:4084:67: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:7141:73: warning: incorrect type in argument 4 (different signedness)
>   drivers/net/wireless/ipw2x00/ipw2100.c:8317:48: warning: incorrect type in argument 4 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix signedness
  2009-02-14 21:50   ` [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix Hannes Eder
@ 2009-02-18  3:49     ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:45 +0100

> Fix sparse warning:
>   drivers/net/wireless/prism54/isl_ioctl.c:2997:32: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/wireless/prism54/oid_mgt.c:712:42: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 43/43] drivers/net/wireless/prism54: fix sparse
@ 2009-02-18  3:49     ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Sat, 14 Feb 2009 22:50:45 +0100

> Fix sparse warning:
>   drivers/net/wireless/prism54/isl_ioctl.c:2997:32: warning: incorrect type in argument 2 (different signedness)
>   drivers/net/wireless/prism54/oid_mgt.c:712:42: warning: incorrect type in argument 2 (different signedness)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value
  2009-02-15 12:13         ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
@ 2009-02-18  3:49           ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel, jjschlst, viro

From: Hannes Eder <hannes@hanneseder.net>
Date: Sun, 15 Feb 2009 13:13:01 +0100

> Impact: Remove the write-only field 'current_ring_status' completely.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* Re: [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning:
@ 2009-02-18  3:49           ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-18  3:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel, jjschlst, viro

From: Hannes Eder <hannes@hanneseder.net>
Date: Sun, 15 Feb 2009 13:13:01 +0100

> Impact: Remove the write-only field 'current_ring_status' completely.
> 
> Fix this sparse warnings:
>   drivers/net/tokenring/smctr.c:4410:52: warning: cast truncates bits from constant value (100 becomes 0)
>   drivers/net/tokenring/smctr.c:4415:52: warning: cast truncates bits from constant value (400 becomes 0)
>   drivers/net/tokenring/smctr.c:4420:52: warning: cast truncates bits from constant value (800 becomes 0)
>   drivers/net/tokenring/smctr.c:4425:52: warning: cast truncates bits from constant value (1000 becomes 0)
>   drivers/net/tokenring/smctr.c:4430:52: warning: cast truncates bits from constant value (2000 becomes 0)
>   drivers/net/tokenring/smctr.c:4435:52: warning: cast truncates bits from constant value (4000 becomes 0)
>   drivers/net/tokenring/smctr.c:4440:52: warning: cast truncates bits from constant value (8000 becomes 0)
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied.

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

* [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows an earlier one
  2009-02-18  1:39     ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol David Miller
@ 2009-02-18 21:49       ` Hannes Eder
  -1 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-18 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, David Miller

Impact: Move variable declaration as far inner as possible.

Fix this sparse warning:
  drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
  drivers/net/igb/igb_main.c:1855:16: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

On Wed, Feb 18, 2009 at 2:39 AM, David Miller <davem@davemloft.net> wrote:
> There have been some changes recently to the igb driver so
> this patch no longer applies.

Conflict resolved, should apply now.

Best, -Hannes

 drivers/net/igb/igb_main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index 43f489a..23431d8 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -1973,7 +1973,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	struct e1000_hw *hw = &adapter->hw;
 	u32 rctl, rxcsum;
 	u32 rxdctl;
-	int i, j;
+	int i;
 
 	/* disable receives while setting up the descriptors */
 	rctl = rd32(E1000_RCTL);
@@ -1988,7 +1988,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	 * the Base and Length of the Rx Descriptor Ring */
 	for (i = 0; i < adapter->num_rx_queues; i++) {
 		struct igb_ring *ring = &adapter->rx_ring[i];
-		j = ring->reg_idx;
+		int j = ring->reg_idx;
 		rdba = ring->dma;
 		wr32(E1000_RDBAL(j),
 		     rdba & 0x00000000ffffffffULL);


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

* [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows
@ 2009-02-18 21:49       ` Hannes Eder
  0 siblings, 0 replies; 231+ messages in thread
From: Hannes Eder @ 2009-02-18 21:49 UTC (permalink / raw)
  To: netdev; +Cc: kernel-janitors, linux-kernel, David Miller

Impact: Move variable declaration as far inner as possible.

Fix this sparse warning:
  drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
  drivers/net/igb/igb_main.c:1855:16: originally declared here

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---

On Wed, Feb 18, 2009 at 2:39 AM, David Miller <davem@davemloft.net> wrote:
> There have been some changes recently to the igb driver so
> this patch no longer applies.

Conflict resolved, should apply now.

Best, -Hannes

 drivers/net/igb/igb_main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index 43f489a..23431d8 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -1973,7 +1973,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	struct e1000_hw *hw = &adapter->hw;
 	u32 rctl, rxcsum;
 	u32 rxdctl;
-	int i, j;
+	int i;
 
 	/* disable receives while setting up the descriptors */
 	rctl = rd32(E1000_RCTL);
@@ -1988,7 +1988,7 @@ static void igb_configure_rx(struct igb_adapter *adapter)
 	 * the Base and Length of the Rx Descriptor Ring */
 	for (i = 0; i < adapter->num_rx_queues; i++) {
 		struct igb_ring *ring = &adapter->rx_ring[i];
-		j = ring->reg_idx;
+		int j = ring->reg_idx;
 		rdba = ring->dma;
 		wr32(E1000_RDBAL(j),
 		     rdba & 0x00000000ffffffffULL);


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

* Re: [PATCH] drivers/net/sfc: fix sparse warnings: Should it be static?
  2009-02-16  9:54         ` Hannes Eder
@ 2009-02-19  1:49           ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-19  1:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, bhutchings, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Mon, 16 Feb 2009 10:54:38 +0100

> Impact: Include the header file.  If CONFIG_SFC_MTD is not defined
> then the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
> 'static inline' with an empty function body in the header file, but
> the the whole file mtd.c is not built in this case.
> 
> Fix this sparse warnings:
>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied to net-next-2.6, thanks.

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

* Re: [PATCH] drivers/net/sfc: fix sparse warnings: Should it be
@ 2009-02-19  1:49           ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-19  1:49 UTC (permalink / raw)
  To: hannes; +Cc: netdev, bhutchings, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Mon, 16 Feb 2009 10:54:38 +0100

> Impact: Include the header file.  If CONFIG_SFC_MTD is not defined
> then the functions 'efx_mtd_remove' and 'efx_mtd_rename' are defined
> 'static inline' with an empty function body in the header file, but
> the the whole file mtd.c is not built in this case.
> 
> Fix this sparse warnings:
>   drivers/net/sfc/mtd.c:204:6: warning: symbol 'efx_mtd_remove' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:221:6: warning: symbol 'efx_mtd_rename' was not declared. Should it be static?
>   drivers/net/sfc/mtd.c:230:5: warning: symbol 'efx_mtd_probe' was not declared. Should it be static?
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied to net-next-2.6, thanks.

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

* Re: [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows an earlier one
  2009-02-18 21:49       ` [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows Hannes Eder
@ 2009-02-19  3:36         ` David Miller
  -1 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-19  3:36 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Wed, 18 Feb 2009 22:49:20 +0100

> Impact: Move variable declaration as far inner as possible.
> 
> Fix this sparse warning:
>   drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
>   drivers/net/igb/igb_main.c:1855:16: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied, thanks.

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

* Re: [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol
@ 2009-02-19  3:36         ` David Miller
  0 siblings, 0 replies; 231+ messages in thread
From: David Miller @ 2009-02-19  3:36 UTC (permalink / raw)
  To: hannes; +Cc: netdev, kernel-janitors, linux-kernel

From: Hannes Eder <hannes@hanneseder.net>
Date: Wed, 18 Feb 2009 22:49:20 +0100

> Impact: Move variable declaration as far inner as possible.
> 
> Fix this sparse warning:
>   drivers/net/igb/igb_main.c:1895:21: warning: symbol 'j' shadows an earlier one
>   drivers/net/igb/igb_main.c:1855:16: originally declared here
> 
> Signed-off-by: Hannes Eder <hannes@hanneseder.net>

Applied, thanks.

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

end of thread, other threads:[~2009-02-19  3:36 UTC | newest]

Thread overview: 231+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-14 21:11 [PATCH 00/43] drivers/net: fix (sparse) warnings Hannes Eder
2009-02-14 21:11 ` Hannes Eder
2009-02-14 21:11 ` [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:11   ` [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol Hannes Eder
2009-02-18  1:21   ` [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:21     ` [PATCH 01/43] drivers/net/at1700.c: fix sparse warning: symbol David Miller
2009-02-14 21:12 ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:12   ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows Hannes Eder
2009-02-15 14:04   ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one walter harms
2009-02-15 14:04     ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol walter harms
2009-02-15 19:57     ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-15 19:57       ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol Hannes Eder
2009-02-15 19:57       ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-16  9:58       ` walter harms
2009-02-16  9:58         ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol walter harms
2009-02-18  1:21   ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:21     ` [PATCH 02/43] drivers/net/e2100.c: fix sparse warning: symbol David Miller
2009-02-14 21:12 ` [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one Hannes Eder
2009-02-14 21:12   ` [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows Hannes Eder
2009-02-18  1:21   ` [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol shadows an earlier one David Miller
2009-02-18  1:21     ` [PATCH 03/43] drivers/net/ni65.c: fix sparse warnings: symbol David Miller
2009-02-14 21:12 ` [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:12   ` [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix Hannes Eder
2009-02-18  1:21   ` [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix signedness David Miller
2009-02-18  1:21     ` [PATCH 04/43] drivers/net/ns83820.c: fix sparse warnings: fix David Miller
2009-02-14 21:12 ` [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:12   ` [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows Hannes Eder
2009-02-18  1:21   ` [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:21     ` [PATCH 05/43] drivers/net/niu.c: fix sparse warning: symbol David Miller
2009-02-14 21:13 ` [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:13   ` Hannes Eder
2009-02-18  1:21   ` David Miller
2009-02-18  1:21     ` [PATCH 06/43] drivers/net/lance.c: fix sparse warnings: fix David Miller
2009-02-14 21:13 ` [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:13   ` Hannes Eder
2009-02-18  1:21   ` David Miller
2009-02-18  1:21     ` [PATCH 07/43] drivers/net/ni65.c: fix sparse warnings: fix David Miller
2009-02-14 21:13 ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:13   ` Hannes Eder
2009-02-14 21:29   ` Cyrill Gorcunov
2009-02-14 21:29     ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
2009-02-14 21:38     ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness Cyrill Gorcunov
2009-02-14 21:38       ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
2009-02-14 21:57       ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:57         ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Hannes Eder
2009-02-14 21:57         ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness Hannes Eder
2009-02-15  8:08         ` Cyrill Gorcunov
2009-02-15  8:08           ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix Cyrill Gorcunov
2009-02-18  1:22     ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix signedness David Miller
2009-02-18  1:22       ` [PATCH 08/43] drivers/net/ppp*.c: fix sparse warnings: fix David Miller
2009-02-14 21:14 ` [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer Hannes Eder
2009-02-14 21:14   ` [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain Hannes Eder
2009-02-15 14:00   ` [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using plain integer as NULL pointer Florian Fainelli
2009-02-15 14:00     ` Florian Fainelli
2009-02-18  1:22     ` David Miller
2009-02-18  1:22       ` [PATCH 09/43] drivers/net/r6040.c: fix sparse warning: Using David Miller
2009-02-14 21:14 ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:14   ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows Hannes Eder
2009-02-18  1:22   ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:22     ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol David Miller
2009-02-18  1:26   ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:26     ` [PATCH 10/43] drivers/net/s2io.c: fix sparse warning: symbol David Miller
2009-02-14 21:14 ` [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:14   ` [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows Hannes Eder
2009-02-18  1:26   ` [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:26     ` [PATCH 11/43] drivers/net/arcnet: fix sparse warning: symbol David Miller
2009-02-14 21:14 ` [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:14   ` Hannes Eder
2009-02-18  1:26   ` David Miller
2009-02-18  1:26     ` [PATCH 12/43] drivers/net/atl1e: fix sparse warnings: fix David Miller
2009-02-14 21:15 ` [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:15   ` Hannes Eder
2009-02-16  2:20   ` Jay Cliburn
2009-02-16  2:20     ` [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix Jay Cliburn
2009-02-18  1:26   ` [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix signedness David Miller
2009-02-18  1:26     ` [PATCH 13/43] drivers/net/atlx: fix sparse warnings: fix David Miller
2009-02-14 21:15 ` [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context imbalance Hannes Eder
2009-02-14 21:15   ` [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context Hannes Eder
2009-02-18  1:27   ` [PATCH 14/43] drivers/net/bonding: fix sparse warnings: context imbalance David Miller
2009-02-18  1:27     ` [PATCH 14/43] drivers/net/bonding: fix sparse warnings: David Miller
2009-02-14 21:15 ` [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:15   ` [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows Hannes Eder
2009-02-18  1:27   ` [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:27     ` [PATCH 15/43] drivers/net/bonding: fix sparse warning: symbol David Miller
2009-02-14 21:16 ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:16   ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows Hannes Eder
2009-02-15 14:14   ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one walter harms
2009-02-15 14:14     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows walter harms
2009-02-15 20:10     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-15 20:10       ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol Hannes Eder
2009-02-15 20:10       ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-15 21:30   ` Divy Le Ray
2009-02-15 21:30     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows Divy Le Ray
2009-02-18  1:27     ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:27       ` [PATCH 16/43] drivers/net/cxgb3: fix sparse warning: symbol David Miller
2009-02-14 21:16 ` [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:16   ` Hannes Eder
2009-02-15 21:32   ` Divy Le Ray
2009-02-15 21:32     ` Divy Le Ray
2009-02-18  1:27     ` David Miller
2009-02-18  1:27       ` [PATCH 17/43] drivers/net/cxgb3: fix sparse warnings: fix David Miller
2009-02-14 21:32 ` [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be static? Hannes Eder
2009-02-14 21:32   ` [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be Hannes Eder
2009-02-18  1:27   ` [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should it be static? David Miller
2009-02-18  1:27     ` [PATCH 18/43] drivers/net/e1000e: fix sparse warning: Should David Miller
2009-02-14 21:33 ` [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:33   ` [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string Hannes Eder
2009-02-18  1:27   ` [PATCH 19/43] drivers/net/hamradio: fix warning: format not a string literal and no David Miller
2009-02-18  1:27     ` [PATCH 19/43] drivers/net/hamradio: fix warning: format not a David Miller
2009-02-14 21:34 ` [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context imbalance Hannes Eder
2009-02-14 21:34   ` [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context Hannes Eder
2009-02-18  1:38   ` [PATCH 20/43] drivers/net/hamradio: fix sparse warning: context imbalance David Miller
2009-02-18  1:38     ` [PATCH 20/43] drivers/net/hamradio: fix sparse warning: David Miller
2009-02-14 21:35 ` [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:35   ` [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol Hannes Eder
2009-02-18  1:38   ` [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:38     ` [PATCH 21/43] drivers/net/hamradio: fix sparse warning: symbol David Miller
2009-02-14 21:36 ` [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:36   ` [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix Hannes Eder
2009-02-18  1:38   ` [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix signedness David Miller
2009-02-18  1:38     ` [PATCH 22/43] drivers/net/hamradio: fix sparse warnings: fix David Miller
2009-02-14 21:38 ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:38   ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an Hannes Eder
2009-02-18  1:39   ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:39     ` [PATCH 23/43] drivers/net/igb: fix sparse warning: symbol David Miller
2009-02-18 21:49     ` [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-18 21:49       ` [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows Hannes Eder
2009-02-19  3:36       ` [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-19  3:36         ` [PATCH 23/43 v2] drivers/net/igb: fix sparse warning: symbol David Miller
2009-02-14 21:38 ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static? Hannes Eder
2009-02-14 21:38   ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be Hannes Eder
2009-02-16  6:48   ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static? Waskiewicz Jr, Peter P
2009-02-16  6:48     ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it Waskiewicz Jr, Peter P
2009-02-18  1:39     ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it be static? David Miller
2009-02-18  1:39       ` [PATCH 24/43] drivers/net/ixgbe: fix sparse warning: Should it David Miller
2009-02-14 21:39 ` [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:39   ` [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string Hannes Eder
2009-02-18  1:39   ` [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a string literal and no David Miller
2009-02-18  1:39     ` [PATCH 25/43] drivers/net/pcmcia: fix warning: format not a David Miller
2009-02-14 21:41 ` [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:41   ` [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an Hannes Eder
2009-02-16  0:38   ` [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol shadows an earlier one Ben Hutchings
2009-02-16  0:38     ` Ben Hutchings
2009-02-18  1:39     ` David Miller
2009-02-18  1:39       ` [PATCH 26/43] drivers/net/sfc: fix sparse warning: symbol David Miller
2009-02-14 21:42 ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
2009-02-14 21:42   ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be Hannes Eder
2009-02-16  0:37   ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Ben Hutchings
2009-02-16  9:38     ` Hannes Eder
2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be Hannes Eder
2009-02-16  9:38       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? Hannes Eder
2009-02-16  9:54       ` [PATCH] " Hannes Eder
2009-02-16  9:54         ` Hannes Eder
2009-02-19  1:49         ` David Miller
2009-02-19  1:49           ` [PATCH] drivers/net/sfc: fix sparse warnings: Should it be David Miller
2009-02-18  1:39       ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it be static? David Miller
2009-02-18  1:39         ` [PATCH 27/43] drivers/net/sfc: fix sparse warnings: Should it David Miller
2009-02-14 21:43 ` [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be static? Hannes Eder
2009-02-14 21:43   ` [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be Hannes Eder
2009-02-18  1:40   ` [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it be static? David Miller
2009-02-18  1:40     ` [PATCH 28/43] drivers/net/skfp: fix sparse warning: Should it David Miller
2009-02-14 21:44 ` [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:44   ` [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string Hannes Eder
2009-02-18  1:40   ` [PATCH 29/43] drivers/net/tokenring: fix warning: format not a string literal and no David Miller
2009-02-18  1:40     ` [PATCH 29/43] drivers/net/tokenring: fix warning: format not a David Miller
2009-02-14 21:44 ` [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:44   ` [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol Hannes Eder
2009-02-18  1:41   ` [PATCH 30/43] drivers/net/tokenring: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  1:41     ` [PATCH 30/43] drivers/net/tokenring: fix sparse warning: David Miller
2009-02-14 21:46 ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
2009-02-14 21:46   ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
2009-02-14 23:24   ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Al Viro
2009-02-14 23:24     ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast Al Viro
2009-02-15 11:47     ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
2009-02-15 11:47       ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
2009-02-15 11:47       ` [PATCH 31/43] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
2009-02-15 12:13       ` [PATCH 31/43 v2] " Hannes Eder
2009-02-15 12:13         ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
2009-02-16 17:29         ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
2009-02-16 17:29           ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast Hannes Eder
2009-02-16 17:29           ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: cast truncates bits from const value Hannes Eder
2009-02-18  3:49         ` David Miller
2009-02-18  3:49           ` [PATCH 31/43 v2] drivers/net/tokenring: fix sparse warning: David Miller
2009-02-14 21:46 ` [PATCH 32/43] drivers/net/tulip: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:46   ` [PATCH 32/43] drivers/net/tulip: fix warning: format not a string Hannes Eder
2009-02-18  3:35   ` [PATCH 32/43] drivers/net/tulip: fix warning: format not a string literal and no David Miller
2009-02-18  3:35     ` [PATCH 32/43] drivers/net/tulip: fix warning: format not a David Miller
2009-02-14 21:47 ` [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:47   ` [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows Hannes Eder
2009-02-18  3:35   ` [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  3:35     ` [PATCH 33/43] drivers/net/tulip: fix sparse warning: symbol David Miller
2009-02-14 21:47 ` [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be static? Hannes Eder
2009-02-14 21:47   ` [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be Hannes Eder
2009-02-18  3:35   ` [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it be static? David Miller
2009-02-18  3:35     ` [PATCH 34/43] drivers/net/usb: fix sparse warnings: Should it David Miller
2009-02-14 21:48 ` [PATCH 35/43] drivers/net/wan: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:48   ` [PATCH 35/43] drivers/net/wan: fix warning: format not a string Hannes Eder
2009-02-18  3:35   ` [PATCH 35/43] drivers/net/wan: fix warning: format not a string literal and no David Miller
2009-02-18  3:35     ` [PATCH 35/43] drivers/net/wan: fix warning: format not a David Miller
2009-02-14 21:48 ` [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an earlier one Hannes Eder
2009-02-14 21:48   ` [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an Hannes Eder
2009-02-18  3:35   ` [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol shadows an earlier one David Miller
2009-02-18  3:35     ` [PATCH 36/43] drivers/net/wan: fix sparse warning: symbol David Miller
2009-02-14 21:48 ` [PATCH 37/43] drivers/net/wireless: fix sparse warning: context imbalance Hannes Eder
2009-02-14 21:48   ` [PATCH 37/43] drivers/net/wireless: fix sparse warning: context Hannes Eder
2009-02-18  3:35   ` [PATCH 37/43] drivers/net/wireless: fix sparse warning: context imbalance David Miller
2009-02-18  3:35     ` [PATCH 37/43] drivers/net/wireless: fix sparse warning: David Miller
2009-02-14 21:49 ` [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one Hannes Eder
2009-02-14 21:49   ` [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol Hannes Eder
2009-02-18  3:35   ` [PATCH 38/43] drivers/net/wireless: fix sparse warnings: symbol shadows an earlier one David Miller
2009-02-18  3:35     ` [PATCH 38/43] drivers/net/wireless: fix sparse warnings: David Miller
2009-02-14 21:49 ` [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:49   ` [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix Hannes Eder
2009-02-18  3:35   ` [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix signedness David Miller
2009-02-18  3:35     ` [PATCH 39/43] drivers/net/wireless: fix sparse warnings: fix David Miller
2009-02-14 21:49 ` [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should it be static? Hannes Eder
2009-02-14 21:49   ` [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should Hannes Eder
2009-02-18  3:35   ` [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: Should it be static? David Miller
2009-02-18  3:35     ` [PATCH 40/43] drivers/net/wireless/ath9k: fix sparse warnings: David Miller
2009-02-14 21:50 ` [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a string literal and no Hannes Eder
2009-02-14 21:50   ` [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a Hannes Eder
2009-02-18  3:49   ` [PATCH 41/43] drivers/net/wireless/b43: fix warning: format not a string literal and no David Miller
2009-02-18  3:49     ` [PATCH 41/43] drivers/net/wireless/b43: fix warning: format David Miller
2009-02-14 21:50 ` [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness Hannes Eder
2009-02-14 21:50   ` [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix Hannes Eder
2009-02-18  3:49   ` [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse warnings: fix signedness David Miller
2009-02-18  3:49     ` [PATCH 42/43] drivers/net/wireless/ipw2x00: fix sparse David Miller
2009-02-14 21:50 ` [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix signedness Hannes Eder
2009-02-14 21:50   ` [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix Hannes Eder
2009-02-18  3:49   ` [PATCH 43/43] drivers/net/wireless/prism54: fix sparse warning: fix signedness David Miller
2009-02-18  3:49     ` [PATCH 43/43] drivers/net/wireless/prism54: fix sparse David Miller

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.