DPDK patches and discussions
 help / color / mirror / Atom feed
From: Shahaf Shuler <shahafs@mellanox.com>
To: Stephen Hemminger <stephen@networkplumber.org>,
	Ferruh Yigit <ferruh.yigit@intel.com>
Cc: Thomas Monjalon <thomas@monjalon.net>,
	"dev@dpdk.org" <dev@dpdk.org>, "Wei Dai" <wei.dai@intel.com>,
	Qi Zhang <qi.z.zhang@intel.com>,
	Andrew Rybchenko <arybchenko@solarflare.com>
Subject: Re: [dpdk-dev] [PATCH] ethdev: force offloading API rules
Date: Sat, 9 Jun 2018 18:43:20 +0000	[thread overview]
Message-ID: <DB7PR05MB44260ECEDA7AD7FF8671D5B0C37A0@DB7PR05MB4426.eurprd05.prod.outlook.com> (raw)
In-Reply-To: <20180608130214.686c79e8@xeon-e3>

Friday, June 8, 2018 11:02 PM, Stephen Hemminger:
> Subject: Re: [dpdk-dev] [PATCH] ethdev: force offloading API rules
> 
> On Thu, 31 May 2018 13:44:30 +0100
> Ferruh Yigit <ferruh.yigit@intel.com> wrote:
> 
> > The error path was disabled in previous release to let apps to be more
> > flexible.
> >
> > But this release they are enabled, applications have to obey offload
> > API rules otherwise they will get errors from following APIs:
> > rte_eth_dev_configure
> > rte_eth_rx_queue_setup
> > rte_eth_tx_queue_setup
> >
> > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>

I am OK with returning EINVAL in case of configuration error.

> 
> Rather than always returning -EINVAL, why not propagate error code that
> the driver returns. This would allow driver to give a more detailed error
> return.
> 
> The problem with that is you probably need to do a review of each drivers
> configure and setup routines to see what they return on error (if any).

Per my understanding the error is in-depended on driver specific implementation, it is rather to enforce the offloading API rules of ethdev layer, which are:
1. PMD reports offloads capabilities
2. application sets it's offloads based on the supported capabilities.   

When the configuration fail, no need to dig into driver, just to look on the error log and see which unsupported offloads were set. 

  reply	other threads:[~2018-06-09 18:43 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-31 12:44 Ferruh Yigit
2018-06-08 19:51 ` Ferruh Yigit
2018-06-08 20:01   ` Thomas Monjalon
2018-06-13 15:16     ` Thomas Monjalon
2018-06-14 11:11       ` Ferruh Yigit
2018-06-09  9:29   ` Andrew Rybchenko
2018-06-08 20:02 ` Stephen Hemminger
2018-06-09 18:43   ` Shahaf Shuler [this message]
2018-06-27  8:31 Ido Goshen
2018-06-27  9:23 ` Ferruh Yigit

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=DB7PR05MB44260ECEDA7AD7FF8671D5B0C37A0@DB7PR05MB4426.eurprd05.prod.outlook.com \
    --to=shahafs@mellanox.com \
    --cc=arybchenko@solarflare.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=qi.z.zhang@intel.com \
    --cc=stephen@networkplumber.org \
    --cc=thomas@monjalon.net \
    --cc=wei.dai@intel.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).