From patchwork Wed Oct 4 15:40:57 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 9984923 X-Patchwork-Delegate: horms@verge.net.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 164BE60291 for ; Wed, 4 Oct 2017 15:41:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0747F28B4A for ; Wed, 4 Oct 2017 15:41:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F030628B4D; Wed, 4 Oct 2017 15:41:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 408B228B61 for ; Wed, 4 Oct 2017 15:41:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752448AbdJDPlN (ORCPT ); Wed, 4 Oct 2017 11:41:13 -0400 Received: from relay4-d.mail.gandi.net ([217.70.183.196]:58153 "EHLO relay4-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752514AbdJDPlM (ORCPT ); Wed, 4 Oct 2017 11:41:12 -0400 Received: from w540.lan (unknown [IPv6:2001:b07:6442:1ac4:2c78:dee8:2211:55b1]) (Authenticated sender: jacopo@jmondi.org) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id 8D0FC17209F; Wed, 4 Oct 2017 17:41:06 +0200 (CEST) From: Jacopo Mondi To: horms@verge.net.au, geert@linux-m68k.org, magnus.damm@gmail.com, robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk Cc: Jacopo Mondi , linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] arm: dts: gr-peach: Reduce extal_clk resolution Date: Wed, 4 Oct 2017 17:40:57 +0200 Message-Id: <1507131657-6414-1-git-send-email-jacopo+renesas@jmondi.org> X-Mailer: git-send-email 2.7.4 Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The system clock described by extal_clk is reported to have a frequency of 13.333 Mhz and is correctly described by gr-peach device tree. However, when enabling a RIIC device the following error is reported by drivers/i2c/busses/i2c-riic.c "invalid parent clk (33332500). Must be 33325000Hz" As RIIC devices have a clock source obtained by dividing by 12 the system clock, the resulting value is not accepted by the driver (which clearly states not to support any frequency except the reported 33325000Hz one). Hence, reduce the system clock accuracy to a value which makes frequencies obtained through division accepted by RIIC driver. Please note that other r7s72100 boards, such as Genmai, report the same "reduced accuracy" frequency, even if their external clock sources are effectively 13.333Mhz as gr-peach one. Signed-off-by: Jacopo Mondi --- arch/arm/boot/dts/r7s72100-gr-peach.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.7.4 diff --git a/arch/arm/boot/dts/r7s72100-gr-peach.dts b/arch/arm/boot/dts/r7s72100-gr-peach.dts index a1c5e88..20309ac 100644 --- a/arch/arm/boot/dts/r7s72100-gr-peach.dts +++ b/arch/arm/boot/dts/r7s72100-gr-peach.dts @@ -71,7 +71,7 @@ }; &extal_clk { - clock-frequency = <13333000>; + clock-frequency = <13330000>; }; &usb_x1_clk {