All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
@ 2022-01-04 12:05 ` Daniel Golle
  0 siblings, 0 replies; 6+ messages in thread
From: Daniel Golle @ 2022-01-04 12:05 UTC (permalink / raw)
  To: linux-mediatek, netdev, linux-arm-kernel, linux-kernel
  Cc: Felix Fietkau, John Crispin, Sean Wang, Mark Lee,
	David S. Miller, Jakub Kicinski, Matthias Brugger, Russell King,
	Andrew Lunn, Heiner Kallweit

Rework value and type of mdio read and write functions in mtk_eth_soc
and generally clean up and unify both functions.
Then add support to access Clause 45 phy registers, using newly
introduced helper macros added by a patch Russell King has suggested
in a reply to an earlier version of this series [1].

All three commits are tested on the Bananapi BPi-R64 board having
MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
clause 45 MDIO.

[1]: https://lore.kernel.org/netdev/Ycr5Cna76eg2B0An@shell.armlinux.org.uk/

v12: replace 'ret != 0' forgotten from an earlier iteration with
     'ret < 0' checks of mtk_mdio_busy_wait return value (purely
     cosmetical as anyway either 0 or -ETIMEDOUT is returned, sorry
     for the noise)
v11: also address return value of mtk_mdio_busy_wait
v10: correct order of SoB lines in 2/3, change patch order in series
v9: improved formatting and Cc missing maintainer
v8: add patch from Russel King, switch to bitfield helper macros
v7: remove unneeded variables and order OR-ed call parameters
v6: further clean up functions and more cleanly separate patches
v5: fix wrong variable name in first patch covered by follow-up patch
v4: clean-up return values and types, split into two commits
v3: return -1 instead of 0xffff on error in _mtk_mdio_write
v2: use MII_DEVADDR_C45_SHIFT and MII_REGADDR_C45_MASK to extract
    device id and register address. Unify read and write functions to
    have identical types and parameter names where possible as we are
    anyway already replacing both function bodies.

Daniel Golle (2):
  net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
  net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access

Russell King (Oracle) (1):
  net: mdio: add helpers to extract clause 45 regad and devad fields

 drivers/net/ethernet/mediatek/mtk_eth_soc.c | 101 +++++++++++++++-----
 drivers/net/ethernet/mediatek/mtk_eth_soc.h |  19 +++-
 include/linux/mdio.h                        |  12 +++
 3 files changed, 102 insertions(+), 30 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
@ 2022-01-04 12:05 ` Daniel Golle
  0 siblings, 0 replies; 6+ messages in thread
From: Daniel Golle @ 2022-01-04 12:05 UTC (permalink / raw)
  To: linux-mediatek, netdev, linux-arm-kernel, linux-kernel
  Cc: Felix Fietkau, John Crispin, Sean Wang, Mark Lee,
	David S. Miller, Jakub Kicinski, Matthias Brugger, Russell King,
	Andrew Lunn, Heiner Kallweit

Rework value and type of mdio read and write functions in mtk_eth_soc
and generally clean up and unify both functions.
Then add support to access Clause 45 phy registers, using newly
introduced helper macros added by a patch Russell King has suggested
in a reply to an earlier version of this series [1].

All three commits are tested on the Bananapi BPi-R64 board having
MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
clause 45 MDIO.

[1]: https://lore.kernel.org/netdev/Ycr5Cna76eg2B0An@shell.armlinux.org.uk/

v12: replace 'ret != 0' forgotten from an earlier iteration with
     'ret < 0' checks of mtk_mdio_busy_wait return value (purely
     cosmetical as anyway either 0 or -ETIMEDOUT is returned, sorry
     for the noise)
v11: also address return value of mtk_mdio_busy_wait
v10: correct order of SoB lines in 2/3, change patch order in series
v9: improved formatting and Cc missing maintainer
v8: add patch from Russel King, switch to bitfield helper macros
v7: remove unneeded variables and order OR-ed call parameters
v6: further clean up functions and more cleanly separate patches
v5: fix wrong variable name in first patch covered by follow-up patch
v4: clean-up return values and types, split into two commits
v3: return -1 instead of 0xffff on error in _mtk_mdio_write
v2: use MII_DEVADDR_C45_SHIFT and MII_REGADDR_C45_MASK to extract
    device id and register address. Unify read and write functions to
    have identical types and parameter names where possible as we are
    anyway already replacing both function bodies.

Daniel Golle (2):
  net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
  net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access

Russell King (Oracle) (1):
  net: mdio: add helpers to extract clause 45 regad and devad fields

 drivers/net/ethernet/mediatek/mtk_eth_soc.c | 101 +++++++++++++++-----
 drivers/net/ethernet/mediatek/mtk_eth_soc.h |  19 +++-
 include/linux/mdio.h                        |  12 +++
 3 files changed, 102 insertions(+), 30 deletions(-)

-- 
2.34.1


_______________________________________________
Linux-mediatek mailing list
Linux-mediatek@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-mediatek

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
@ 2022-01-04 12:05 ` Daniel Golle
  0 siblings, 0 replies; 6+ messages in thread
From: Daniel Golle @ 2022-01-04 12:05 UTC (permalink / raw)
  To: linux-mediatek, netdev, linux-arm-kernel, linux-kernel
  Cc: Felix Fietkau, John Crispin, Sean Wang, Mark Lee,
	David S. Miller, Jakub Kicinski, Matthias Brugger, Russell King,
	Andrew Lunn, Heiner Kallweit

Rework value and type of mdio read and write functions in mtk_eth_soc
and generally clean up and unify both functions.
Then add support to access Clause 45 phy registers, using newly
introduced helper macros added by a patch Russell King has suggested
in a reply to an earlier version of this series [1].

All three commits are tested on the Bananapi BPi-R64 board having
MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
clause 45 MDIO.

[1]: https://lore.kernel.org/netdev/Ycr5Cna76eg2B0An@shell.armlinux.org.uk/

v12: replace 'ret != 0' forgotten from an earlier iteration with
     'ret < 0' checks of mtk_mdio_busy_wait return value (purely
     cosmetical as anyway either 0 or -ETIMEDOUT is returned, sorry
     for the noise)
v11: also address return value of mtk_mdio_busy_wait
v10: correct order of SoB lines in 2/3, change patch order in series
v9: improved formatting and Cc missing maintainer
v8: add patch from Russel King, switch to bitfield helper macros
v7: remove unneeded variables and order OR-ed call parameters
v6: further clean up functions and more cleanly separate patches
v5: fix wrong variable name in first patch covered by follow-up patch
v4: clean-up return values and types, split into two commits
v3: return -1 instead of 0xffff on error in _mtk_mdio_write
v2: use MII_DEVADDR_C45_SHIFT and MII_REGADDR_C45_MASK to extract
    device id and register address. Unify read and write functions to
    have identical types and parameter names where possible as we are
    anyway already replacing both function bodies.

Daniel Golle (2):
  net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
  net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access

Russell King (Oracle) (1):
  net: mdio: add helpers to extract clause 45 regad and devad fields

 drivers/net/ethernet/mediatek/mtk_eth_soc.c | 101 +++++++++++++++-----
 drivers/net/ethernet/mediatek/mtk_eth_soc.h |  19 +++-
 include/linux/mdio.h                        |  12 +++
 3 files changed, 102 insertions(+), 30 deletions(-)

-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
  2022-01-04 12:05 ` Daniel Golle
  (?)
@ 2022-01-05 11:30   ` patchwork-bot+netdevbpf
  -1 siblings, 0 replies; 6+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-01-05 11:30 UTC (permalink / raw)
  To: Daniel Golle
  Cc: linux-mediatek, netdev, linux-arm-kernel, linux-kernel, nbd,
	john, sean.wang, Mark-MC.Lee, davem, kuba, matthias.bgg, linux,
	andrew, hkallweit1

Hello:

This series was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Tue, 4 Jan 2022 12:05:51 +0000 you wrote:
> Rework value and type of mdio read and write functions in mtk_eth_soc
> and generally clean up and unify both functions.
> Then add support to access Clause 45 phy registers, using newly
> introduced helper macros added by a patch Russell King has suggested
> in a reply to an earlier version of this series [1].
> 
> All three commits are tested on the Bananapi BPi-R64 board having
> MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
> Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
> clause 45 MDIO.
> 
> [...]

Here is the summary with links:
  - [v12,1/3] net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
    https://git.kernel.org/netdev/net-next/c/eda80b249df7
  - [v12,2/3] net: mdio: add helpers to extract clause 45 regad and devad fields
    https://git.kernel.org/netdev/net-next/c/c6af53f038aa
  - [v12,3/3] net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access
    https://git.kernel.org/netdev/net-next/c/e2e7f6e29c99

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
@ 2022-01-05 11:30   ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 6+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-01-05 11:30 UTC (permalink / raw)
  To: Daniel Golle
  Cc: linux-mediatek, netdev, linux-arm-kernel, linux-kernel, nbd,
	john, sean.wang, Mark-MC.Lee, davem, kuba, matthias.bgg, linux,
	andrew, hkallweit1

Hello:

This series was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Tue, 4 Jan 2022 12:05:51 +0000 you wrote:
> Rework value and type of mdio read and write functions in mtk_eth_soc
> and generally clean up and unify both functions.
> Then add support to access Clause 45 phy registers, using newly
> introduced helper macros added by a patch Russell King has suggested
> in a reply to an earlier version of this series [1].
> 
> All three commits are tested on the Bananapi BPi-R64 board having
> MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
> Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
> clause 45 MDIO.
> 
> [...]

Here is the summary with links:
  - [v12,1/3] net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
    https://git.kernel.org/netdev/net-next/c/eda80b249df7
  - [v12,2/3] net: mdio: add helpers to extract clause 45 regad and devad fields
    https://git.kernel.org/netdev/net-next/c/c6af53f038aa
  - [v12,3/3] net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access
    https://git.kernel.org/netdev/net-next/c/e2e7f6e29c99

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



_______________________________________________
Linux-mediatek mailing list
Linux-mediatek@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-mediatek

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45
@ 2022-01-05 11:30   ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 6+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-01-05 11:30 UTC (permalink / raw)
  To: Daniel Golle
  Cc: linux-mediatek, netdev, linux-arm-kernel, linux-kernel, nbd,
	john, sean.wang, Mark-MC.Lee, davem, kuba, matthias.bgg, linux,
	andrew, hkallweit1

Hello:

This series was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Tue, 4 Jan 2022 12:05:51 +0000 you wrote:
> Rework value and type of mdio read and write functions in mtk_eth_soc
> and generally clean up and unify both functions.
> Then add support to access Clause 45 phy registers, using newly
> introduced helper macros added by a patch Russell King has suggested
> in a reply to an earlier version of this series [1].
> 
> All three commits are tested on the Bananapi BPi-R64 board having
> MediaTek MT7531BE DSA gigE switch using clause 22 MDIO and
> Ubiquiti UniFi 6 LR access point having Aquantia AQR112C PHY using
> clause 45 MDIO.
> 
> [...]

Here is the summary with links:
  - [v12,1/3] net: ethernet: mtk_eth_soc: fix return values and refactor MDIO ops
    https://git.kernel.org/netdev/net-next/c/eda80b249df7
  - [v12,2/3] net: mdio: add helpers to extract clause 45 regad and devad fields
    https://git.kernel.org/netdev/net-next/c/c6af53f038aa
  - [v12,3/3] net: ethernet: mtk_eth_soc: implement Clause 45 MDIO access
    https://git.kernel.org/netdev/net-next/c/e2e7f6e29c99

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-01-05 11:31 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-04 12:05 [PATCH v12 0/3] net: ethernet: mtk_eth_soc: refactoring and Clause 45 Daniel Golle
2022-01-04 12:05 ` Daniel Golle
2022-01-04 12:05 ` Daniel Golle
2022-01-05 11:30 ` patchwork-bot+netdevbpf
2022-01-05 11:30   ` patchwork-bot+netdevbpf
2022-01-05 11:30   ` patchwork-bot+netdevbpf

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.