From patchwork Fri Sep 4 10:33:37 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Sperl X-Patchwork-Id: 7121261 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3F1D5BEEC1 for ; Fri, 4 Sep 2015 10:36:29 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6791E20844 for ; Fri, 4 Sep 2015 10:36:27 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9B49020842 for ; Fri, 4 Sep 2015 10:36:26 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZXoK2-00058u-Tj; Fri, 04 Sep 2015 10:34:18 +0000 Received: from 212-186-180-163.dynamic.surfer.at ([212.186.180.163] helo=cgate.sperl.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZXoJx-00055F-VS; Fri, 04 Sep 2015 10:34:15 +0000 Received: from raspcm.intern.sperl.org (account martin@sperl.org [10.10.10.41] verified) by sperl.org (CommuniGate Pro SMTP 6.1.2) with ESMTPSA id 6342759; Fri, 04 Sep 2015 10:33:50 +0000 From: kernel@martin.sperl.org To: Stephen Warren , Lee Jones , Rob Russell King , linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH] ARM: dt: bcm2835: set mmc clock to the correct value of 250MHz Date: Fri, 4 Sep 2015 10:33:37 +0000 Message-Id: <1441362818-4323-1-git-send-email-kernel@martin.sperl.org> X-Mailer: git-send-email 1.7.10.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150904_033414_217066_8928FCC8 X-CRM114-Status: UNSURE ( 6.79 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.9 (/) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Martin Sperl MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Martin Sperl This patch sets the clock speed to 250MHz to make the SD card work at the correct clock speed without overclocking by 2.5. Signed-off-by: Martin Sperl --- arch/arm/boot/dts/bcm2835.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Analysis with a logic-analyzer found that the current setting of the mmc clock at 100MHz is wrong and results in overclocking the SD-card and eMMC on the Compute Module. Exact measurements show that when 25Mhz are selected by the sdhci driver effectively 62.5MHz are used (so 2.5 times faster), which is what is expected when the clock is configured to a fixed 100MHz instead of the 250MHz that the clock is actually running at. diff --git a/arch/arm/boot/dts/bcm2835.dtsi b/arch/arm/boot/dts/bcm2835.dtsi index 301c73f..591f202 100644 --- a/arch/arm/boot/dts/bcm2835.dtsi +++ b/arch/arm/boot/dts/bcm2835.dtsi @@ -170,7 +170,7 @@ reg = <0>; #clock-cells = <0>; clock-output-names = "mmc"; - clock-frequency = <100000000>; + clock-frequency = <250000000>; }; clk_i2c: clock@1 {