From owner-svn-src-all@FreeBSD.ORG Fri Dec 13 17:03:32 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A465A740; Fri, 13 Dec 2013 17:03:32 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8ECFD1971; Fri, 13 Dec 2013 17:03:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rBDH3WNN034438; Fri, 13 Dec 2013 17:03:32 GMT (envelope-from ian@svn.freebsd.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.7/8.14.7/Submit) id rBDH3W13034437; Fri, 13 Dec 2013 17:03:32 GMT (envelope-from ian@svn.freebsd.org) Message-Id: <201312131703.rBDH3W13034437@svn.freebsd.org> From: Ian Lepore Date: Fri, 13 Dec 2013 17:03:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r259314 - stable/10/sys/arm/freescale/imx X-SVN-Group: stable-10 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.17 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: Fri, 13 Dec 2013 17:03:32 -0000 Author: ian Date: Fri Dec 13 17:03:32 2013 New Revision: 259314 URL: http://svnweb.freebsd.org/changeset/base/259314 Log: MFC r256774: Clock divisors 0-3 correspond to dividing by 1-4, so add 1 before dividing. Modified: stable/10/sys/arm/freescale/imx/imx51_ccm.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/arm/freescale/imx/imx51_ccm.c ============================================================================== --- stable/10/sys/arm/freescale/imx/imx51_ccm.c Fri Dec 13 17:02:09 2013 (r259313) +++ stable/10/sys/arm/freescale/imx/imx51_ccm.c Fri Dec 13 17:03:32 2013 (r259314) @@ -278,8 +278,8 @@ imx51_get_clock(enum imx51_clock clk) case IMX51CLK_MAIN_BUS_CLK: freq = imx51_get_clock(IMX51CLK_MAIN_BUS_CLK_SRC); cdcr = bus_read_4(ccm_softc->res[0], CCMC_CDCR); - return freq / (cdcr & CDCR_PERIPH_CLK_DVFS_PODF_MASK) >> - CDCR_PERIPH_CLK_DVFS_PODF_SHIFT; + return freq / (1 + ((cdcr & CDCR_PERIPH_CLK_DVFS_PODF_MASK) >> + CDCR_PERIPH_CLK_DVFS_PODF_SHIFT)); case IMX51CLK_AHB_CLK_ROOT: freq = imx51_get_clock(IMX51CLK_MAIN_BUS_CLK); cbcdr = bus_read_4(ccm_softc->res[0], CCMC_CBCDR);