netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2.6.9-rc2 12/12] S2io: styling
@ 2004-10-28 18:34 Ravinandan Arakali
  0 siblings, 0 replies; 8+ messages in thread
From: Ravinandan Arakali @ 2004-10-28 18:34 UTC (permalink / raw)
  To: 'Jeff Garzik', 'Francois Romieu'
  Cc: netdev, leonid.grossman, raghavendra.koushik, rapuru.sriram,
	alicia.pena

Hi,
Attached is the patch to implement comments about styling
and few other changes.
Following is list of changes.
1. Incorporated Randy's comment about C99 format for s2io_driver
   structure initialization.
2. Driver version displayed at load time.
3. If initialization failed in s2io_init_nic(), appropriate error
   codes are returned.
4. #ifdef SET_ETHTOOL_OPS removed in couple of places.

Signed-off-by: Raghavendra Koushik <raghavendra.koushik@s2io.com>
---
diff -urN vanilla-linux/drivers/net/s2io.c linux-2.6.8.1/drivers/net/s2io.c
--- vanilla-linux/drivers/net/s2io.c	2004-10-26 16:45:59.090250752 -0700
+++ linux-2.6.8.1/drivers/net/s2io.c	2004-10-26 16:45:47.840960904 -0700
@@ -250,10 +250,10 @@
 MODULE_DEVICE_TABLE(pci, s2io_tbl);
 
 static struct pci_driver s2io_driver = {
-      name:"S2IO",
-      id_table:s2io_tbl,
-      probe:s2io_init_nic,
-      remove:__devexit_p(s2io_rem_nic),
+      .name = "S2IO",
+      .id_table = s2io_tbl,
+      .probe = s2io_init_nic,
+      .remove = __devexit_p(s2io_rem_nic),
 };
 
 /* A simplifier macro used both by init and free shared_mem Fns(). */
@@ -4603,6 +4603,9 @@
 	struct config_param *config;
 
 
+	DBG_PRINT(ERR_DBG, "Loading S2IO driver with %s\n",
+		s2io_driver_version);
+
 	if ((ret = pci_enable_device(pdev))) {
 		DBG_PRINT(ERR_DBG,
 			  "s2io_init_nic: pci_enable_device failed\n");
@@ -4720,6 +4723,7 @@
 	if (init_shared_mem(sp)) {
 		DBG_PRINT(ERR_DBG, "%s: Memory allocation failed\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto mem_alloc_failed;
 	}
 
@@ -4728,6 +4732,7 @@
 	if (!sp->bar0) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem1\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar0_remap_failed;
 	}
 
@@ -4736,6 +4741,7 @@
 	if (!sp->bar1) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem2\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar1_remap_failed;
 	}
 
@@ -4756,9 +4762,7 @@
 	dev->set_multicast_list = &s2io_set_multicast;
 	dev->do_ioctl = &s2io_ioctl;
 	dev->change_mtu = &s2io_change_mtu;
-#ifdef SET_ETHTOOL_OPS
 	SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops);
-#endif
 	/*
 	 * will use eth_mac_addr() for  dev->set_mac_address
 	 * mac address will be set every time dev->open() is called
@@ -4788,6 +4792,7 @@
 	if (s2io_set_swapper(sp)) {
 		DBG_PRINT(ERR_DBG, "%s:swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4802,6 +4807,7 @@
 		DBG_PRINT(ERR_DBG,
 			  "%s: S2IO: swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4874,6 +4880,7 @@
 
 	if (register_netdev(dev)) {
 		DBG_PRINT(ERR_DBG, "Device registration failed\n");
+		ret = -ENODEV;
 		goto register_failed;
 	}
 
@@ -4900,7 +4907,7 @@
 	pci_set_drvdata(pdev, NULL);
 	free_netdev(dev);
 
-	return -ENODEV;
+	return ret;
 }
 
 /**
diff -urN vanilla-linux/drivers/net/s2io.h linux-2.6.8.1/drivers/net/s2io.h
--- vanilla-linux/drivers/net/s2io.h	2004-10-26 16:45:59.329214424 -0700
+++ linux-2.6.8.1/drivers/net/s2io.h	2004-10-26 16:45:48.079924576 -0700
@@ -50,10 +50,6 @@
 #define ALIGN_SIZE  			127
 #define	PCIX_COMMAND_REGISTER	0x62
 
-#ifndef SET_ETHTOOL_OPS
-#define SUPPORTED_10000baseT_Full (1 << 12)
-#endif
-
 /*
  * Debug related variables.
  */
@@ -873,9 +869,7 @@
 int s2io_set_mac_addr(struct net_device *dev, u8 * addr);
 static irqreturn_t s2io_isr(int irq, void *dev_id, struct pt_regs *regs);
 static int verify_xena_quiescence(u64 val64, int flag);
-#ifdef SET_ETHTOOL_OPS
 static struct ethtool_ops netdev_ethtool_ops;
-#endif
 static void s2io_set_link(unsigned long data);
 static void s2io_card_down(nic_t * nic);
 static int s2io_card_up(nic_t * nic);

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

* [PATCH 2.6.9-rc2 12/12] S2io: styling
@ 2004-10-28 22:51 Ravinandan Arakali
  0 siblings, 0 replies; 8+ messages in thread
From: Ravinandan Arakali @ 2004-10-28 22:51 UTC (permalink / raw)
  To: 'Jeff Garzik', 'Francois Romieu'
  Cc: netdev, leonid.grossman, raghavendra.koushik, rapuru.sriram,
	alicia.pena

Hi,
Attached is the patch to implement comments about styling
and few other changes.
Following is list of changes.
1. Incorporated Randy's comment about C99 format for s2io_driver
   structure initialization.
2. Driver version displayed at load time.
3. If initialization failed in s2io_init_nic(), appropriate error
   codes are returned.
4. #ifdef SET_ETHTOOL_OPS removed in couple of places.

Signed-off-by: Raghavendra Koushik <raghavendra.koushik@s2io.com>
Signed-off-by: Ravinandan Arakali <ravinandan.arakali@s2io.com>
---
diff -urN vanilla-linux/drivers/net/s2io.c linux-2.6.8.1/drivers/net/s2io.c
--- vanilla-linux/drivers/net/s2io.c	2004-10-26 16:45:59.090250752 -0700
+++ linux-2.6.8.1/drivers/net/s2io.c	2004-10-26 16:45:47.840960904 -0700
@@ -250,10 +250,10 @@
 MODULE_DEVICE_TABLE(pci, s2io_tbl);
 
 static struct pci_driver s2io_driver = {
-      name:"S2IO",
-      id_table:s2io_tbl,
-      probe:s2io_init_nic,
-      remove:__devexit_p(s2io_rem_nic),
+      .name = "S2IO",
+      .id_table = s2io_tbl,
+      .probe = s2io_init_nic,
+      .remove = __devexit_p(s2io_rem_nic),
 };
 
 /* A simplifier macro used both by init and free shared_mem Fns(). */
@@ -4603,6 +4603,9 @@
 	struct config_param *config;
 
 
+	DBG_PRINT(ERR_DBG, "Loading S2IO driver with %s\n",
+		s2io_driver_version);
+
 	if ((ret = pci_enable_device(pdev))) {
 		DBG_PRINT(ERR_DBG,
 			  "s2io_init_nic: pci_enable_device failed\n");
@@ -4720,6 +4723,7 @@
 	if (init_shared_mem(sp)) {
 		DBG_PRINT(ERR_DBG, "%s: Memory allocation failed\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto mem_alloc_failed;
 	}
 
@@ -4728,6 +4732,7 @@
 	if (!sp->bar0) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem1\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar0_remap_failed;
 	}
 
@@ -4736,6 +4741,7 @@
 	if (!sp->bar1) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem2\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar1_remap_failed;
 	}
 
@@ -4756,9 +4762,7 @@
 	dev->set_multicast_list = &s2io_set_multicast;
 	dev->do_ioctl = &s2io_ioctl;
 	dev->change_mtu = &s2io_change_mtu;
-#ifdef SET_ETHTOOL_OPS
 	SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops);
-#endif
 	/*
 	 * will use eth_mac_addr() for  dev->set_mac_address
 	 * mac address will be set every time dev->open() is called
@@ -4788,6 +4792,7 @@
 	if (s2io_set_swapper(sp)) {
 		DBG_PRINT(ERR_DBG, "%s:swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4802,6 +4807,7 @@
 		DBG_PRINT(ERR_DBG,
 			  "%s: S2IO: swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4874,6 +4880,7 @@
 
 	if (register_netdev(dev)) {
 		DBG_PRINT(ERR_DBG, "Device registration failed\n");
+		ret = -ENODEV;
 		goto register_failed;
 	}
 
@@ -4900,7 +4907,7 @@
 	pci_set_drvdata(pdev, NULL);
 	free_netdev(dev);
 
-	return -ENODEV;
+	return ret;
 }
 
 /**
diff -urN vanilla-linux/drivers/net/s2io.h linux-2.6.8.1/drivers/net/s2io.h
--- vanilla-linux/drivers/net/s2io.h	2004-10-26 16:45:59.329214424 -0700
+++ linux-2.6.8.1/drivers/net/s2io.h	2004-10-26 16:45:48.079924576 -0700
@@ -50,10 +50,6 @@
 #define ALIGN_SIZE  			127
 #define	PCIX_COMMAND_REGISTER	0x62
 
-#ifndef SET_ETHTOOL_OPS
-#define SUPPORTED_10000baseT_Full (1 << 12)
-#endif
-
 /*
  * Debug related variables.
  */
@@ -873,9 +869,7 @@
 int s2io_set_mac_addr(struct net_device *dev, u8 * addr);
 static irqreturn_t s2io_isr(int irq, void *dev_id, struct pt_regs *regs);
 static int verify_xena_quiescence(u64 val64, int flag);
-#ifdef SET_ETHTOOL_OPS
 static struct ethtool_ops netdev_ethtool_ops;
-#endif
 static void s2io_set_link(unsigned long data);
 static void s2io_card_down(nic_t * nic);
 static int s2io_card_up(nic_t * nic);

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

* [PATCH 2.6.9-rc2 12/12] S2io: styling
@ 2004-11-08 16:18 raghavendra.koushik
  2004-11-09  4:22 ` Jeff Garzik
  0 siblings, 1 reply; 8+ messages in thread
From: raghavendra.koushik @ 2004-11-08 16:18 UTC (permalink / raw)
  To: jgarzik, romieu, netdev; +Cc: ravinandan.arakali, raghavendra.koushik

Hi,
Attached is the patch to implement comments about styling
and few other changes.
Following is list of changes.
1. Incorporated Randy's comment about C99 format for s2io_driver
   structure initialization.
2. Driver version displayed at load time.
3. If initialization failed in s2io_init_nic(), appropriate error
   codes are returned.
4. #ifdef SET_ETHTOOL_OPS removed in couple of places.

Signed-off-by: Raghavendra Koushik <raghavendra.koushik@s2io.com>
Signed-off-by: Ravinandan Arakali <ravinandan.arakali@s2io.com>
---
diff -urN vanilla-linux/drivers/net/s2io.c linux-2.6.8.1/drivers/net/s2io.c
--- vanilla-linux/drivers/net/s2io.c	2004-10-26 16:45:59.090250752 -0700
+++ linux-2.6.8.1/drivers/net/s2io.c	2004-10-26 16:45:47.840960904 -0700
@@ -250,10 +250,10 @@
 MODULE_DEVICE_TABLE(pci, s2io_tbl);
 
 static struct pci_driver s2io_driver = {
-      name:"S2IO",
-      id_table:s2io_tbl,
-      probe:s2io_init_nic,
-      remove:__devexit_p(s2io_rem_nic),
+      .name = "S2IO",
+      .id_table = s2io_tbl,
+      .probe = s2io_init_nic,
+      .remove = __devexit_p(s2io_rem_nic),
 };
 
 /* A simplifier macro used both by init and free shared_mem Fns(). */
@@ -4603,6 +4603,9 @@
 	struct config_param *config;
 
 
+	DBG_PRINT(ERR_DBG, "Loading S2IO driver with %s\n",
+		s2io_driver_version);
+
 	if ((ret = pci_enable_device(pdev))) {
 		DBG_PRINT(ERR_DBG,
 			  "s2io_init_nic: pci_enable_device failed\n");
@@ -4720,6 +4723,7 @@
 	if (init_shared_mem(sp)) {
 		DBG_PRINT(ERR_DBG, "%s: Memory allocation failed\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto mem_alloc_failed;
 	}
 
@@ -4728,6 +4732,7 @@
 	if (!sp->bar0) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem1\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar0_remap_failed;
 	}
 
@@ -4736,6 +4741,7 @@
 	if (!sp->bar1) {
 		DBG_PRINT(ERR_DBG, "%s: S2IO: cannot remap io mem2\n",
 			  dev->name);
+		ret = -ENOMEM;
 		goto bar1_remap_failed;
 	}
 
@@ -4756,9 +4762,7 @@
 	dev->set_multicast_list = &s2io_set_multicast;
 	dev->do_ioctl = &s2io_ioctl;
 	dev->change_mtu = &s2io_change_mtu;
-#ifdef SET_ETHTOOL_OPS
 	SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops);
-#endif
 	/*
 	 * will use eth_mac_addr() for  dev->set_mac_address
 	 * mac address will be set every time dev->open() is called
@@ -4788,6 +4792,7 @@
 	if (s2io_set_swapper(sp)) {
 		DBG_PRINT(ERR_DBG, "%s:swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4802,6 +4807,7 @@
 		DBG_PRINT(ERR_DBG,
 			  "%s: S2IO: swapper settings are wrong\n",
 			  dev->name);
+		ret = -EAGAIN;
 		goto set_swap_failed;
 	}
 
@@ -4874,6 +4880,7 @@
 
 	if (register_netdev(dev)) {
 		DBG_PRINT(ERR_DBG, "Device registration failed\n");
+		ret = -ENODEV;
 		goto register_failed;
 	}
 
@@ -4900,7 +4907,7 @@
 	pci_set_drvdata(pdev, NULL);
 	free_netdev(dev);
 
-	return -ENODEV;
+	return ret;
 }
 
 /**
diff -urN vanilla-linux/drivers/net/s2io.h linux-2.6.8.1/drivers/net/s2io.h
--- vanilla-linux/drivers/net/s2io.h	2004-10-26 16:45:59.329214424 -0700
+++ linux-2.6.8.1/drivers/net/s2io.h	2004-10-26 16:45:48.079924576 -0700
@@ -50,10 +50,6 @@
 #define ALIGN_SIZE  			127
 #define	PCIX_COMMAND_REGISTER	0x62
 
-#ifndef SET_ETHTOOL_OPS
-#define SUPPORTED_10000baseT_Full (1 << 12)
-#endif
-
 /*
  * Debug related variables.
  */
@@ -873,9 +869,7 @@
 int s2io_set_mac_addr(struct net_device *dev, u8 * addr);
 static irqreturn_t s2io_isr(int irq, void *dev_id, struct pt_regs *regs);
 static int verify_xena_quiescence(u64 val64, int flag);
-#ifdef SET_ETHTOOL_OPS
 static struct ethtool_ops netdev_ethtool_ops;
-#endif
 static void s2io_set_link(unsigned long data);
 static void s2io_card_down(nic_t * nic);
 static int s2io_card_up(nic_t * nic);

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

* Re: [PATCH 2.6.9-rc2 12/12] S2io: styling
  2004-11-08 16:18 [PATCH 2.6.9-rc2 12/12] S2io: styling raghavendra.koushik
@ 2004-11-09  4:22 ` Jeff Garzik
  2004-11-15 20:21   ` Ravinandan Arakali
  0 siblings, 1 reply; 8+ messages in thread
From: Jeff Garzik @ 2004-11-09  4:22 UTC (permalink / raw)
  To: raghavendra.koushik; +Cc: romieu, netdev, ravinandan.arakali

It is my pleasure to report that I successfully applied all 12 patches 
from the most recent batch sent, to the netdev-2.6 queue.

	Jeff

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

* RE: [PATCH 2.6.9-rc2 12/12] S2io: styling
  2004-11-09  4:22 ` Jeff Garzik
@ 2004-11-15 20:21   ` Ravinandan Arakali
  2004-11-15 22:34     ` Jeff Garzik
  0 siblings, 1 reply; 8+ messages in thread
From: Ravinandan Arakali @ 2004-11-15 20:21 UTC (permalink / raw)
  To: 'Jeff Garzik', raghavendra.koushik
  Cc: romieu, netdev, leonid.grossman

Jeff,
We received couple of comments from Krishna Kumar. Other than that
we are waiting for further comments. If there are no other, we can
submit one final patch to address Krishna Kumar's comments.

In one of your earlier mails(on 10/28), you mentioned "patches pass 
review".
Pls let us know.

Thanks,
Ravi

-----Original Message-----
From: Jeff Garzik [mailto:jgarzik@pobox.com]
Sent: Monday, November 08, 2004 8:23 PM
To: raghavendra.koushik@s2io.com
Cc: romieu@fr.zoreil.com; netdev@oss.sgi.com;
ravinandan.arakali@s2io.com
Subject: Re: [PATCH 2.6.9-rc2 12/12] S2io: styling


It is my pleasure to report that I successfully applied all 12 patches 
from the most recent batch sent, to the netdev-2.6 queue.

	Jeff

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

* Re: [PATCH 2.6.9-rc2 12/12] S2io: styling
  2004-11-15 20:21   ` Ravinandan Arakali
@ 2004-11-15 22:34     ` Jeff Garzik
  2004-11-15 23:51       ` Ravinandan Arakali
  0 siblings, 1 reply; 8+ messages in thread
From: Jeff Garzik @ 2004-11-15 22:34 UTC (permalink / raw)
  To: ravinandan.arakali; +Cc: raghavendra.koushik, romieu, netdev, leonid.grossman

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

Ravinandan Arakali wrote:
> Jeff,
> We received couple of comments from Krishna Kumar. Other than that
> we are waiting for further comments. If there are no other, we can
> submit one final patch to address Krishna Kumar's comments.
> 
> In one of your earlier mails(on 10/28), you mentioned "patches pass 
> review".
> Pls let us know.

See attached for the list of patches I've applied.

If I am missing any, please let me know.

	Jeff



[-- Attachment #2: linus.txt --]
[-- Type: text/plain, Size: 734 bytes --]

Please do a

	bk pull bk://gkernel.bkbits.net/s2io

This will update the following files:

 drivers/net/Kconfig     |   11 
 drivers/net/s2io-regs.h |    3 
 drivers/net/s2io.c      | 3114 ++++++++++++++++++++++++++++--------------------
 drivers/net/s2io.h      |  295 ++--
 4 files changed, 2018 insertions(+), 1405 deletions(-)

through these ChangeSets:

<raghavendra.koushik:s2io.com>:
  o S2io: styling
  o S2io: modified loadable parameters
  o S2io: 2 buffer mode with copy
  o S2io: new functions for card restart
  o S2io: two buffer mode
  o S2io: NAPI fix
  o S2io: new txd allocation
  o S2io: module loadable parameters
  o S2io: hardware fixes
  o S2io: optimizations
  o S2io: sw bug fixes
  o S2io: cosmetic changes


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

* RE: [PATCH 2.6.9-rc2 12/12] S2io: styling
  2004-11-15 22:34     ` Jeff Garzik
@ 2004-11-15 23:51       ` Ravinandan Arakali
  2004-11-16  0:38         ` Jeff Garzik
  0 siblings, 1 reply; 8+ messages in thread
From: Ravinandan Arakali @ 2004-11-15 23:51 UTC (permalink / raw)
  To: 'Jeff Garzik'
  Cc: raghavendra.koushik, romieu, netdev, leonid.grossman

Jeff,
You have not missed any of the patches.
I guess the changes will appear in a future release since I don't
see it yet in 2.6.10rc2.
We will send one more patch to address Krishna Kumar's comments.

Thanks,
Ravi

-----Original Message-----
From: Jeff Garzik [mailto:jgarzik@pobox.com]
Sent: Monday, November 15, 2004 2:34 PM
To: ravinandan.arakali@s2io.com
Cc: raghavendra.koushik@s2io.com; romieu@fr.zoreil.com;
netdev@oss.sgi.com; leonid.grossman@s2io.com
Subject: Re: [PATCH 2.6.9-rc2 12/12] S2io: styling


Ravinandan Arakali wrote:
> Jeff,
> We received couple of comments from Krishna Kumar. Other than that
> we are waiting for further comments. If there are no other, we can
> submit one final patch to address Krishna Kumar's comments.
> 
> In one of your earlier mails(on 10/28), you mentioned "patches pass 
> review".
> Pls let us know.

See attached for the list of patches I've applied.

If I am missing any, please let me know.

	Jeff

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

* Re: [PATCH 2.6.9-rc2 12/12] S2io: styling
  2004-11-15 23:51       ` Ravinandan Arakali
@ 2004-11-16  0:38         ` Jeff Garzik
  0 siblings, 0 replies; 8+ messages in thread
From: Jeff Garzik @ 2004-11-16  0:38 UTC (permalink / raw)
  To: ravinandan.arakali; +Cc: raghavendra.koushik, romieu, netdev, leonid.grossman

Ravinandan Arakali wrote:
> Jeff,
> You have not missed any of the patches.
> I guess the changes will appear in a future release since I don't
> see it yet in 2.6.10rc2.
> We will send one more patch to address Krishna Kumar's comments.

Correct, the patches came too late for 2.6.10, but will go upstream as 
soon as it is released.

	Jeff

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

end of thread, other threads:[~2004-11-16  0:38 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-08 16:18 [PATCH 2.6.9-rc2 12/12] S2io: styling raghavendra.koushik
2004-11-09  4:22 ` Jeff Garzik
2004-11-15 20:21   ` Ravinandan Arakali
2004-11-15 22:34     ` Jeff Garzik
2004-11-15 23:51       ` Ravinandan Arakali
2004-11-16  0:38         ` Jeff Garzik
  -- strict thread matches above, loose matches on Subject: below --
2004-10-28 22:51 Ravinandan Arakali
2004-10-28 18:34 Ravinandan Arakali

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).