netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: "Kirsher, Jeffrey T" <jeffrey.t.kirsher@intel.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"gospo@redhat.com" <gospo@redhat.com>,
	"Fastabend, John R" <john.r.fastabend@intel.com>
Subject: Re: [net-next-2.6 PATCH 3/3] ixgbe: Do not allocate too many netdev txqueues
Date: Sun, 28 Feb 2010 23:21:37 -0800	[thread overview]
Message-ID: <1267428097.2052.772.camel@localhost> (raw)
In-Reply-To: <1267329420.9082.28.camel@edumazet-laptop>

On Sat, 2010-02-27 at 20:57 -0700, Eric Dumazet wrote:
> Le samedi 27 février 2010 à 17:02 -0800, Peter P Waskiewicz Jr a écrit :
> > On Fri, 2010-02-26 at 06:04 -0800, Eric Dumazet wrote:
> > > Le vendredi 26 février 2010 à 01:15 -0800, Jeff Kirsher a écrit :
> > > > +	if (ii->mac == ixgbe_mac_82598EB)
> > > > +		indices = min_t(unsigned int, indices, IXGBE_MAX_RSS_INDICES);
> > > > +	else
> > > > +		indices = min_t(unsigned int, indices, IXGBE_MAX_FDIR_INDICES);
> > > > +
> > > > +	indices = max_t(unsigned int, indices, IXGBE_MAX_DCB_INDICES);
> > > > +#ifdef IXGBE_FCOE
> > > > +	indices += min_t(unsigned int, num_possible_cpus(),
> > > > +			 IXGBE_MAX_FCOE_INDICES);
> > > > +#endif
> > > > +	indices = min_t(unsigned int, indices, MAX_TX_QUEUES);
> > > > +	netdev = alloc_etherdev_mq(sizeof(struct ixgbe_adapter), indices);
> > > >  	if (!netdev) {
> > > >  		err = -ENOMEM;
> > > >  		goto err_alloc_etherdev;
> > > > 
> > > 
> > > Thanks Jeff, but what is the reason for limiting to MAX_TX_QUEUES ?
> > > Is it a hardware issue ?
> > > 
> > 
> > MAX_TX_QUEUES is 128, which is the maximum the 82599 device supports in
> > hardware (82598 supports 32 Tx queues).  I'm not sure why you'd ever
> > want to have more Tx queues than what you have in the network device.
> 
> I was not sure MAX_TX_QUEUES capping was still necessary after the
> block :
> 
> if (ii->mac == ixgbe_mac_82598EB)
>           indices = min_t(unsigned int, indices, IXGBE_MAX_RSS_INDICES);
> else
>           indices = min_t(unsigned int, indices,
> IXGBE_MAX_FDIR_INDICES);
> 
> indices = max_t(unsigned int, indices, IXGBE_MAX_DCB_INDICES);
> #ifdef IXGBE_FCOE
> 	indices += min_t(unsigned int, num_possible_cpus(),
>                     IXGBE_MAX_FCOE_INDICES);
> #endif
> 
> So I asked to be sure that MAX_TX_QUEUES was not a leftover from the
> previous default allocation.
> 
> Thanks

I see what you're getting at now.  The most we could have from this
codepath is 72 indices for 82599, and 24 for 82598, so yeah, this is
probably unneeded.

We can get the patch cleaned up.

Cheers,
-PJ


  reply	other threads:[~2010-03-01  7:21 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-26  9:14 [net-next-2.6 PATCH 1/3] ixgbe: Fix DMA mapping/unmapping issues when HWRSC is enabled on IOMMU enabled kernels Jeff Kirsher
2010-02-26  9:14 ` [net-next-2.6 PATCH 2/3] ixgbe: do not stop tx queues in ixgbe_set_tso Jeff Kirsher
2010-02-26 10:10   ` David Miller
2010-02-26  9:15 ` [net-next-2.6 PATCH 3/3] ixgbe: Do not allocate too many netdev txqueues Jeff Kirsher
2010-02-26 10:10   ` David Miller
2010-02-26 14:04   ` Eric Dumazet
2010-02-28  1:02     ` Peter P Waskiewicz Jr
2010-02-28  3:57       ` Eric Dumazet
2010-03-01  7:21         ` Peter P Waskiewicz Jr [this message]
2010-03-01  7:53           ` John Fastabend
2010-02-26 10:10 ` [net-next-2.6 PATCH 1/3] ixgbe: Fix DMA mapping/unmapping issues when HWRSC is enabled on IOMMU enabled kernels David Miller
2010-03-02  0:29 ` Simon Horman
2010-03-02  1:09   ` Chilakala, Mallikarjuna

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=1267428097.2052.772.camel@localhost \
    --to=peter.p.waskiewicz.jr@intel.com \
    --cc=davem@davemloft.net \
    --cc=eric.dumazet@gmail.com \
    --cc=gospo@redhat.com \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=john.r.fastabend@intel.com \
    --cc=netdev@vger.kernel.org \
    /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).