All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <brouer@redhat.com>
To: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: brouer@redhat.com, davem@davemloft.net,
	alexei.starovoitov@gmail.com, daniel@iogearbox.net,
	netdev@vger.kernel.org, oss-drivers@netronome.com,
	bjorn.topel@intel.com
Subject: Re: [PATCH net-next 1/3] net: update real_num_rx_queues even when !CONFIG_SYSFS
Date: Tue, 31 Jul 2018 15:02:01 +0200	[thread overview]
Message-ID: <20180731150201.49e2fd45@redhat.com> (raw)
In-Reply-To: <20180731034353.3774-2-jakub.kicinski@netronome.com>

On Mon, 30 Jul 2018 20:43:51 -0700
Jakub Kicinski <jakub.kicinski@netronome.com> wrote:

> We used to depend on real_num_rx_queues as a upper bound for sanity
> checks.  For AF_XDP socket validation it's useful if the check behaves
> the same regardless of CONFIG_SYSFS setting.
> 
> Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
> Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com>

Acked-by: Jesper Dangaard Brouer <brouer@redhat.com>

> ---
>  include/linux/netdevice.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
> index 9c917467a2c7..3bf7e93c9e96 100644
> --- a/include/linux/netdevice.h
> +++ b/include/linux/netdevice.h
> @@ -3431,8 +3431,9 @@ int netif_set_real_num_tx_queues(struct net_device *dev, unsigned int txq);
>  int netif_set_real_num_rx_queues(struct net_device *dev, unsigned int rxq);
>  #else
>  static inline int netif_set_real_num_rx_queues(struct net_device *dev,
> -						unsigned int rxq)
> +						unsigned int rxqs)
>  {
> +	dev->real_num_rx_queues = rxqs;
>  	return 0;
>  }
>  #endif

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer

  reply	other threads:[~2018-07-31 14:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-31  3:43 [PATCH net-next 0/3] xsk: improvements to RX queue check and replace Jakub Kicinski
2018-07-31  3:43 ` [PATCH net-next 1/3] net: update real_num_rx_queues even when !CONFIG_SYSFS Jakub Kicinski
2018-07-31 13:02   ` Jesper Dangaard Brouer [this message]
2018-07-31  3:43 ` [PATCH net-next 2/3] xsk: refactor xdp_umem_assign_dev() Jakub Kicinski
2018-07-31  3:43 ` [PATCH net-next 3/3] xsk: don't allow umem replace at stack level Jakub Kicinski
2018-07-31  6:34 ` [PATCH net-next 0/3] xsk: improvements to RX queue check and replace Björn Töpel
2018-07-31  7:50 ` Daniel Borkmann
2018-07-31 16:48   ` David Miller

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=20180731150201.49e2fd45@redhat.com \
    --to=brouer@redhat.com \
    --cc=alexei.starovoitov@gmail.com \
    --cc=bjorn.topel@intel.com \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=jakub.kicinski@netronome.com \
    --cc=netdev@vger.kernel.org \
    --cc=oss-drivers@netronome.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.