netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* RFC: igb: Intel 82575 gigabit ethernet driver (take #3)
@ 2008-01-10 23:32 Kok, Auke
  2008-01-11  0:01 ` Jeff Garzik
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Kok, Auke @ 2008-01-10 23:32 UTC (permalink / raw)
  To: NetDev, Jeff Garzik
  Cc: Arjan van de Ven, Jesse Brandeburg, Ronciak, John, Andrew Morton

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


All,

here is the third version of the igb (82575) ethernet controller driver. This
driver was previously posted 2007-07-13 and 2007-12-11. Many comments received
were addressed:

- removed indirection wrappers in the same way as e1000e and ixgbe.
- cleaned up largely against sparse, checkpatch
- removed module parameters and moved functionality to ethtool ioctls
- new NAPI API rewrites
- by default the driver runs in multiqueue mode with 2 to 40 RX queues enabled.

and specifically in this version:

- register macro's were condensed for readability
- fixed namespace collisions by renaming functions to igb_*

Since the driver is still too large (allthough the patch shrunk from 558k to 416k
to 407k, almost 38% of its size) to post to this list I am attaching the bzipped
patch here. You can get the same driver alternatively from here:

http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch
[407k]
http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch.bz2
[74k]

or through git:
    git://lost.foo-projects.org/~ahkok/git/linux-2.6 #igb


There are several concerns still open for this driver:
- hardware code is still a large API. we're expecting more hardware to be
supported by this driver in the future. The API has already been scrubbed but we
anticipate that the remaining hooks will be used in the future.
- The register defines are still named "E1000_" as they are mostly identical to
the e1000 chipsets (igb register space is a superset of most recent e1000 register
sets).


Please review,


Cheers,

Auke

---

>From 4ec9e52f44de0c1c41265c5f326b573643f24da7 Mon Sep 17 00:00:00 2001
From: Auke Kok <auke-jan.h.kok@intel.com>
Date: Thu, 10 Jan 2008 14:55:46 -0800
Subject: [PATCH] igb: PCI-Express 82575 Gigabit Ethernet driver

We are pleased to announce a new Gigabit Ethernet product and its
driver to the linux community. This product is the Intel(R) 82575
Gigabit Ethernet adapter family. Physical adapters will be available
to the public soon. These adapters come in 2- and 4-port versions
(copper PHY) currently. Other variants will be available later.

The 82575 chipset supports significantly different features that
warrant a new driver. The descriptor format is (just like the
ixgbe driver) different. The device can use multiple MSI-X vectors
and multiple queues for both send and receive. This allows us to
optimize some of the driver code specifically as well compared to
the e1000-supported devices.

This version of the igb driver no lnger uses fake netdevices and
incorporates napi_struct members for each ring to do the multi-
queue polling. multi-queue is enabled by default and the driver
supports NAPI mode only.

All the namespace collisions should be gone in this version too. The
register macro's have been condensed to improve readability.

Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
---
 drivers/net/Kconfig             |   22 +
 drivers/net/Makefile            |    1 +
 drivers/net/igb/Makefile        |   37 +
 drivers/net/igb/e1000_82575.c   | 1269 ++++++++++++
 drivers/net/igb/e1000_82575.h   |  150 ++
 drivers/net/igb/e1000_defines.h |  772 ++++++++
 drivers/net/igb/e1000_hw.h      |  599 ++++++
 drivers/net/igb/e1000_mac.c     | 1505 ++++++++++++++
 drivers/net/igb/e1000_mac.h     |   98 +
 drivers/net/igb/e1000_nvm.c     |  605 ++++++
 drivers/net/igb/e1000_nvm.h     |   40 +
 drivers/net/igb/e1000_phy.c     | 1807 +++++++++++++++++
 drivers/net/igb/e1000_phy.h     |   98 +
 drivers/net/igb/e1000_regs.h    |  270 +++
 drivers/net/igb/igb.h           |  300 +++
 drivers/net/igb/igb_ethtool.c   | 1927 ++++++++++++++++++
 drivers/net/igb/igb_main.c      | 4138 +++++++++++++++++++++++++++++++++++++++
 17 files changed, 13638 insertions(+), 0 deletions(-)
 create mode 100644 drivers/net/igb/Makefile
 create mode 100644 drivers/net/igb/e1000_82575.c
 create mode 100644 drivers/net/igb/e1000_82575.h
 create mode 100644 drivers/net/igb/e1000_defines.h
 create mode 100644 drivers/net/igb/e1000_hw.h
 create mode 100644 drivers/net/igb/e1000_mac.c
 create mode 100644 drivers/net/igb/e1000_mac.h
 create mode 100644 drivers/net/igb/e1000_nvm.c
 create mode 100644 drivers/net/igb/e1000_nvm.h
 create mode 100644 drivers/net/igb/e1000_phy.c
 create mode 100644 drivers/net/igb/e1000_phy.h
 create mode 100644 drivers/net/igb/e1000_regs.h
 create mode 100644 drivers/net/igb/igb.h
 create mode 100644 drivers/net/igb/igb_ethtool.c
 create mode 100644 drivers/net/igb/igb_main.c



[-- Attachment #2: 0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch.bz2 --]
[-- Type: application/x-bzip2, Size: 75975 bytes --]

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

* Re: RFC: igb: Intel 82575 gigabit ethernet driver (take #3)
  2008-01-10 23:32 RFC: igb: Intel 82575 gigabit ethernet driver (take #3) Kok, Auke
@ 2008-01-11  0:01 ` Jeff Garzik
  2008-01-11  0:22   ` Kok, Auke
  2008-01-11  9:17 ` Christoph Hellwig
  2008-01-22 10:05 ` Jeff Garzik
  2 siblings, 1 reply; 5+ messages in thread
From: Jeff Garzik @ 2008-01-11  0:01 UTC (permalink / raw)
  To: Kok, Auke
  Cc: NetDev, Arjan van de Ven, Jesse Brandeburg, Ronciak, John,
	Andrew Morton

Kok, Auke wrote:
> All,
> 
> here is the third version of the igb (82575) ethernet controller driver. This
> driver was previously posted 2007-07-13 and 2007-12-11. Many comments received
> were addressed:
> 
> - removed indirection wrappers in the same way as e1000e and ixgbe.
> - cleaned up largely against sparse, checkpatch
> - removed module parameters and moved functionality to ethtool ioctls
> - new NAPI API rewrites
> - by default the driver runs in multiqueue mode with 2 to 40 RX queues enabled.
> 
> and specifically in this version:
> 
> - register macro's were condensed for readability
> - fixed namespace collisions by renaming functions to igb_*
> 
> Since the driver is still too large (allthough the patch shrunk from 558k to 416k
> to 407k, almost 38% of its size) to post to this list I am attaching the bzipped
> patch here. You can get the same driver alternatively from here:
> 
> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch
> [407k]
> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch.bz2
> [74k]
> 
> or through git:
>     git://lost.foo-projects.org/~ahkok/git/linux-2.6 #igb
> 
> 
> There are several concerns still open for this driver:
> - hardware code is still a large API. we're expecting more hardware to be
> supported by this driver in the future. The API has already been scrubbed but we
> anticipate that the remaining hooks will be used in the future.
> - The register defines are still named "E1000_" as they are mostly identical to
> the e1000 chipsets (igb register space is a superset of most recent e1000 register
> sets).

I think we can throw it into netdev#upstream if you're ready...

	Jeff





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

* Re: RFC: igb: Intel 82575 gigabit ethernet driver (take #3)
  2008-01-11  0:01 ` Jeff Garzik
@ 2008-01-11  0:22   ` Kok, Auke
  0 siblings, 0 replies; 5+ messages in thread
From: Kok, Auke @ 2008-01-11  0:22 UTC (permalink / raw)
  To: Jeff Garzik
  Cc: NetDev, Arjan van de Ven, Jesse Brandeburg, Ronciak, John,
	Andrew Morton

Jeff Garzik wrote:
> Kok, Auke wrote:
>> All,
>>
>> here is the third version of the igb (82575) ethernet controller
>> driver. This
>> driver was previously posted 2007-07-13 and 2007-12-11. Many comments
>> received
>> were addressed:
>>
>> - removed indirection wrappers in the same way as e1000e and ixgbe.
>> - cleaned up largely against sparse, checkpatch
>> - removed module parameters and moved functionality to ethtool ioctls
>> - new NAPI API rewrites
>> - by default the driver runs in multiqueue mode with 2 to 40 RX queues
>> enabled.
>>
>> and specifically in this version:
>>
>> - register macro's were condensed for readability
>> - fixed namespace collisions by renaming functions to igb_*
>>
>> Since the driver is still too large (allthough the patch shrunk from
>> 558k to 416k
>> to 407k, almost 38% of its size) to post to this list I am attaching
>> the bzipped
>> patch here. You can get the same driver alternatively from here:
>>
>> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch
>>
>> [407k]
>> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch.bz2
>>
>> [74k]
>>
>> or through git:
>>     git://lost.foo-projects.org/~ahkok/git/linux-2.6 #igb
>>
>>
>> There are several concerns still open for this driver:
>> - hardware code is still a large API. we're expecting more hardware to be
>> supported by this driver in the future. The API has already been
>> scrubbed but we
>> anticipate that the remaining hooks will be used in the future.
>> - The register defines are still named "E1000_" as they are mostly
>> identical to
>> the e1000 chipsets (igb register space is a superset of most recent
>> e1000 register
>> sets).
> 
> I think we can throw it into netdev#upstream if you're ready...

yes, of course :)

both the patch file and the git tree should work for you.


Cheers,

Auke

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

* Re: RFC: igb: Intel 82575 gigabit ethernet driver (take #3)
  2008-01-10 23:32 RFC: igb: Intel 82575 gigabit ethernet driver (take #3) Kok, Auke
  2008-01-11  0:01 ` Jeff Garzik
@ 2008-01-11  9:17 ` Christoph Hellwig
  2008-01-22 10:05 ` Jeff Garzik
  2 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2008-01-11  9:17 UTC (permalink / raw)
  To: Kok, Auke
  Cc: NetDev, Jeff Garzik, Arjan van de Ven, Jesse Brandeburg,
	Ronciak, John, Andrew Morton

On Thu, Jan 10, 2008 at 03:32:28PM -0800, Kok, Auke wrote:
> - cleaned up largely against sparse, checkpatch

largely means not completely, right?  Please make sure there's no sparse
warnings left at least.  checkpatch is not that criticial, but it would
be good to have an explanation for everything left.


some comments on the patch

 - please remove that sill copyright heder on the Makefile, it's hard
   to claim any rights on a trivial 3 line makefile.
 - also please use igb-y instead of igb-objs in the Makefile
 - the driver would be a lot more readable (and more importantly
   hackable) if it was written in a natural flow instead of having dozends 
   of lines of forward declarations in every file.
 - so you're adding your own phy abstraction.  Is there a good reason
   you can't simply use the generic phylib?

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

* Re: RFC: igb: Intel 82575 gigabit ethernet driver (take #3)
  2008-01-10 23:32 RFC: igb: Intel 82575 gigabit ethernet driver (take #3) Kok, Auke
  2008-01-11  0:01 ` Jeff Garzik
  2008-01-11  9:17 ` Christoph Hellwig
@ 2008-01-22 10:05 ` Jeff Garzik
  2 siblings, 0 replies; 5+ messages in thread
From: Jeff Garzik @ 2008-01-22 10:05 UTC (permalink / raw)
  To: Kok, Auke
  Cc: NetDev, Arjan van de Ven, Jesse Brandeburg, Ronciak, John,
	Andrew Morton

Kok, Auke wrote:
> All,
> 
> here is the third version of the igb (82575) ethernet controller driver. This
> driver was previously posted 2007-07-13 and 2007-12-11. Many comments received
> were addressed:
> 
> - removed indirection wrappers in the same way as e1000e and ixgbe.
> - cleaned up largely against sparse, checkpatch
> - removed module parameters and moved functionality to ethtool ioctls
> - new NAPI API rewrites
> - by default the driver runs in multiqueue mode with 2 to 40 RX queues enabled.
> 
> and specifically in this version:
> 
> - register macro's were condensed for readability
> - fixed namespace collisions by renaming functions to igb_*
> 
> Since the driver is still too large (allthough the patch shrunk from 558k to 416k
> to 407k, almost 38% of its size) to post to this list I am attaching the bzipped
> patch here. You can get the same driver alternatively from here:
> 
> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch
> [407k]
> http://foo-projects.org/~sofar/0001-igb-PCI-Express-82575-Gigabit-Ethernet-driver.patch.bz2
> [74k]
> 
> or through git:
>     git://lost.foo-projects.org/~ahkok/git/linux-2.6 #igb
> 
> 
> There are several concerns still open for this driver:
> - hardware code is still a large API. we're expecting more hardware to be
> supported by this driver in the future. The API has already been scrubbed but we
> anticipate that the remaining hooks will be used in the future.
> - The register defines are still named "E1000_" as they are mostly identical to
> the e1000 chipsets (igb register space is a superset of most recent e1000 register
> sets).
> 
> 
> Please review,
> 
> 
> Cheers,
> 
> Auke
> 
> ---
> 
>>From 4ec9e52f44de0c1c41265c5f326b573643f24da7 Mon Sep 17 00:00:00 2001
> From: Auke Kok <auke-jan.h.kok@intel.com>
> Date: Thu, 10 Jan 2008 14:55:46 -0800
> Subject: [PATCH] igb: PCI-Express 82575 Gigabit Ethernet driver
> 
> We are pleased to announce a new Gigabit Ethernet product and its
> driver to the linux community. This product is the Intel(R) 82575
> Gigabit Ethernet adapter family. Physical adapters will be available
> to the public soon. These adapters come in 2- and 4-port versions
> (copper PHY) currently. Other variants will be available later.
> 
> The 82575 chipset supports significantly different features that
> warrant a new driver. The descriptor format is (just like the
> ixgbe driver) different. The device can use multiple MSI-X vectors
> and multiple queues for both send and receive. This allows us to
> optimize some of the driver code specifically as well compared to
> the e1000-supported devices.
> 
> This version of the igb driver no lnger uses fake netdevices and
> incorporates napi_struct members for each ring to do the multi-
> queue polling. multi-queue is enabled by default and the driver
> supports NAPI mode only.
> 
> All the namespace collisions should be gone in this version too. The
> register macro's have been condensed to improve readability.
> 
> Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
> ---
>  drivers/net/Kconfig             |   22 +
>  drivers/net/Makefile            |    1 +
>  drivers/net/igb/Makefile        |   37 +
>  drivers/net/igb/e1000_82575.c   | 1269 ++++++++++++
>  drivers/net/igb/e1000_82575.h   |  150 ++
>  drivers/net/igb/e1000_defines.h |  772 ++++++++
>  drivers/net/igb/e1000_hw.h      |  599 ++++++
>  drivers/net/igb/e1000_mac.c     | 1505 ++++++++++++++
>  drivers/net/igb/e1000_mac.h     |   98 +
>  drivers/net/igb/e1000_nvm.c     |  605 ++++++
>  drivers/net/igb/e1000_nvm.h     |   40 +
>  drivers/net/igb/e1000_phy.c     | 1807 +++++++++++++++++
>  drivers/net/igb/e1000_phy.h     |   98 +
>  drivers/net/igb/e1000_regs.h    |  270 +++
>  drivers/net/igb/igb.h           |  300 +++
>  drivers/net/igb/igb_ethtool.c   | 1927 ++++++++++++++++++
>  drivers/net/igb/igb_main.c      | 4138 +++++++++++++++++++++++++++++++++++++++
>  17 files changed, 13638 insertions(+), 0 deletions(-)
>  create mode 100644 drivers/net/igb/Makefile
>  create mode 100644 drivers/net/igb/e1000_82575.c
>  create mode 100644 drivers/net/igb/e1000_82575.h
>  create mode 100644 drivers/net/igb/e1000_defines.h
>  create mode 100644 drivers/net/igb/e1000_hw.h
>  create mode 100644 drivers/net/igb/e1000_mac.c
>  create mode 100644 drivers/net/igb/e1000_mac.h
>  create mode 100644 drivers/net/igb/e1000_nvm.c
>  create mode 100644 drivers/net/igb/e1000_nvm.h
>  create mode 100644 drivers/net/igb/e1000_phy.c
>  create mode 100644 drivers/net/igb/e1000_phy.h
>  create mode 100644 drivers/net/igb/e1000_regs.h
>  create mode 100644 drivers/net/igb/igb.h
>  create mode 100644 drivers/net/igb/igb_ethtool.c
>  create mode 100644 drivers/net/igb/igb_main.c

applied



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

end of thread, other threads:[~2008-01-22 10:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-10 23:32 RFC: igb: Intel 82575 gigabit ethernet driver (take #3) Kok, Auke
2008-01-11  0:01 ` Jeff Garzik
2008-01-11  0:22   ` Kok, Auke
2008-01-11  9:17 ` Christoph Hellwig
2008-01-22 10:05 ` Jeff Garzik

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).