Re: [net-next PATCH v1] net: phy: Move of_mdio from drivers/of to drivers/net/mdio

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 08/10/2020 15:47, Calvin Johnson wrote:
Better place for of_mdio.c is drivers/net/mdio.
Move of_mdio.c from drivers/of to drivers/net/mdio

Signed-off-by: Calvin Johnson <calvin.johnson@xxxxxxxxxxx>

In-Principle-Acked-By: Grant Likely <grant.likely@xxxxxxx>

... but I've not tested or compiled *anything*!

g.

---

  MAINTAINERS                        | 2 +-
  drivers/net/mdio/Kconfig           | 8 ++++++++
  drivers/net/mdio/Makefile          | 2 ++
  drivers/{of => net/mdio}/of_mdio.c | 0
  drivers/of/Kconfig                 | 7 -------
  drivers/of/Makefile                | 1 -
  6 files changed, 11 insertions(+), 9 deletions(-)
  rename drivers/{of => net/mdio}/of_mdio.c (100%)

diff --git a/MAINTAINERS b/MAINTAINERS
index 8ff71b1a4a99..d1b82a3a1843 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -6525,9 +6525,9 @@ F:	Documentation/devicetree/bindings/net/mdio*
  F:	Documentation/devicetree/bindings/net/qca,ar803x.yaml
  F:	Documentation/networking/phy.rst
  F:	drivers/net/mdio/
+F:	drivers/net/mdio/of_mdio.c
  F:	drivers/net/pcs/
  F:	drivers/net/phy/
-F:	drivers/of/of_mdio.c
  F:	drivers/of/of_net.c
  F:	include/dt-bindings/net/qca-ar803x.h
  F:	include/linux/*mdio*.h
diff --git a/drivers/net/mdio/Kconfig b/drivers/net/mdio/Kconfig
index 27a2a4a3d943..a10cc460d7cf 100644
--- a/drivers/net/mdio/Kconfig
+++ b/drivers/net/mdio/Kconfig
@@ -19,6 +19,14 @@ config MDIO_BUS
  	  reflects whether the mdio_bus/mdio_device code is built as a
  	  loadable module or built-in.
+config OF_MDIO
+	def_tristate PHYLIB
+	depends on OF
+	depends on PHYLIB
+	select FIXED_PHY
+	help
+	  OpenFirmware MDIO bus (Ethernet PHY) accessors
+
  if MDIO_BUS
config MDIO_DEVRES
diff --git a/drivers/net/mdio/Makefile b/drivers/net/mdio/Makefile
index 14d1beb633c9..5c498dde463f 100644
--- a/drivers/net/mdio/Makefile
+++ b/drivers/net/mdio/Makefile
@@ -1,6 +1,8 @@
  # SPDX-License-Identifier: GPL-2.0
  # Makefile for Linux MDIO bus drivers
+obj-$(CONFIG_OF_MDIO) += of_mdio.o
+
  obj-$(CONFIG_MDIO_ASPEED)		+= mdio-aspeed.o
  obj-$(CONFIG_MDIO_BCM_IPROC)		+= mdio-bcm-iproc.o
  obj-$(CONFIG_MDIO_BCM_UNIMAC)		+= mdio-bcm-unimac.o
diff --git a/drivers/of/of_mdio.c b/drivers/net/mdio/of_mdio.c
similarity index 100%
rename from drivers/of/of_mdio.c
rename to drivers/net/mdio/of_mdio.c
diff --git a/drivers/of/Kconfig b/drivers/of/Kconfig
index d91618641be6..18450437d5d5 100644
--- a/drivers/of/Kconfig
+++ b/drivers/of/Kconfig
@@ -74,13 +74,6 @@ config OF_NET
  	depends on NETDEVICES
  	def_bool y
-config OF_MDIO
-	def_tristate PHYLIB
-	depends on PHYLIB
-	select FIXED_PHY
-	help
-	  OpenFirmware MDIO bus (Ethernet PHY) accessors
-
  config OF_RESERVED_MEM
  	bool
  	depends on OF_EARLY_FLATTREE
diff --git a/drivers/of/Makefile b/drivers/of/Makefile
index 663a4af0cccd..6e1e5212f058 100644
--- a/drivers/of/Makefile
+++ b/drivers/of/Makefile
@@ -9,7 +9,6 @@ obj-$(CONFIG_OF_ADDRESS)  += address.o
  obj-$(CONFIG_OF_IRQ)    += irq.o
  obj-$(CONFIG_OF_NET)	+= of_net.o
  obj-$(CONFIG_OF_UNITTEST) += unittest.o
-obj-$(CONFIG_OF_MDIO)	+= of_mdio.o
  obj-$(CONFIG_OF_RESERVED_MEM) += of_reserved_mem.o
  obj-$(CONFIG_OF_RESOLVE)  += resolver.o
  obj-$(CONFIG_OF_OVERLAY) += overlay.o




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux