Date: Fri, 20 Nov 2020 11:29:20 +0000 (UTC) From: Emmanuel Vadot <manu@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r367882 - head/sys/dev/dwc Message-ID: <202011201129.0AKBTKRI090009@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: manu Date: Fri Nov 20 11:29:20 2020 New Revision: 367882 URL: https://svnweb.freebsd.org/changeset/base/367882 Log: if_dwc: dwc_get_hwaddr cannot fail, change return to void No functional changes intended Modified: head/sys/dev/dwc/if_dwc.c Modified: head/sys/dev/dwc/if_dwc.c ============================================================================== --- head/sys/dev/dwc/if_dwc.c Fri Nov 20 11:29:00 2020 (r367881) +++ head/sys/dev/dwc/if_dwc.c Fri Nov 20 11:29:20 2020 (r367882) @@ -1153,7 +1153,7 @@ out: return (0); } -static int +static void dwc_get_hwaddr(struct dwc_softc *sc, uint8_t *hwaddr) { uint32_t hi, lo, rnd; @@ -1185,8 +1185,6 @@ dwc_get_hwaddr(struct dwc_softc *sc, uint8_t *hwaddr) hwaddr[4] = rnd >> 8; hwaddr[5] = rnd >> 0; } - - return (0); } #define GPIO_ACTIVE_LOW 1 @@ -1336,10 +1334,7 @@ dwc_attach(device_t dev) } /* Read MAC before reset */ - if (dwc_get_hwaddr(sc, macaddr)) { - device_printf(sc->dev, "can't get mac\n"); - return (ENXIO); - } + dwc_get_hwaddr(sc, macaddr); /* Reset the PHY if needed */ if (dwc_reset(dev) != 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202011201129.0AKBTKRI090009>