All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Garzik <jeff@garzik.org>
To: Ananda Raju <Ananda.Raju@neterion.com>
Cc: netdev@vger.kernel.org, leonid.grossman@neterion.com,
	alicia.pena@neterion.com, ramkrishna.vepa@neterion.com,
	sivakumar.subramani@neterion.com, sreenivasa.honnur@neterion.com,
	sriram.rapuru@neterion.com
Subject: Re: [PATCH 2.6.20 1/5] s2io: Making LRO and UFO as module loadable parameter.
Date: Tue, 23 Jan 2007 00:40:46 -0500	[thread overview]
Message-ID: <45B59FDE.4080503@garzik.org> (raw)
In-Reply-To: <Pine.GSO.4.10.10701190226300.22012-100000@guinness>

Ananda Raju wrote:
> This patch adds two load parameters napi and ufo. Previously NAPI was
> compilation option with these changes wan enable disable NAPI using load
> parameter. Also we are introducing ufo load parameter to enable/disable
> ufo feature
> 
> Signed-off-by: Sivakumar Subramani <sivakumar.subramani@neterion.com>
> ---
> diff -urpN orig/drivers/net/s2io.c patch1/drivers/net/s2io.c
> --- orig/drivers/net/s2io.c	2006-12-21 10:06:58.000000000 +0530
> +++ patch1/drivers/net/s2io.c	2007-01-08 11:56:23.000000000 +0530
> @@ -401,9 +401,10 @@ S2IO_PARM_INT(lro, 0);
>   * aggregation happens until we hit max IP pkt size(64K)
>   */
>  S2IO_PARM_INT(lro_max_pkts, 0xFFFF);
> -#ifndef CONFIG_S2IO_NAPI
>  S2IO_PARM_INT(indicate_max_pkts, 0);
> -#endif
> +
> +S2IO_PARM_INT(napi, 1);
> +S2IO_PARM_INT(ufo, 0);
>  
>  static unsigned int tx_fifo_len[MAX_TX_FIFOS] =
>      {DEFAULT_FIFO_0_LEN, [1 ...(MAX_TX_FIFOS - 1)] = DEFAULT_FIFO_1_7_LEN};
> @@ -2275,9 +2276,7 @@ static int fill_rx_buffers(struct s2io_n
>  	struct config_param *config;
>  	u64 tmp;
>  	buffAdd_t *ba;
> -#ifndef CONFIG_S2IO_NAPI
>  	unsigned long flags;
> -#endif
>  	RxD_t *first_rxdp = NULL;
>  
>  	mac_control = &nic->mac_control;
> @@ -2321,12 +2320,15 @@ static int fill_rx_buffers(struct s2io_n
>  			DBG_PRINT(INTR_DBG, "%s: Next block at: %p\n",
>  				  dev->name, rxdp);
>  		}
> -#ifndef CONFIG_S2IO_NAPI
> -		spin_lock_irqsave(&nic->put_lock, flags);
> -		mac_control->rings[ring_no].put_pos =
> -		    (block_no * (rxd_count[nic->rxd_mode] + 1)) + off;
> -		spin_unlock_irqrestore(&nic->put_lock, flags);
> -#endif
> +		if(!napi) {
> +			spin_lock_irqsave(&nic->put_lock, flags);
> +			mac_control->rings[ring_no].put_pos =
> +		    	(block_no * (rxd_count[nic->rxd_mode] + 1)) + off;
> +			spin_unlock_irqrestore(&nic->put_lock, flags);
> +		} else {
> +			mac_control->rings[ring_no].put_pos =
> +			(block_no * (rxd_count[nic->rxd_mode] + 1)) + off;
> +		}	
>  		if ((rxdp->Control_1 & RXD_OWN_XENA) &&
>  			((nic->rxd_mode >= RXD_MODE_3A) &&
>  				(rxdp->Control_2 & BIT(0)))) {
> @@ -2569,7 +2571,7 @@ static void free_rx_buffers(struct s2io_
>   * 0 on success and 1 if there are No Rx packets to be processed.
>   */
>  
> -#if defined(CONFIG_S2IO_NAPI)
> +#if defined(HAVE_NETDEV_POLL)

ACK the entire patch except for the above change:  don't bother with 
HAVE_NETDEV_POLL.  In current kernels you may assume we have it.

	Jeff




  reply	other threads:[~2007-01-23  5:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-19  7:31 [PATCH 2.6.20 1/5] s2io: Making LRO and UFO as module loadable parameter Ananda Raju
2007-01-23  5:40 ` Jeff Garzik [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-01-29  5:49 Ananda Raju
2007-01-31 10:17 ` Jeff Garzik
2007-01-29  6:05 Sivakumar Subramani
2007-01-31  3:54 Sivakumar Subramani
2007-01-31 18:28 Sivakumar Subramani
2007-02-02 13:22 ` Jeff Garzik
2007-01-31 19:13 Sivakumar Subramani

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=45B59FDE.4080503@garzik.org \
    --to=jeff@garzik.org \
    --cc=Ananda.Raju@neterion.com \
    --cc=alicia.pena@neterion.com \
    --cc=leonid.grossman@neterion.com \
    --cc=netdev@vger.kernel.org \
    --cc=ramkrishna.vepa@neterion.com \
    --cc=sivakumar.subramani@neterion.com \
    --cc=sreenivasa.honnur@neterion.com \
    --cc=sriram.rapuru@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 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.