DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Gregory Etelson <getelson@nvidia.com>
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	dev@dpdk.org, mkashani@nvidia.com, rasland@nvidia.com,
	Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Subject: Re: [PATCH v3 1/2] ethdev: make representor parameter more explicit
Date: Wed, 05 Nov 2025 22:17:55 +0100	[thread overview]
Message-ID: <8735291.3yuU7cT3dn@thomas> (raw)
In-Reply-To: <20251105112039.1db64906@phoenix>

05/11/2025 20:20, Stephen Hemminger:
> Looks good as is, a couple of minor observations.
> 
> > +	/* pfX... or (pfX)... */
> > +	if ((str[0] == 'p' && str[1] == 'f') ||
> > +	    (str[0] == '(' && str[1] == 'p' && str[2] == 'f')) {
> 
> This is correct but seem like it is getting verbose.
> If there are more cases than this looking for prefix, might be
> useful to have helper function.
> 
> Looks like devargs could use some better pattern matching,
> lots of string handling already in this code.
> String processing in C is often an error trap.
> 
> > +		if (str != NULL && str[0] == ')') {
> > +			str++; /* advance past ")" */
> > +			eth_da->flags =
> > +				RTE_ETH_DEVARG_IGNORE_PF_REPRESENTOR;
> 
> Can't that go on one line, max line length in DPDK is 100.
> Is there a case where there could be multiple devargs flags?

It is the first flag.
I would prefer this flag to be named RTE_ETH_DEVARG_REPRESENTOR_IGNORE_PF.



      reply	other threads:[~2025-11-05 21:18 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-28  9:58 [PATCH " Gregory Etelson
2025-10-28  9:58 ` [PATCH 2/2] net/mlx5: support PF representor suppresion in multi-port E-Switch Gregory Etelson
2025-11-05 17:37 ` [PATCH v2 1/2] ethdev: make representor parameter more explicit Gregory Etelson
2025-11-05 17:37   ` [PATCH v2 2/2] net/mlx5: support PF representor suppresion in multi-port E-Switch Gregory Etelson
2025-11-05 17:48 ` [PATCH v3 1/2] ethdev: make representor parameter more explicit Gregory Etelson
2025-11-05 17:48   ` [PATCH v3 2/2] net/mlx5: support PF representor suppression in multi-port E-Switch Gregory Etelson
2025-11-05 19:20   ` [PATCH v3 1/2] ethdev: make representor parameter more explicit Stephen Hemminger
2025-11-05 21:17     ` Thomas Monjalon [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=8735291.3yuU7cT3dn@thomas \
    --to=thomas@monjalon.net \
    --cc=andrew.rybchenko@oktetlabs.ru \
    --cc=dev@dpdk.org \
    --cc=getelson@nvidia.com \
    --cc=mkashani@nvidia.com \
    --cc=rasland@nvidia.com \
    --cc=stephen@networkplumber.org \
    /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).