From: Stephen Hemminger <shemminger@vyatta.com>
To: ram.vepa@neterion.com
Cc: David Miller <davem@davemloft.net>, Netdev <netdev@vger.kernel.org>
Subject: Re: [net-2.6 PATCH 7/10] Neterion: New driver: Main entry points
Date: Wed, 25 Mar 2009 08:30:08 -0700 [thread overview]
Message-ID: <20090325083008.0179381d@nehalam> (raw)
In-Reply-To: <1237968795.1655.271.camel@flash>
On 25 Mar 2009 00:13:33 -0800
Ramkrishna Vepa <ram.vepa@neterion.com> wrote:
> This patch implements all the driver entry point functions.
> - Definition of all module loadable paramters.
> - Implementation of all driver entry point functions.
> - Changes from previous submission -
> - Incorporated following review comments from Ben Hutchings
> - NAPI is always enabled (no option to turn it OFF).
> - Loadable parameters
> rx_steering_type: This loadable option is removed.
> ring_blocks: This loadable option is removed.
> The driver default settings work well in most if not all cases.
> Another patch to configure these parameters with ethtool will be
> released in the future.
> - LRO has been deprecated in favour of GRO - Bill Fink & Dave Miller's comment
> - Fixed sparse warnings - Reported by Andi Kleen
> - Removed unused variables
>
> Signed-off-by: Sivakumar Subramani <sivakumar.subramani@neterion.com>
> Signed-off-by: Rastapur Santosh <santosh.rastapur@neterion.com>
> Signed-off-by: Ramkrishna Vepa <ram.vepa@neterion.com>
> ---
> diff -Nurp patch_6/drivers/net/vxge/vxge-main.c patch_7/drivers/net/vxge/vxge-main.c
> --- patch_6/drivers/net/vxge/vxge-main.c 1969-12-31 16:00:00.000000000 -0800
> +++ patch_7/drivers/net/vxge/vxge-main.c 2009-03-24 13:34:33.000000000 -0700
> @@ -0,0 +1,4844 @@
> +/******************************************************************************
> +* This software may be used and distributed according to the terms of
> +* the GNU General Public License (GPL), incorporated herein by reference.
> +* Drivers based on or derived from this code fall under the GPL and must
> +* retain the authorship, copyright and license notice. This file is not
> +* a complete program and may only be used when the entire operating
> +* system is licensed under the GPL.
> +* See the file COPYING in this distribution for more information.
> +*
> +* vxge-main.c: Driver for Neterion Inc's X3100 Series 10GbE PCIe I/O
> +* Virtualized Server Adapter.
> +* Copyright(c) 2002-2009 Neterion Inc.
> +*
> +* The module loadable parameters that are supported by the driver and a brief
> +* explanation of all the variables:
> +* vlan_tag_strip:
> +* Strip VLAN Tag enable/disable. Instructs the device to remove
> +* the VLAN tag from all received tagged frames that are not
> +* replicated at the internal L2 switch.
> +* 0 - Do not strip the VLAN tag.
> +* 1 - Strip the VLAN tag.
> +*
> +* addr_learn_en:
> +* Enable Receive Traffic Steering using MAC destination address.
> +* 0 - DISABLE
> +* 1 - ENABLE
> +*
> +* gro:
> +* Enable Generic Receive Offload (GRO)
> +* 0 - DISABLE
> +* 1 - ENABLE
> +*
> +* max_config_port:
> +* Maximum number of port to be supported.
> +* MIN -1 and MAX - 2
> +*
> +* fifo_indicate_max_pkts:
> +* Sets the maximum number of transmit frames to be processed within
> +* single interrupt.
> +* MIN - 1 and MAX - 65536
> +*
> +* ring_indicate_max_pkts:
> +* Sets the maximum number of received frames to be processed within
> +* single interrupt.
> +* MIN - 1 and MAX - 65536
> +*
> +* max_config_vpath:
> +* This configures the maximum no of VPATH configures for each
> +* device function.
> +* MIN - 1 and MAX - 17
> +*
> +* max_config_dev:
> +* This configures maximum no of Device function to be enabled.
> +* MIN - 1 and MAX - 17
> +*
> +* intr_type:
> +* This configures the type of interrupt.
> +* 0 - INTA
> +* 1 - Reserved
> +* 2 - MSIX
> +* 3 - EMULATED_INTA
> +*
> +* exec_mode:
> +* This is set make enable the debug mode by default.
> +* 0 - DISABLE
> +* 1 - ENABLE
> +*
> +* tx_steering_type:
> +* This parameter is for configuring the transmit steering.
> +* 0 - No steering
> +* 1 - Priority steering
> +* 2 - Vlan steering
> +* 3 - Multiqueue steering
> +* 4 - Port steering (default)
> +*
> +* tx_pause_enable:
> +* This parameter enables pause frame generation.
> +* 0 - Disable
> +* 1 - Enable
> +*
> +* rx_pause_enable:
> +* This parameter enables response to received pause frames
> +* 0 - Disable
> +* 1 - Enable.
> +*
> +************************************
Module parameters are a method of last resort. Module parameters are
a pain for customers because they are hard to configure, and only work
on one device driver. They should not be used if anything else is available.
Therefore the following can be replaced by existing ethtool hooks
gro -> ethtool_get_gro, ethtool_set_gro
tx/rx_pause -> ethtool_get_pauseparm, ethtool_set_pauseparm
I would like to see the following added to ethtool, go ahead and propose
some additions to ethtool that do what you need for addr_learn_en and
tx_steering_type.
Not sure what exec_mode does but why not call it 'debug'
The intr_type parameter should be unnecessary, assuming the driver does
the right thing based on bus methods. If you are worried about buggy MSIX
hardware, then please do a simulated irq to test IRQ routing.
Most drivers just use the NAPI weight to control the parameter you
are setting with ring_indicate_max_pkts. The weight value is changeable
at runtime with sysfs.
next prev parent reply other threads:[~2009-03-25 15:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-25 8:13 [net-2.6 PATCH 7/10] Neterion: New driver: Main entry points Ramkrishna Vepa
2009-03-25 15:30 ` Stephen Hemminger [this message]
2009-03-25 23:26 ` Ramkrishna Vepa
2009-03-25 23:47 ` Ramkrishna Vepa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090325083008.0179381d@nehalam \
--to=shemminger@vyatta.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=ram.vepa@neterion.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).