netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Andrey Turkin <andrey.turkin@gmail.com>
Cc: netdev@vger.kernel.org, Ronak Doshi <doshir@vmware.com>,
	VMware PV-Drivers Reviewers <pv-drivers@vmware.com>
Subject: Re: [PATCH v2] vmxnet3: Implement ethtool's get_channels command
Date: Mon, 18 Jul 2022 15:07:27 -0700	[thread overview]
Message-ID: <20220718150727.17175e28@kernel.org> (raw)
In-Reply-To: <20220718045110.2633-1-andrey.turkin@gmail.com>

On Mon, 18 Jul 2022 04:51:10 +0000 Andrey Turkin wrote:
> +	if (IS_ENABLED(CONFIG_PCI_MSI) && adapter->intr.type == VMXNET3_IT_MSIX) {
> +		if (adapter->share_intr == VMXNET3_INTR_BUDDYSHARE) {
> +			ec->combined_count = adapter->num_tx_queues;
> +			ec->rx_count = 0;
> +			ec->tx_count = 0;
> +		} else {
> +			ec->combined_count = 0;
> +			ec->rx_count = adapter->num_rx_queues;
> +			ec->tx_count =
> +				adapter->share_intr == VMXNET3_INTR_TXSHARE ?
> +					       1 : adapter->num_tx_queues;
> +		}
> +	} else {
> +		ec->rx_count = 0;
> +		ec->tx_count = 0;
> +		ec->combined_count = 1;

No need to set the unused counts to 0.

      parent reply	other threads:[~2022-07-18 22:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-18  4:51 [PATCH v2] vmxnet3: Implement ethtool's get_channels command Andrey Turkin
2022-07-18 21:57 ` Andrew Lunn
2022-07-18 22:07 ` 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=20220718150727.17175e28@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrey.turkin@gmail.com \
    --cc=doshir@vmware.com \
    --cc=netdev@vger.kernel.org \
    --cc=pv-drivers@vmware.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).