netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Don Fry <brazilnut@us.ibm.com>
To: Wen Hsin Chang <whchang@tw.ibm.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, tsbogend@alpha.franken.de
Subject: Re: [PATCH] pcnet32.c: modify RX ring size through module parameter
Date: Mon, 15 May 2006 08:54:54 -0700	[thread overview]
Message-ID: <20060515155454.GA31478@us.ibm.com> (raw)
In-Reply-To: <4467F63E.5060401@tw.ibm.com>

I have several problems with this patch.  First, it assumes you only have
one device or you want all devices to operate with the same receive ring
size.  (use module_param_array like full_duplex or options).

Second, the mininum number of descriptors should be 4 not 2, or the
loopback test will look past the end of the receive ring looking for
status to change, and then try and pick up an skb pointer past the end of
the array and try to dereference it.

Either fix the loopback test to work with the minimum number of tx and rx
descriptors instead of the hard coded 4, or make the minimum rx ring
size be 4.  numbuffs = min(4 , min(lp->tx_ring_size, lp->rx_ring_size));

Another nit is the description says it is the "RX Ring Buffer Size" which
might be misunderstood as the size of the receive buffer, not the size of
the receive descriptor ring.  ("RX Ring Size" would be better).

Lastly, the patch also will not apply against pcnet32.c in mainline
2.6.17-rc4 due to whitespace changes.

On Mon, May 15, 2006 at 11:32:14AM +0800, Wen Hsin Chang wrote:
> This patch is created from pcnet32.c v1.32. it will allow users to 
> specify RX ring size upon module
> insertion via module parameter 'rx_log_size'. This is needed in some 
> cases where too small the rx ring
> size will cause RX errors upon remote installation via pcnet32 NIC card.
> 
> Signed-off-by: Wen Hsin Chang <whchang@tw.ibm.com>

-- 
Don Fry
brazilnut@us.ibm.com

  reply	other threads:[~2006-05-15 15:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-15  3:32 [PATCH] pcnet32.c: modify RX ring size through module parameter Wen Hsin Chang
2006-05-15 15:54 ` Don Fry [this message]
2006-05-15 15:58 ` Jon Mason
2006-05-16  3:05   ` Wen Hsin Chang

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=20060515155454.GA31478@us.ibm.com \
    --to=brazilnut@us.ibm.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=tsbogend@alpha.franken.de \
    --cc=whchang@tw.ibm.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).