Netdev List
 help / color / mirror / Atom feed
From: Vladimir Oltean <olteanv@gmail.com>
To: Ante Knezic <ante.knezic@helmholz.de>
Cc: andrew@lunn.ch, davem@davemloft.net, edumazet@google.com,
	f.fainelli@gmail.com, kuba@kernel.org,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	pabeni@redhat.com
Subject: Re: [PATCH net-next] net: dsa: dont use generic selftest strings for custom selftests
Date: Thu, 14 Dec 2023 16:56:20 +0200	[thread overview]
Message-ID: <20231214145620.lfsft2c3x5fjz6ev@skbuf> (raw)
In-Reply-To: <20231214144751.1507-1-ante.knezic@helmholz.de>

On Thu, Dec 14, 2023 at 03:47:51PM +0100, Ante Knezic wrote:
> Indeed I do have a custom implementation for the mv88e6xxx chip, but its not
> come to state to be posted because of test/chip specifics.
> 
> > I didn't notice when the selftest support was added that there is no
> > implementation in DSA drivers of custom ds->ops->self_test(). Adding
> > interfaces with no users is frowned upon, precisely because it doesn't
> > show the big picture.
> 
> I was not aware of this, I apologize. If this is the case, perhaps this patch
> should wait for the first custom self test implementation and be reposted as
> a part of bigger series.
> 
> Thanks,
> Ante
> 

I agree this should be resubmitted with a user of the API. Looking
forward to seeing it. Thanks for the understanding.

The only thing I would want to comment on the patch as it is is to avoid
the pattern of:

	if (a)
		return x;
	else
		return y;

and formulate it as:

	if (a)
		return x;

	return y;

instead. The "else" is redundant for an "if" that ends with a return statement.

---
pw-bot: changes-requested

      reply	other threads:[~2023-12-14 14:56 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-14 14:21 [PATCH net-next] net: dsa: dont use generic selftest strings for custom selftests Ante Knezic
2023-12-14 14:25 ` Vladimir Oltean
2023-12-14 14:47   ` Ante Knezic
2023-12-14 14:56     ` Vladimir Oltean [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=20231214145620.lfsft2c3x5fjz6ev@skbuf \
    --to=olteanv@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=ante.knezic@helmholz.de \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.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