Date: Sat, 6 May 2017 06:07:44 +0000 (UTC) From: Adrian Chadd <adrian@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r317869 - head/sys/dev/etherswitch/e6000sw Message-ID: <201705060607.v4667ics082851@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: adrian Date: Sat May 6 06:07:44 2017 New Revision: 317869 URL: https://svnweb.freebsd.org/changeset/base/317869 Log: [etherswitch] [e6000sw] fix compile issue under clang/arm Submitted by: Hiroki Mori <yamori813@yahoo.co.jp> Approved by: mizhka Differential Revision: https://reviews.freebsd.org/D10563 Modified: head/sys/dev/etherswitch/e6000sw/e6060sw.c Modified: head/sys/dev/etherswitch/e6000sw/e6060sw.c ============================================================================== --- head/sys/dev/etherswitch/e6000sw/e6060sw.c Sat May 6 06:06:11 2017 (r317868) +++ head/sys/dev/etherswitch/e6000sw/e6060sw.c Sat May 6 06:07:44 2017 (r317869) @@ -169,6 +169,7 @@ e6060sw_probe(device_t dev) sc = device_get_softc(dev); bzero(sc, sizeof(*sc)); + devid = 0; for (i = 0; i < 2; ++i) { data = MDIO_READREG(device_get_parent(dev), CORE_REGISTER + i * 0x10, SWITCH_ID); @@ -184,8 +185,6 @@ e6060sw_probe(device_t dev) break; } } - if (i == 2) - return (ENXIO); if (devid == E6060) devname = "88E6060"; @@ -193,6 +192,9 @@ e6060sw_probe(device_t dev) devname = "88E6063"; else if (devid == E6065) devname = "88E6065"; + else + return (ENXIO); + sprintf(desc, "Marvell %s MDIO switch driver at 0x%02x", devname, sc->smi_offset); device_set_desc_copy(dev, desc);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201705060607.v4667ics082851>