Message ID | 1548700381-22376-7-git-send-email-jorge.ramirez-ortiz@linaro.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B083F1874 for <patchwork-linux-arm@patchwork.kernel.org>; Mon, 28 Jan 2019 18:35:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9D77C2C04A for <patchwork-linux-arm@patchwork.kernel.org>; Mon, 28 Jan 2019 18:35:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 918B82C05F; Mon, 28 Jan 2019 18:35:26 +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=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 392AE2C04A for <patchwork-linux-arm@patchwork.kernel.org>; Mon, 28 Jan 2019 18:35:26 +0000 (UTC) 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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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=32DkpEKRio+gKTrxpbQENfH/+eRSG3dKdxbTtshLLmU=; b=qpLBdKq+IuKf/zcjvF//Or7YD2 A8m8g7x/3pOH2Dqhle4gQbm6Gs+Ng3PwCQON1rWDeJqScrJtOeISVTFvmBGkgJ7fO7BKblQuRj7mc PrCe+qolOZU6i3CYRVyHApAog3ak1nrewKQ8jiM0J7swM1TcJLaDgYgENKQjThaLErCuAD4oqXs7/ zTDNqp0Ultr0iJi/jgBffhYLC5DViubBh2QkQPW6n1QGbKJezZY68ANvm5W1W6p8l/cuRaIuUq+Sz aBVnICh7FV3HW9jM9APhwrLD8Wp3jkJp3neAF4QiPUFgzL9hmQPq0FPnexfm1wugiSAcyiXxpyKfC m0ozXoFg==; 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 1goBki-0008QB-CC; Mon, 28 Jan 2019 18:35:24 +0000 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1goBiq-0005fq-Bw for linux-arm-kernel@lists.infradead.org; Mon, 28 Jan 2019 18:33:34 +0000 Received: by mail-wm1-x342.google.com with SMTP id n190so15131965wmd.0 for <linux-arm-kernel@lists.infradead.org>; Mon, 28 Jan 2019 10:33:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=CrsB9vDQWUxmYDFtafFb8lMIaGmRCz/1Apw6ozfisK4=; b=KhRO5+csN6b8B+mnXc+NAwS26Oh+divVSo7QhSO3rViTZsfX0dTqWyofGc7paL1I+9 YmjqT4gyn4WWHjSJ2KHFD9EVU19issse0zOzuDZq+GpG8ewfA9hfWkLO/h4AOXwezu78 f/9cKm4qgduRmD5A5un53ljNDnpsg2bd+AxT4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=CrsB9vDQWUxmYDFtafFb8lMIaGmRCz/1Apw6ozfisK4=; b=oR5pO4vOk5+rUUZOjNbuGGNsOMsLLD7ITbnpfHAqbsOQhr8PhNRGYW/wJ9ELPMcmAi slyJxQHLMzDLGqHgmAJ6zNPp7xxDWTh1HRkOlrGPnfN1mtqvY5jx/ClHC+mLCdTnrJy8 oau9A2kmJj1b3lKC7lcj6xOSrCb53LWVjOAxKhMvsJhwfxhuSPS6SiSKibUvhi4HYLa1 oY7++4KDwMWdyLD1OBs8VRzvdQOgaR4v4yrRA64NK6JlHms0/BPXjRitg0pVmaXnOEfK d8JeBrs+m266z7DKGP/rBld0H/RDl/2bT0G+gmKc5G1QrDXbL1jmShBgM57Use94bE8b Yemw== X-Gm-Message-State: AJcUukcoJmO7EFopqgCsUiVb4s2yAkggZbEIijT36+xRhHCLTjxMwZAY CKttTYKWyGhCfO0X3ZnNkK3HPQ== X-Google-Smtp-Source: ALg8bN5e+//cVztkL1BiaB2dZA1ZoazVcMiftOg308Qtn/CxK5rzHIza9kn/nUZIMqAIDiibN6IchQ== X-Received: by 2002:a1c:5dd1:: with SMTP id r200mr18719376wmb.93.1548700407005; Mon, 28 Jan 2019 10:33:27 -0800 (PST) Received: from localhost.localdomain (233.red-81-47-145.staticip.rima-tde.net. [81.47.145.233]) by smtp.gmail.com with ESMTPSA id l19sm270082wme.21.2019.01.28.10.33.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:26 -0800 (PST) From: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org> To: jorge.ramirez-ortiz@linaro.org, sboyd@kernel.org, bjorn.andersson@linaro.org, andy.gross@linaro.org, david.brown@linaro.org, jassisinghbrar@gmail.com, mark.rutland@arm.com, mturquette@baylibre.com, robh+dt@kernel.org, will.deacon@arm.com, arnd@arndb.de, horms+renesas@verge.net.au, heiko@sntech.de, sibis@codeaurora.org, enric.balletbo@collabora.com, jagan@amarulasolutions.com, olof@lixom.net Subject: [PATCH v2 06/14] clk: qcom: hfpll: get parent clock names from DT Date: Mon, 28 Jan 2019 19:32:53 +0100 Message-Id: <1548700381-22376-7-git-send-email-jorge.ramirez-ortiz@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1548700381-22376-1-git-send-email-jorge.ramirez-ortiz@linaro.org> References: <1548700381-22376-1-git-send-email-jorge.ramirez-ortiz@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190128_103328_896770_DB41F1E6 X-CRM114-Status: GOOD ( 13.50 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Cc: devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org, linux-kernel@vger.kernel.org, amit.kucheria@linaro.org, linux-clk@vger.kernel.org, vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
Support CPU frequency scaling on QCS404
|
expand
|
diff --git a/drivers/clk/qcom/hfpll.c b/drivers/clk/qcom/hfpll.c index a6de7101..87b7f46 100644 --- a/drivers/clk/qcom/hfpll.c +++ b/drivers/clk/qcom/hfpll.c @@ -52,6 +52,7 @@ static int qcom_hfpll_probe(struct platform_device *pdev) void __iomem *base; struct regmap *regmap; struct clk_hfpll *h; + struct clk *pclk; struct clk_init_data init = { .parent_names = (const char *[]){ "xo" }, .num_parents = 1, @@ -75,6 +76,13 @@ static int qcom_hfpll_probe(struct platform_device *pdev) 0, &init.name)) return -ENODEV; + /* get parent clock from device tree (optional) */ + pclk = devm_clk_get(dev, "xo"); + if (!IS_ERR(pclk)) + init.parent_names = (const char *[]){ __clk_get_name(pclk) }; + else if (PTR_ERR(pclk) == -EPROBE_DEFER) + return -EPROBE_DEFER; + h->d = &hdata; h->clkr.hw.init = &init; spin_lock_init(&h->lock);