Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Russell King - ARM Linux admin
On Thu, Jan 21, 2021 at 07:55:34PM +0100, Andrew Lunn wrote: > On Thu, Jan 21, 2021 at 09:03:47AM -0800, Richard Cochran wrote: > > On Thu, Jan 21, 2021 at 05:22:37PM +0100, Andrew Lunn wrote: > > > > > There is a growing interesting in PTP, the number of drivers keeps > > > going up. The likeliho

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Andrew Lunn
On Thu, Jan 21, 2021 at 09:03:47AM -0800, Richard Cochran wrote: > On Thu, Jan 21, 2021 at 05:22:37PM +0100, Andrew Lunn wrote: > > > There is a growing interesting in PTP, the number of drivers keeps > > going up. The likelihood of MAC/PHY combination having two > > timestamping sources is growin

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Russell King - ARM Linux admin
On Thu, Jan 21, 2021 at 07:06:11AM -0800, Richard Cochran wrote: > On Thu, Jan 21, 2021 at 10:27:38AM +, Russell King - ARM Linux admin > wrote: > > As I already explained to you, you can *NOT* use kernel configuration > > to make the choice. ARM is a multi-platform kernel, and we will not >

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Richard Cochran
On Thu, Jan 21, 2021 at 05:22:37PM +0100, Andrew Lunn wrote: > There is a growing interesting in PTP, the number of drivers keeps > going up. The likelihood of MAC/PHY combination having two > timestamping sources is growing all the time. So the stack needs to > change to support the selection of

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Andrew Lunn
On Thu, Jan 21, 2021 at 07:06:11AM -0800, Richard Cochran wrote: > On Thu, Jan 21, 2021 at 10:27:38AM +, Russell King - ARM Linux admin > wrote: > > As I already explained to you, you can *NOT* use kernel configuration > > to make the choice. ARM is a multi-platform kernel, and we will not >

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Richard Cochran
On Thu, Jan 21, 2021 at 10:27:38AM +, Russell King - ARM Linux admin wrote: > As I already explained to you, you can *NOT* use kernel configuration > to make the choice. ARM is a multi-platform kernel, and we will not > stand for platform choices dictated by kernel configuration options. This

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-21 Thread Russell King - ARM Linux admin
On Wed, Jan 20, 2021 at 08:04:51PM -0800, Richard Cochran wrote: > On Thu, Jan 14, 2021 at 10:38:00PM +, Russell King - ARM Linux admin > wrote: > > > So, I think the only way to prevent a regression with the code as > > it is today is that we _never_ support PTP on Marvell PHYs - because > >

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-20 Thread Richard Cochran
On Thu, Jan 14, 2021 at 10:38:00PM +, Russell King - ARM Linux admin wrote: > So, I think the only way to prevent a regression with the code as > it is today is that we _never_ support PTP on Marvell PHYs - because > doing so _will_ break the existing MVPP2 driver's implementation and > cause

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Thu, Jan 14, 2021 at 05:31:11PM +, Russell King - ARM Linux admin wrote: > On Thu, Jan 14, 2021 at 09:27:12AM -0800, Richard Cochran wrote: > > Thanks for the reminder. We ended up with having to review the MAC > > drivers that support phydev. > > > > > > https://lore.kernel.org/netdev

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Thu, Jan 14, 2021 at 09:27:12AM -0800, Richard Cochran wrote: > On Thu, Jan 14, 2021 at 01:32:35PM +, Russell King - ARM Linux admin > wrote: > > > We had already discussed this patch last year, and you agreed with it > > > then. What has changed? > > > > See the discussion in this sub-thr

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Richard Cochran
On Thu, Jan 14, 2021 at 01:32:35PM +, Russell King - ARM Linux admin wrote: > > We had already discussed this patch last year, and you agreed with it > > then. What has changed? > > See the discussion in this sub-thread: > > https://lore.kernel.org/netdev/20200729105807.gz1...@shell.armlinux.

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Thu, Jan 14, 2021 at 05:09:42PM +, Russell King - ARM Linux admin wrote: > On Sun, Jan 10, 2021 at 05:35:25PM +0100, Andrew Lunn wrote: > > On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > > > Check whether the MAC driver has implemented the get_ts_info() > > > method first, a

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Sun, Jan 10, 2021 at 05:35:25PM +0100, Andrew Lunn wrote: > On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > > Check whether the MAC driver has implemented the get_ts_info() > > method first, and call it if present. If this method returns > > -EOPNOTSUPP, defer to the phylib or d

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Thu, Jan 14, 2021 at 01:22:17PM +, Russell King - ARM Linux admin wrote: > On Thu, Jan 14, 2021 at 04:55:06AM -0800, Richard Cochran wrote: > > On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > > > This allows network drivers such as mvpp2 to use their more accurate > > > times

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Russell King - ARM Linux admin
On Thu, Jan 14, 2021 at 04:55:06AM -0800, Richard Cochran wrote: > On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > > This allows network drivers such as mvpp2 to use their more accurate > > timestamping implementation than using a less accurate implementation > > in the PHY. Network

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-14 Thread Richard Cochran
On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > This allows network drivers such as mvpp2 to use their more accurate > timestamping implementation than using a less accurate implementation > in the PHY. Network drivers can opt to defer to phylib by returning > -EOPNOTSUPP. My expec

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-13 Thread Jakub Kicinski
On Sun, 10 Jan 2021 17:35:25 +0100 Andrew Lunn wrote: > On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > > Check whether the MAC driver has implemented the get_ts_info() > > method first, and call it if present. If this method returns > > -EOPNOTSUPP, defer to the phylib or default

Re: [PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-10 Thread Andrew Lunn
On Sun, Jan 10, 2021 at 11:13:44AM +, Russell King wrote: > Check whether the MAC driver has implemented the get_ts_info() > method first, and call it if present. If this method returns > -EOPNOTSUPP, defer to the phylib or default implementation. > > This allows network drivers such as mvpp2

[PATCH net-next] net: ethtool: allow MAC drivers to override ethtool get_ts_info

2021-01-10 Thread Russell King
Check whether the MAC driver has implemented the get_ts_info() method first, and call it if present. If this method returns -EOPNOTSUPP, defer to the phylib or default implementation. This allows network drivers such as mvpp2 to use their more accurate timestamping implementation than using a les