net: miiphybb: Pass struct mii_dev directly to bb_miiphy_read/write()

Access to MDIO bus private data can be provided by both
struct mii_dev .priv member and struct bb_miiphy_bus .priv
member, use the former directly and remove .priv from the
later. Drop unused bb_miiphy_getbus(). This removes any
dependency on struct bb_miiphy_bus from the miiphybb code,
except for helper functions which will be removed later.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Paul Barker <paul.barker.ct@bp.renesas.com>
diff --git a/drivers/net/designware.c b/drivers/net/designware.c
index 2069e34..4827811 100644
--- a/drivers/net/designware.c
+++ b/drivers/net/designware.c
@@ -227,9 +227,9 @@
 #endif
 
 #if IS_ENABLED(CONFIG_BITBANGMII) && IS_ENABLED(CONFIG_DM_GPIO)
-static int dw_eth_bb_mdio_active(struct bb_miiphy_bus *bus)
+static int dw_eth_bb_mdio_active(struct mii_dev *miidev)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 	struct gpio_desc *desc = &priv->mdio_gpio;
 
 	desc->flags = 0;
@@ -238,9 +238,9 @@
 	return 0;
 }
 
-static int dw_eth_bb_mdio_tristate(struct bb_miiphy_bus *bus)
+static int dw_eth_bb_mdio_tristate(struct mii_dev *miidev)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 	struct gpio_desc *desc = &priv->mdio_gpio;
 
 	desc->flags = 0;
@@ -249,9 +249,9 @@
 	return 0;
 }
 
-static int dw_eth_bb_set_mdio(struct bb_miiphy_bus *bus, int v)
+static int dw_eth_bb_set_mdio(struct mii_dev *miidev, int v)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 
 	if (v)
 		dm_gpio_set_value(&priv->mdio_gpio, 1);
@@ -261,18 +261,18 @@
 	return 0;
 }
 
-static int dw_eth_bb_get_mdio(struct bb_miiphy_bus *bus, int *v)
+static int dw_eth_bb_get_mdio(struct mii_dev *miidev, int *v)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 
 	*v = dm_gpio_get_value(&priv->mdio_gpio);
 
 	return 0;
 }
 
-static int dw_eth_bb_set_mdc(struct bb_miiphy_bus *bus, int v)
+static int dw_eth_bb_set_mdc(struct mii_dev *miidev, int v)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 
 	if (v)
 		dm_gpio_set_value(&priv->mdc_gpio, 1);
@@ -282,9 +282,9 @@
 	return 0;
 }
 
-static int dw_eth_bb_delay(struct bb_miiphy_bus *bus)
+static int dw_eth_bb_delay(struct mii_dev *miidev)
 {
-	struct dw_eth_dev *priv = bus->priv;
+	struct dw_eth_dev *priv = miidev->priv;
 
 	udelay(priv->bb_delay);
 	return 0;