]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
net: mvneta: Fix not always calling dev_err with a device
authorSean Anderson <seanga2@gmail.com>
Tue, 15 Sep 2020 14:44:54 +0000 (10:44 -0400)
committerTom Rini <trini@konsulko.com>
Wed, 30 Sep 2020 12:53:12 +0000 (08:53 -0400)
No need for indirection here.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Tested-by: Patrick Delaunay <patrick.delaunay@st.com>
drivers/net/mvneta.c

index 4c7d06ca40e5da1761d561334570579ea3d3c6b5..2c93fe42f7e32faea9333269cff80e8e621d6cdf 100644 (file)
@@ -1402,7 +1402,7 @@ static int mvneta_init(struct udevice *dev)
 
        err = mvneta_init2(pp);
        if (err < 0) {
-               dev_err(&pdev->dev, "can't init eth hal\n");
+               dev_err(dev, "can't init eth hal\n");
                return err;
        }
 
@@ -1410,7 +1410,7 @@ static int mvneta_init(struct udevice *dev)
 
        err = mvneta_port_power_up(pp, pp->phy_interface);
        if (err < 0) {
-               dev_err(&pdev->dev, "can't power up port\n");
+               dev_err(dev, "can't power up port\n");
                return err;
        }