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=-4.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 A1C16C4338F for ; Wed, 11 Aug 2021 11:22:11 +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 60AEB60EB5 for ; Wed, 11 Aug 2021 11:22:11 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 60AEB60EB5 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=c2HmBxB2LZttU+uE7T5m3ZlyA0x9IAP+H5XBKRqqgz4=; b=p0Ev8GustNRqNR 4Ojp3mShtbDvoqhUVS6xzUigft/HPJ4pN641KJVUWHKQGEATDR1lY7EqNj5eyS8ZVCF3RVVfXCdfW pfMKmNQ+zq2p1n/u4d6Vfdj80y/vyBYk7RP3aG6MO7v/LYyxZl8n7r2Mnj4C9u0lDt1siIdfvoK2C n79llQFbkHFLRVyDHHIJVPzzHEP5TIp9BUuq4Ziqq64iVs5yDnMHWpt9vYLPwU+702xQAzJ9Cgq2Y xqHfmmGIRxxs916cum4Oh/phcn2U2Gu1KvziXxTLKPTHalETnKAKZnK7esKGQlvGPUHj6vtyiAx4j Iurbq2nZxEh0EdzfXKcQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mDmHW-006lVA-SO; Wed, 11 Aug 2021 11:20:23 +0000 Received: from mail-ua1-x92f.google.com ([2607:f8b0:4864:20::92f]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mDmHQ-006lSp-1i for linux-arm-kernel@lists.infradead.org; Wed, 11 Aug 2021 11:20:19 +0000 Received: by mail-ua1-x92f.google.com with SMTP id ay13so999364uab.5 for ; Wed, 11 Aug 2021 04:20:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=t0kEBolSkLS2sqce8sXfB33QiH70Nq/WEHar/RhDH00=; b=EXu9onjXPrdieAXb4oXgi7XDK2Cs0n7NV6W1fs65ZqHGgYhojmH+np0TMd9X9TqyuL mOnHJv7IMjvM9aW6URokLeKObx1Hr9sjULLeVyDoJV4IKgi8fwJ//B4u5gldK+Z5wFx9 BKtL5eL2UislHCHvFKd2LH1s/w/8kUDgOikyU9jhJ/2FvWAV5lYtV4zP5KAHH5VelCmZ OILdkPwbA6BPx1xP6y3Vmt5x8OAnk13uX69egwyyuj2xCe/JXUzlmQ1/WZHG02cohJit nyEOMegmP/pDz8Yx19iIhYRG2XssOk/biOMEYxoM2J5Xg5LaVzEzM6IeYbKxMX6BoUG0 DcBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=t0kEBolSkLS2sqce8sXfB33QiH70Nq/WEHar/RhDH00=; b=WabHWOCG3Fh/zNCAiGNV4ONzGK96/AsRenIKm9cacYRC6XPPUvP9j2jyziV5Y6nD3o 9OGkSvklNQ//Bi5c5ysizylnoXx/w18dCYFvRC72B5aW8wbXP5p44+4JDO869mTnJnfw eZbcXCRMXzpKX2Xqm01LrEuO5dkaIRdfmg4MLoAosLZ7rbitJ+16tuIuT1S5IoCGJ/KN +2tMWA8E0XZt+ooBi2prsjqtU3pZYRtWBDLowSkoKOU7g+Pw/UpKAjOZ60vunC7jKFXj fYOfnTown/BVsJizo1NvISU2mQ4hejABOUbkdmvSQpxB5/7E28j4VxZLd6EJ+nYT6QQT 8FrQ== X-Gm-Message-State: AOAM530XKzvjrVSx7WtfHgow81OgCJ+fnBAheqdr7PEIyWJG5KkeUfYN owLryDiWupqqRW0tCpgIoD/ov1l4rpYMP3Gy9+Rnqg== X-Google-Smtp-Source: ABdhPJzHREh3TtpeK5LboogIOTf9B16ur3hdtF1iwFqcdwjhPQLqbrAfGLqvXhyblELiy1U/5s3uTaTrZeYTfryBy8o= X-Received: by 2002:ab0:7014:: with SMTP id k20mr10843046ual.9.1628680814267; Wed, 11 Aug 2021 04:20:14 -0700 (PDT) MIME-Version: 1.0 References: <20210806152146.16107-1-semen.protsenko@linaro.org> <20210806152146.16107-8-semen.protsenko@linaro.org> <3add6f87-7293-e1ae-8f9e-c69e9de18cf5@canonical.com> In-Reply-To: From: Sam Protsenko Date: Wed, 11 Aug 2021 14:20:02 +0300 Message-ID: Subject: Re: [PATCH v2 7/8] clk: samsung: Add Exynos850 clock driver stub To: Sylwester Nawrocki Cc: Krzysztof Kozlowski , Chanwoo Choi , Linus Walleij , Tomasz Figa , =?UTF-8?Q?Pawe=C5=82_Chmiel?= , Marc Zyngier , Rob Herring , Stephen Boyd , Michael Turquette , Jiri Slaby , Greg Kroah-Hartman , Charles Keepax , Ryu Euiyoul , Tom Gall , Sumit Semwal , John Stultz , Amit Pundir , devicetree , linux-arm Mailing List , linux-clk , "open list:GPIO SUBSYSTEM" , Linux Kernel Mailing List , Linux Samsung SOC , "open list:SERIAL DRIVERS" X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210811_042016_145208_A2F7F62F X-CRM114-Status: GOOD ( 30.31 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, 10 Aug 2021 at 10:55, Sylwester Nawrocki wrote: > > On 09.08.2021 21:48, Sam Protsenko wrote: > >>> +/* Will be extracted to bindings header once proper clk driver is implemented */ > >>> +#define OSCCLK 1 > >>> +#define DOUT_UART 2 > >>> +#define CLK_NR_CLKS 3 > >>> + > >>> +/* Fixed rate clocks generated outside the SoC */ > >>> +static struct samsung_fixed_rate_clock exynos850_fixed_rate_ext_clks[] __initdata = { > >>> + FRATE(OSCCLK, "fin_pll", NULL, 0, 26000000), > >>> +}; > >>> + > >>> +/* > >>> + * Model the UART clock as a fixed-rate clock for now, to make serial driver > >>> + * work. This clock is already configured in the bootloader. > >>> + */ > >>> +static const struct samsung_fixed_rate_clock exynos850_peri_clks[] __initconst = { > >>> + FRATE(DOUT_UART, "DOUT_UART", NULL, 0, 200000000), > >>> +}; > >>> + > >>> +static const struct of_device_id ext_clk_match[] __initconst = { > >>> + { .compatible = "samsung,exynos850-oscclk" }, > >> > >> One more thing - I am not sure anymore if this is correct. AFAIR, we > >> wanted to drop compatibles for external clocks. > >> > > I'll remove oscclk from the clock driver and device tree. It's not > > needed right now anyway, as that driver is just a stub. > > > > But I'd still like to know the proper way to define external clocks. I > > can see that in exynos7.dtsi and exynos5433.dtsi there is just regular > > fixed clock defined for "oscclk" (or "fin_pll"), and then that clock > > is referenced in corresponding clock driver by its > > 'clock-output-names' property. I guess that approach is the > > recommended one? > > Yes, we should use generic "fixed-clock" in DT to model the external > root clock. Registering the external clock from within the CMU driver > is a legacy method that predates generic "fixed-clock" and should be > avoided. > Thanks for confirming this. I'll go with generic fixed clock in my clock patch series then. > That said I think this temporary stub driver is not needed at all, > you could well define a fixed clock in DT and reference it in the UART > node, as Krzysztof suggested. > Ok, I'll remove the stub clock driver in v3. Using fixed clock in device tree for serial seems to work fine. > -- > Regards, > Sylwester _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel