From owner-svn-src-all@freebsd.org Thu Dec 1 03:34:05 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AC20EC5ED03; Thu, 1 Dec 2016 03:34:05 +0000 (UTC) (envelope-from loos@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7BC9F16AF; Thu, 1 Dec 2016 03:34:05 +0000 (UTC) (envelope-from loos@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uB13Y4Rr096021; Thu, 1 Dec 2016 03:34:04 GMT (envelope-from loos@FreeBSD.org) Received: (from loos@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id uB13Y4To096019; Thu, 1 Dec 2016 03:34:04 GMT (envelope-from loos@FreeBSD.org) Message-Id: <201612010334.uB13Y4To096019@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: loos set sender to loos@FreeBSD.org using -f From: Luiz Otavio O Souza Date: Thu, 1 Dec 2016 03:34:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r309347 - head/sys/arm/ti/cpsw X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Dec 2016 03:34:05 -0000 Author: loos Date: Thu Dec 1 03:34:04 2016 New Revision: 309347 URL: https://svnweb.freebsd.org/changeset/base/309347 Log: MDIO_PHYACCESS_ACK is only valid for read access, remove it from miibus_writereg. Reduce the DELAY() between reads while waiting for MII access. Spotted by: yongari Sponsored by: Rubicon Communications, LLC (Netgate) Modified: head/sys/arm/ti/cpsw/if_cpsw.c head/sys/arm/ti/cpsw/if_cpswvar.h Modified: head/sys/arm/ti/cpsw/if_cpsw.c ============================================================================== --- head/sys/arm/ti/cpsw/if_cpsw.c Thu Dec 1 03:27:16 2016 (r309346) +++ head/sys/arm/ti/cpsw/if_cpsw.c Thu Dec 1 03:34:04 2016 (r309347) @@ -1512,9 +1512,6 @@ cpswp_miibus_writereg(device_t dev, int return (0); } - if ((cpsw_read_4(sc->swsc, sc->phyaccess) & MDIO_PHYACCESS_ACK) == 0) - device_printf(dev, "Failed to write to PHY.\n"); - return (0); } Modified: head/sys/arm/ti/cpsw/if_cpswvar.h ============================================================================== --- head/sys/arm/ti/cpsw/if_cpswvar.h Thu Dec 1 03:27:16 2016 (r309346) +++ head/sys/arm/ti/cpsw/if_cpswvar.h Thu Dec 1 03:34:04 2016 (r309347) @@ -33,8 +33,8 @@ #define CPSW_INTR_COUNT 4 /* MII BUS */ -#define CPSW_MIIBUS_RETRIES 5 -#define CPSW_MIIBUS_DELAY 1000 +#define CPSW_MIIBUS_RETRIES 20 +#define CPSW_MIIBUS_DELAY 100 #define CPSW_MAX_ALE_ENTRIES 1024