netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Nick Child <nnac123@linux.ibm.com>
Cc: netdev@vger.kernel.org, bjking1@linux.ibm.com,
	haren@linux.ibm.com, ricklind@us.ibm.com, mmc@linux.ibm.com
Subject: Re: [PATCH net-next 3/3] ibmveth: Ethtool set queue support
Date: Tue, 27 Sep 2022 16:43:49 -0700	[thread overview]
Message-ID: <20220927164349.0a5316bd@kernel.org> (raw)
In-Reply-To: <7e18bf4d-b922-f6f5-b7fb-08d8cc9d58aa@linux.ibm.com>

On Tue, 27 Sep 2022 14:42:39 -0500 Nick Child wrote:
> >> +static int ibmveth_set_channels(struct net_device *netdev,
> >> +				struct ethtool_channels *channels)  
> 
> >> +	/* We have IBMVETH_MAX_QUEUES netdev_queue's allocated
> >> +	 * but we may need to alloc/free the ltb's.
> >> +	 */
> >> +	netif_tx_stop_all_queues(netdev);  
> > 
> > What if the device is not UP?  
> 
>  From my understanding this will just set the __QUEUE_STATE_DRV_XOFF bit
> of all of the queues. I don't think this will cause any issues if the
> device is DOWN. Please let me know if you are worried about anything
> in particular here.

My concern was that the memory is allocated on open and freed on close.
So we shouldn't be doing any extra work if the device is closed, just
record the desired number of queues and return success.

> Just as a side note, ibmveth never sets carrier state to UP since it
> cannot determine the link status of the physical device being
> virtualized. The state is instead left as UNKNOWN when not DOWN.

Sorry for lack of clarity - UP as in IFF_UP, not IFF_LOWER_UP.

      reply	other threads:[~2022-09-27 23:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-21 21:50 [PATCH net-next 1/3] ibmveth: Copy tx skbs into a premapped buffer Nick Child
2022-09-21 21:50 ` [PATCH net-next 2/3] ibmveth: Implement multi queue on xmit Nick Child
2022-09-21 21:50 ` [PATCH net-next 3/3] ibmveth: Ethtool set queue support Nick Child
2022-09-26 18:44   ` Jakub Kicinski
2022-09-27 19:42     ` Nick Child
2022-09-27 23:43       ` Jakub Kicinski [this message]

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=20220927164349.0a5316bd@kernel.org \
    --to=kuba@kernel.org \
    --cc=bjking1@linux.ibm.com \
    --cc=haren@linux.ibm.com \
    --cc=mmc@linux.ibm.com \
    --cc=netdev@vger.kernel.org \
    --cc=nnac123@linux.ibm.com \
    --cc=ricklind@us.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).