diff mbox series

[v2,23/46] net: sunxi: Fix not calling dev_xxx with a device

Message ID 20200915144522.509493-24-seanga2@gmail.com
State Accepted
Commit e2f74215227e971491bce6860771fd2736b4cfc8
Delegated to: Tom Rini
Headers show
Series dm: Print device name in dev_xxx like Linux | expand

Commit Message

Sean Anderson Sept. 15, 2020, 2:44 p.m. UTC
There's no dev to log with, so pass the device along with the priv data.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
---

Changes in v2:
- New

 drivers/net/sunxi_emac.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Comments

Simon Glass Sept. 17, 2020, 1:10 a.m. UTC | #1
On Tue, 15 Sep 2020 at 08:46, Sean Anderson <seanga2@gmail.com> wrote:
>
> There's no dev to log with, so pass the device along with the priv data.
>
> Signed-off-by: Sean Anderson <seanga2@gmail.com>
> ---
>
> Changes in v2:
> - New
>
>  drivers/net/sunxi_emac.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>

Reviewed-by: Simon Glass <sjg@chromium.org>
diff mbox series

Patch

diff --git a/drivers/net/sunxi_emac.c b/drivers/net/sunxi_emac.c
index df18ecc064..8e66ce2461 100644
--- a/drivers/net/sunxi_emac.c
+++ b/drivers/net/sunxi_emac.c
@@ -505,7 +505,8 @@  static int _sunxi_emac_eth_send(struct emac_eth_dev *priv, void *packet,
 	return 0;
 }
 
-static int sunxi_emac_board_setup(struct emac_eth_dev *priv)
+static int sunxi_emac_board_setup(struct udevice *dev,
+				  struct emac_eth_dev *priv)
 {
 	struct sunxi_sramc_regs *sram =
 		(struct sunxi_sramc_regs *)SUNXI_SRAMC_BASE;
@@ -576,7 +577,7 @@  static int sunxi_emac_eth_probe(struct udevice *dev)
 		return ret;
 	}
 
-	ret = sunxi_emac_board_setup(priv);
+	ret = sunxi_emac_board_setup(dev, priv);
 	if (ret)
 		return ret;