From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 748DEC10F0E for ; Fri, 12 Apr 2019 12:21:34 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 468FA2077C for ; Fri, 12 Apr 2019 12:21:34 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="NK0K4pC7" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 468FA2077C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=sntech.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=7TE1AhjWgkCWZJW5ICHxCwrmXCo0siZbM/Ivoy9SuU0=; b=NK0K4pC7SQ+1RM QMOsa8QsUedEKcqFOdvfgwbmFkcqwKPufZWoyFJBUCHpRWBuUmVgO4UHv7hgAbTUBA6kIPQQcoMm8 E0WSmIWcaIv7ze6vFXjYGGsGfDZEIRn1y8ZLm8eJc6wcHHNlhAQKLtX0BotvZIwpwu4Qj7ptu/4t+ iLeNADS7+p2oq+yUC1st5Es5PuAtmZ7d371v3cELT4sMZFAJwm/0xhgnOw35cFaKDdYG2MQhsKayT VeMKoE36fAtrvdsc300G0LH1+4fccGWgzYRbrMPmR41PtrvwTNB8oJXf6znt67gLroBSfb+aFRQfu smtL+XqPMPHbocOe3tNA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hEvBU-0006cw-Ak; Fri, 12 Apr 2019 12:21:32 +0000 Received: from gloria.sntech.de ([185.11.138.130]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hEvBR-0006cZ-DR; Fri, 12 Apr 2019 12:21:31 +0000 Received: from ip5f5a6320.dynamic.kabel-deutschland.de ([95.90.99.32] helo=diego.localnet) by gloria.sntech.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hEvBL-0005TL-57; Fri, 12 Apr 2019 14:21:23 +0200 From: Heiko =?ISO-8859-1?Q?St=FCbner?= To: Christoph =?ISO-8859-1?Q?M=FCllner?= Subject: Re: [PATCH v1 1/6] clk: rockchip: Add supprot to limit input rate for fractional divider Date: Fri, 12 Apr 2019 14:21:22 +0200 Message-ID: <3395739.hcHkC3K37q@diego> In-Reply-To: <818a6e0a-d99b-7350-9c4a-9e0a0d12122a@theobroma-systems.com> References: <1554284549-24916-1-git-send-email-zhangqing@rock-chips.com> <8338364.h4JqnAax9Z@diego> <818a6e0a-d99b-7350-9c4a-9e0a0d12122a@theobroma-systems.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190412_052129_610827_69108AC5 X-CRM114-Status: GOOD ( 17.95 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: huangtao@rock-chips.com, xxx@rock-chips.com, xf@rock-chips.com, sboyd@kernel.org, mturquette@baylibre.com, Elaine Zhang , linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, Finley Xiao , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Christoph, Am Freitag, 12. April 2019, 14:12:52 CEST schrieb Christoph M=FCllner: > On 12.04.19 13:52, Heiko St=FCbner wrote: > > Am Mittwoch, 3. April 2019, 11:42:24 CEST schrieb Elaine Zhang: > >> From: Finley Xiao > >> > >> From Rockchips fractional divider usage, some clocks can be generated > >> by fractional divider, but the input clock frequency of fractional > >> divider should be less than a specified value. > >> > >> Signed-off-by: Finley Xiao > >> Signed-off-by: Elaine Zhang > > = > > can you tell me where these maximum input values come from? > > = > > I talked to Christoph from Theobroma (Cc'ed) last week and he mentioned > > that they're using the fractional divider with a higher input frequency > > to create a very specific frequency [some details are gone from my memo= ry > > though] they can't get otherwise. > > = > > So I really don't want to break their working setup by introducing barr= iers > > that are not strictly necessary. > > = > > @Christoph: can you describe the bits from your fractional setup that > > I've forgotten please? > = > We need to set the I2S0 clock to 24.56 MHz. > = > When restricting the input frequency to a maximum of 600 Mhz, > we could use the integer divider to get 400 Mhz (dividing by 2). > However, with the 400 Mhz as input to the frac divider, > we run into the problem, that the maximum possible output frequency > is 20 MHz (there is another restriction which states that the > fraction input : output frequency must be >=3D 20). just for clarification, what is the current input frequency you already use sucessfully? Heiko > > = > >> diff --git a/drivers/clk/rockchip/clk-px30.c b/drivers/clk/rockchip/cl= k-px30.c > >> index 601a77f1af78..ccabce35580b 100644 > >> --- a/drivers/clk/rockchip/clk-px30.c > >> +++ b/drivers/clk/rockchip/clk-px30.c > >> @@ -21,6 +21,7 @@ > >> #include "clk.h" > >> = > >> #define PX30_GRF_SOC_STATUS0 0x480 > >> +#define PX30_FRAC_MAX_PRATE 600000000 > > = > > = > >> diff --git a/drivers/clk/rockchip/clk-rk3368.c b/drivers/clk/rockchip/= clk-rk3368.c > >> index 7c4d242f19c1..67c2da5e7d61 100644 > >> --- a/drivers/clk/rockchip/clk-rk3368.c > >> +++ b/drivers/clk/rockchip/clk-rk3368.c > >> @@ -20,6 +20,9 @@ > >> #include "clk.h" > >> = > >> #define RK3368_GRF_SOC_STATUS0 0x480 > >> +#define RK3368_I2S_FRAC_MAX_PRATE 600000000 > >> +#define RK3368_UART_FRAC_MAX_PRATE 600000000 > >> +#define RK3368_SPDIF_FRAC_MAX_PRATE 600000000 > > = > >> diff --git a/drivers/clk/rockchip/clk-rk3399.c b/drivers/clk/rockchip/= clk-rk3399.c > >> index 5a628148f3f0..1d81382bd3e0 100644 > >> --- a/drivers/clk/rockchip/clk-rk3399.c > >> +++ b/drivers/clk/rockchip/clk-rk3399.c > >> @@ -21,6 +21,12 @@ > >> #include > >> #include "clk.h" > >> = > >> +#define RK3399_I2S_FRAC_MAX_PRATE 600000000 > >> +#define RK3399_UART_FRAC_MAX_PRATE 600000000 > >> +#define RK3399_SPDIF_FRAC_MAX_PRATE 600000000 > >> +#define RK3399_VOP_FRAC_MAX_PRATE 600000000 > >> +#define RK3399_WIFI_FRAC_MAX_PRATE 600000000 > >> + > > = > > = > > = > = _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel