public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Vladimir Oltean <vladimir.oltean@nxp.com>
To: Maxim Georgiev <glipus@gmail.com>
Cc: kory.maincent@bootlin.com, kuba@kernel.org,
	netdev@vger.kernel.org, maxime.chevallier@bootlin.com,
	vadim.fedorenko@linux.dev, richardcochran@gmail.com,
	gerhard@engleder-embedded.com, liuhangbin@gmail.com
Subject: Re: [RFC PATCH net-next v6 1/5] net: Add NDOs for hardware timestamp get/set
Date: Thu, 11 May 2023 15:32:45 +0300	[thread overview]
Message-ID: <20230511123245.rs5gskwukood3ger@skbuf> (raw)
In-Reply-To: <20230502043150.17097-2-glipus@gmail.com>

On Mon, May 01, 2023 at 10:31:46PM -0600, Maxim Georgiev wrote:
>  struct net_device_ops {
>  	int			(*ndo_init)(struct net_device *dev);
> @@ -1649,6 +1659,12 @@ struct net_device_ops {
>  	ktime_t			(*ndo_get_tstamp)(struct net_device *dev,
>  						  const struct skb_shared_hwtstamps *hwtstamps,
>  						  bool cycles);
> +	int			(*ndo_hwtstamp_get)(struct net_device *dev,
> +						    struct kernel_hwtstamp_config *kernel_config,
> +						    struct netlink_ext_ack *extack);

I'm not sure it is necessary to pass an extack to "get". That should
only give a more detailed reason if the driver refuses something.

For that matter, now that ndo_hwtstamp_get() should no longer be
concerned with the copy_to_user(), I'm not even sure that it should
return int at all, and not void. The transition is going to be slightly
problematic though, with the generic_hwtstamp_get_lower() necessarily
still calling dev_eth_ioctl() -> copy_to_user(), so we probably can't
make it void just now.

  reply	other threads:[~2023-05-11 12:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-02  4:31 [RFC PATCH net-next v6 0/5] New NDO methods ndo_hwtstamp_get/set Maxim Georgiev
2023-05-02  4:31 ` [RFC PATCH net-next v6 1/5] net: Add NDOs for hardware timestamp get/set Maxim Georgiev
2023-05-11 12:32   ` Vladimir Oltean [this message]
2023-05-12  3:22     ` Max Georgiev
2023-05-12 17:41       ` Jakub Kicinski
2023-05-15 15:36         ` Max Georgiev
2023-05-02  4:31 ` [RFC PATCH net-next v6 2/5] net: Add ifreq pointer field to kernel_hwtstamp_config structure Maxim Georgiev
2023-05-04  3:05   ` Jakub Kicinski
2023-05-04 15:21     ` Max Georgiev
2023-05-04 15:41       ` Jakub Kicinski
2023-05-11  9:30   ` Vladimir Oltean
2023-05-02  4:31 ` [RFC PATCH net-next v6 3/5] vlan/macvlan: Add ndo_hwtstamp_get/set support to vlan/macvlan code path Maxim Georgiev
2023-05-02  4:31 ` [RFC PATCH net-next v6 4/5] bond: Add ndo_hwtstamp_get/set support to bond driver Maxim Georgiev
2023-05-02  4:31 ` [RFC PATCH net-next v6 5/5] netdevsim: Implement ndo_hwtstamp_get/set methods in netdevsim driver Maxim Georgiev
2023-06-21  2:23 ` [RFC PATCH net-next v6 0/5] New NDO methods ndo_hwtstamp_get/set Jakub Kicinski
2023-07-01 10:03   ` Vladimir Oltean
2023-07-01 14:51     ` Max Georgiev

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=20230511123245.rs5gskwukood3ger@skbuf \
    --to=vladimir.oltean@nxp.com \
    --cc=gerhard@engleder-embedded.com \
    --cc=glipus@gmail.com \
    --cc=kory.maincent@bootlin.com \
    --cc=kuba@kernel.org \
    --cc=liuhangbin@gmail.com \
    --cc=maxime.chevallier@bootlin.com \
    --cc=netdev@vger.kernel.org \
    --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