DPDK patches and discussions
 help / color / mirror / Atom feed
From: Yanling Song <songyl@ramaxel.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	"yanling.song@linux.dev" <yanling.song@linux.dev>,
	=?GB18030?B?0e64yQ==?= <yanggan@ramaxel.com>,
	"ferruh.yigit@intel.com" <ferruh.yigit@intel.com>,
	xuyun@ramaxel.com
Subject: Re: [PATCH v1 16/25] net/spnic: add device configure/version/info
Date: Wed, 22 Dec 2021 08:56:42 +0800	[thread overview]
Message-ID: <20211222085642.000079ce@ramaxel.com> (raw)
In-Reply-To: <20211219162356.08e62c72@hermes.local>

On Mon, 20 Dec 2021 08:23:56 +0800
Stephen Hemminger <stephen@networkplumber.org> wrote:

> On Sat, 18 Dec 2021 10:51:43 +0800
> Yanling Song <songyl@ramaxel.com> wrote:
> 
> > +static int spnic_dev_configure(struct rte_eth_dev *dev)
> > +{
> > +	struct spnic_nic_dev *nic_dev =
> > SPNIC_ETH_DEV_TO_PRIVATE_NIC_DEV(dev); +
> > +	nic_dev->num_sqs =  dev->data->nb_tx_queues;
> > +	nic_dev->num_rqs = dev->data->nb_rx_queues;
> > +
> > +	if (nic_dev->num_sqs > nic_dev->max_sqs ||
> > +	    nic_dev->num_rqs > nic_dev->max_rqs) {
> > +		PMD_DRV_LOG(ERR, "num_sqs: %d or num_rqs: %d
> > larger than max_sqs: %d or max_rqs: %d",
> > +			    nic_dev->num_sqs, nic_dev->num_rqs,
> > +			    nic_dev->max_sqs, nic_dev->max_rqs);
> > +		return -EINVAL;
> > +	}
> > +  
> 
> This should already be covered by checks in ethedev:dev_configure.

OK. The check will be removed in the next version.

> 
> > +	/* The range of mtu is 384~9600 */
> > +	if (SPNIC_MTU_TO_PKTLEN(dev->data->dev_conf.rxmode.mtu) <
> > +	    SPNIC_MIN_FRAME_SIZE ||
> > +	    SPNIC_MTU_TO_PKTLEN(dev->data->dev_conf.rxmode.mtu) >
> > +	    SPNIC_MAX_JUMBO_FRAME_SIZE) {
> > +		PMD_DRV_LOG(ERR, "Max rx pkt len out of range,
> > mtu: %d, expect between %d and %d",
> > +			    dev->data->dev_conf.rxmode.mtu,
> > +			    SPNIC_MIN_FRAME_SIZE,
> > SPNIC_MAX_JUMBO_FRAME_SIZE);
> > +		return -EINVAL;
> > +	}  
> 
> Already covered by eth_dev_validate_mtu called from ethdev
> dev_configure.
> 
OK. The check will be removed in the next version.

  reply	other threads:[~2021-12-22  0:56 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-18  2:51 [PATCH v1 00/25] Net/SPNIC: support SPNIC into DPDK 22.03 Yanling Song
2021-12-18  2:51 ` [PATCH v1 01/25] drivers/net: introduce a new PMD driver Yanling Song
2021-12-19 19:40   ` Stephen Hemminger
2021-12-22  0:54     ` Yanling Song
2021-12-22 16:55       ` Stephen Hemminger
2021-12-23  8:10         ` Yanling Song
2021-12-18  2:51 ` [PATCH v1 02/25] net/spnic: initialize the HW interface Yanling Song
2021-12-18  2:51 ` [PATCH v1 03/25] net/spnic: add mbox message channel Yanling Song
2021-12-18  2:51 ` [PATCH v1 04/25] net/spnic: introduce event queue Yanling Song
2021-12-18  2:51 ` [PATCH v1 05/25] net/spnic: add mgmt module Yanling Song
2021-12-18  2:51 ` [PATCH v1 06/25] net/spnic: add cmdq and work queue Yanling Song
2021-12-18  2:51 ` [PATCH v1 07/25] net/spnic: add interface handling cmdq message Yanling Song
2021-12-18  2:51 ` [PATCH v1 08/25] net/spnic: add hardware info initialization Yanling Song
2021-12-18  2:51 ` [PATCH v1 09/25] net/spnic: support MAC and link event handling Yanling Song
2021-12-18  2:51 ` [PATCH v1 10/25] net/spnic: add function info initialization Yanling Song
2021-12-18  2:51 ` [PATCH v1 11/25] net/spnic: add queue pairs context initialization Yanling Song
2021-12-18  2:51 ` [PATCH v1 12/25] net/spnic: support mbuf handling of Tx/Rx Yanling Song
2021-12-18  2:51 ` [PATCH v1 13/25] net/spnic: support Rx congfiguration Yanling Song
2021-12-18  2:51 ` [PATCH v1 14/25] net/spnic: add port/vport enable Yanling Song
2021-12-18  2:51 ` [PATCH v1 15/25] net/spnic: support IO packets handling Yanling Song
2021-12-18  2:51 ` [PATCH v1 16/25] net/spnic: add device configure/version/info Yanling Song
2021-12-20  0:23   ` Stephen Hemminger
2021-12-22  0:56     ` Yanling Song [this message]
2021-12-18  2:51 ` [PATCH v1 17/25] net/spnic: support RSS configuration update and get Yanling Song
2021-12-18  2:51 ` [PATCH v1 18/25] net/spnic: support VLAN filtering and offloading Yanling Song
2021-12-18  2:51 ` [PATCH v1 19/25] net/spnic: support promiscuous and allmulticast Rx modes Yanling Song
2021-12-18  2:51 ` [PATCH v1 20/25] net/spnic: support flow control Yanling Song
2021-12-18  2:51 ` [PATCH v1 21/25] net/spnic: support getting Tx/Rx queues info Yanling Song
2021-12-18  2:51 ` [PATCH v1 22/25] net/spnic: net/spnic: support xstats statistics Yanling Song
2021-12-18  2:51 ` [PATCH v1 23/25] net/spnic: support VFIO interrupt Yanling Song
2021-12-18  2:51 ` [PATCH v1 24/25] net/spnic: support Tx/Rx queue start/stop Yanling Song
2021-12-18  2:51 ` [PATCH v1 25/25] net/spnic: add doc infrastructure Yanling Song

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=20211222085642.000079ce@ramaxel.com \
    --to=songyl@ramaxel.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=stephen@networkplumber.org \
    --cc=xuyun@ramaxel.com \
    --cc=yanggan@ramaxel.com \
    --cc=yanling.song@linux.dev \
    /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).