netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Vadim Fedorenko <vadim.fedorenko@linux.dev>
Cc: Manish Chopra <manishc@marvell.com>,
	Andrew Lunn <andrew+netdev@lunn.ch>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>,
	Richard Cochran <richardcochran@gmail.com>,
	Simon Horman <horms@kernel.org>,
	Jacob Keller <jacob.e.keller@intel.com>,
	Kory Maincent <kory.maincent@bootlin.com>,
	netdev@vger.kernel.org
Subject: Re: [PATCH net-next v2 1/2] bnx2x: convert to use ndo_hwtstamp callbacks
Date: Fri, 7 Nov 2025 18:41:02 -0800	[thread overview]
Message-ID: <20251107184102.65b0f765@kernel.org> (raw)
In-Reply-To: <20251106213717.3543174-2-vadim.fedorenko@linux.dev>

On Thu,  6 Nov 2025 21:37:16 +0000 Vadim Fedorenko wrote:
> +	switch (config->tx_type) {
> +	case HWTSTAMP_TX_ONESTEP_SYNC:
> +	case HWTSTAMP_TX_ONESTEP_P2P:
> +		NL_SET_ERR_MSG_MOD(extack,
> +				   "One-step timestamping is not supported");
> +		return -ERANGE;
> +	default:
> +		break;
> +	}

This is the wrong way around, if someone adds a new value unsupported
by the driver it will pass. We should be listing the supported types
and

	default:
		...ERR_MSG..
		return -ERANGE;
	}
-- 
pw-bot: cr

  reply	other threads:[~2025-11-08  2:41 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-06 21:37 [PATCH net-next v2 0/2] convert drivers to use ndo_hwtstamp callbacks part 4 Vadim Fedorenko
2025-11-06 21:37 ` [PATCH net-next v2 1/2] bnx2x: convert to use ndo_hwtstamp callbacks Vadim Fedorenko
2025-11-08  2:41   ` Jakub Kicinski [this message]
2025-11-08 12:38     ` Vadim Fedorenko
2025-11-10 23:23       ` Jacob Keller
2025-11-10 23:50         ` Jakub Kicinski
2025-11-06 21:37 ` [PATCH net-next v2 2/2] qede: " Vadim Fedorenko

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=20251107184102.65b0f765@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=jacob.e.keller@intel.com \
    --cc=kory.maincent@bootlin.com \
    --cc=manishc@marvell.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=richardcochran@gmail.com \
    --cc=vadim.fedorenko@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).