From patchwork Mon Jan 28 18:32:48 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156861 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3748474jaa; Mon, 28 Jan 2019 10:33:24 -0800 (PST) X-Google-Smtp-Source: ALg8bN4GXxVadR1bRXx375HOcfQz83bsaEqHPFD7gmyAaZq6KGA3dbx/PwZsJMNAyuBkbnQ2ZqDj X-Received: by 2002:a17:902:48:: with SMTP id 66mr22178220pla.68.1548700404595; Mon, 28 Jan 2019 10:33:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700404; cv=none; d=google.com; s=arc-20160816; b=fj8Csh42qbK0xmOraQx5Ro7Yj6W01D4deDGAZQkeeTT9r0hQYmAO6IfaN/qzjCfqxs 2vrGcH14P1yFtjnvkTXN2QWgU4751EnGkbFAXUB1JQiTfUrtJxXAL/N/t8UFL8xveccl ZsrSS+ZLkL4u6/OF6xO9oUcgPuKdy+nEsfaMJAOudRcjMhS3cTiijqoLNVoTHsnZ3vUz ajd1sh2b9hItGvpqej4+oCKX5ANnJm0SCLYNAU99TtJfWuvCPx2NPRn+i5SCf3Y+xODh OlJqMYZ0UJlAuFDYE8SjM1Tq0jvR7VNrC8oDcuNRsv/CmpNrxRqCXHu3mQoQNrD/bjFY S1AA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=g60ZjpL7981mWpyGrLVdtBfYDiHQgHKtcJ+DI6e0xyM=; b=AgbbMx8bZc4XH8kyp9V8NB57/JkI4oRbwwMpufdTi1JvEUZqtCTnrJCVc1CYiAX1T1 pBDalUCYM9A0SwjPDDl7zs7YDsGtFHuOvYIcD85p3eFbc7zcyWLPI0jl6bazWXokPFm3 rkEZD8wrKpBQfkfgv3fdNFRXKT+xL31iMDbGp6nbd0AfDO36jQV6JaXz2iJ5bvXfhUpE gzXXEcTy+c24fE0I/Flevms2V7lGAvDa6glW3Ry10qBITIbbXKo2AJycmolv68hWQB5A 9BjGBEEI127QV98QoCQwo+i+m6ULFheOHzd1Q0qTXWo5e6lVY/hAKLUmkiENRmR0Oznn PN5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=F+uqjAbn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h7si1272754pls.326.2019.01.28.10.33.23; Mon, 28 Jan 2019 10:33:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=F+uqjAbn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727824AbfA1SdW (ORCPT + 31 others); Mon, 28 Jan 2019 13:33:22 -0500 Received: from mail-wr1-f68.google.com ([209.85.221.68]:33121 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727772AbfA1SdT (ORCPT ); Mon, 28 Jan 2019 13:33:19 -0500 Received: by mail-wr1-f68.google.com with SMTP id p7so19288000wru.0 for ; Mon, 28 Jan 2019 10:33:18 -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=g60ZjpL7981mWpyGrLVdtBfYDiHQgHKtcJ+DI6e0xyM=; b=F+uqjAbnKbzSB8lfWnOU2J3SGhkWEVCMLZC3sUtR3HXaCnr1T3kqZPUPHf/YumVdKC Sq6oGx60KrbI/cxgTud27xWXcH66R026zdPHMhZ40kP5o8pcYYEGX0Plh5TLzLpm/0pn y2E4NXreMTTrwKoHhHrk3QbTvRY2WfofqEXz8= 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=g60ZjpL7981mWpyGrLVdtBfYDiHQgHKtcJ+DI6e0xyM=; b=Ig9mVC9kbi516LUHLG5CsFu84hwRT4AfPPnIlJPUbqyK+XhLnFenmDsQaAw3H0MBWj Fo0SjbJHHzB8nLnAs64A41mCJjFwozFVhQO4hL6Pr/Er72NsEy50GquUNMYFqzQ3Vgu8 OJz/86Px1+MAbT75Lux2FK+cSkhm663/Qv6pSsuTh83XNVJbOItk2mDwuO1tkNtyQkux bLyCypmtqfQ4Z2rMFg4qbfDWN6G6tfSflMJ6yBawgT71szpQsTlYAcQEJ5yxHKFAtLH1 pVLP8agD+yjDkpVQhZF6/4/pzMmnpQC29z68pH2w2ZSyxP04S+Hpnusy0Pdd0SS987WT yuig== X-Gm-Message-State: AJcUukeYZguMne7WFYlPwRBvmKZ9FxjTIKdqjBRsnEdaOqR40OgvREBs ysQy4dS5kX7B3uww4BpCDcCBjQ== X-Received: by 2002:adf:cd0e:: with SMTP id w14mr23694468wrm.218.1548700397788; Mon, 28 Jan 2019 10:33:17 -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.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:17 -0800 (PST) From: Jorge Ramirez-Ortiz 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2 01/14] clk: qcom: gcc: limit GPLL0_AO_OUT operating frequency Date: Mon, 28 Jan 2019 19:32:48 +0100 Message-Id: <1548700381-22376-2-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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Limit the GPLL0_AO_OUT_MAIN operating frequency as per its hardware specifications. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- drivers/clk/qcom/clk-alpha-pll.c | 8 ++++++++ drivers/clk/qcom/clk-alpha-pll.h | 1 + drivers/clk/qcom/gcc-qcs404.c | 3 ++- 3 files changed, 11 insertions(+), 1 deletion(-) -- 2.7.4 diff --git a/drivers/clk/qcom/clk-alpha-pll.c b/drivers/clk/qcom/clk-alpha-pll.c index 0ced4a5..ef51f30 100644 --- a/drivers/clk/qcom/clk-alpha-pll.c +++ b/drivers/clk/qcom/clk-alpha-pll.c @@ -730,6 +730,14 @@ static long alpha_pll_huayra_round_rate(struct clk_hw *hw, unsigned long rate, return alpha_huayra_pll_round_rate(rate, *prate, &l, &a); } +const struct clk_ops clk_alpha_pll_fixed_ops = { + .enable = clk_alpha_pll_enable, + .disable = clk_alpha_pll_disable, + .is_enabled = clk_alpha_pll_is_enabled, + .recalc_rate = clk_alpha_pll_recalc_rate, +}; +EXPORT_SYMBOL_GPL(clk_alpha_pll_fixed_ops); + const struct clk_ops clk_alpha_pll_ops = { .enable = clk_alpha_pll_enable, .disable = clk_alpha_pll_disable, diff --git a/drivers/clk/qcom/clk-alpha-pll.h b/drivers/clk/qcom/clk-alpha-pll.h index 66755f0..6b4eb74 100644 --- a/drivers/clk/qcom/clk-alpha-pll.h +++ b/drivers/clk/qcom/clk-alpha-pll.h @@ -104,6 +104,7 @@ struct alpha_pll_config { }; extern const struct clk_ops clk_alpha_pll_ops; +extern const struct clk_ops clk_alpha_pll_fixed_ops; extern const struct clk_ops clk_alpha_pll_hwfsm_ops; extern const struct clk_ops clk_alpha_pll_postdiv_ops; extern const struct clk_ops clk_alpha_pll_huayra_ops; diff --git a/drivers/clk/qcom/gcc-qcs404.c b/drivers/clk/qcom/gcc-qcs404.c index 64da032..7de4fcf 100644 --- a/drivers/clk/qcom/gcc-qcs404.c +++ b/drivers/clk/qcom/gcc-qcs404.c @@ -304,6 +304,7 @@ static struct clk_alpha_pll gpll0_out_main = { }, }; + static struct clk_alpha_pll gpll0_ao_out_main = { .offset = 0x21000, .regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_DEFAULT], @@ -316,7 +317,7 @@ static struct clk_alpha_pll gpll0_ao_out_main = { .parent_names = (const char *[]){ "cxo" }, .num_parents = 1, .flags = CLK_IS_CRITICAL, - .ops = &clk_alpha_pll_ops, + .ops = &clk_alpha_pll_fixed_ops, }, }, }; From patchwork Mon Jan 28 18:32:49 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156875 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3749791jaa; Mon, 28 Jan 2019 10:34:41 -0800 (PST) X-Google-Smtp-Source: ALg8bN4jXLkBcchL5HNX9WGjdtCC+OItchgIyGdw/rWJIyai5vwwblxiLpbhA2uYryZFoGXy+lN4 X-Received: by 2002:a62:b80a:: with SMTP id p10mr22826873pfe.32.1548700481767; Mon, 28 Jan 2019 10:34:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700481; cv=none; d=google.com; s=arc-20160816; b=x259CjMNwdKsBDnMkp17+DvTnJaqpY7wh7TN9s8aXTJ9JbZnJ7wICNCa1SSih+L4ab lwGvQqyjP5DyazlqZ9stQQcZ4SDAkVBnCnEWbeX8Mv46CJQXTqLIw0k+SWmnAt/CDdXK +KLYRPD/L2PzIh+ZD1IroKX0i40Z7XucOn2MInxM7cMjcXeZdSEf0NncnbO1jGspca8n ISf2/qtDFlAQI+uUc2btlRMR7cWqSlj5vUwzFShcPPJIa/MPcGlrmZf2rL+CYhxrSlAe +njfVp0d3wJWGCqF7QS5IGGxVsK1YjfDtsuXKcxqKlo5KClHuOQOpYqMY4JM6Alq7Far cPVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=CByMJapU1NSkj2K6jtzA4klxdw2kAUsE2KAShgBobpo=; b=m3dmzS4XLYiJISe+D5Rub0j/TwBoXa+NQzQ/wFoXd+Vk7LcWk4q9vuevdpNXzSEEMm adXOZqucRRYQpwSlpx/Lx9ekbYjS7sIZjxfvJmPF8zBn/LLGD62dh+WVQnsAYAv/3UR7 e7z46yH3e22+fYDT759su/nP2WJCz1pRLqo0QbybGTEhjATEH7CwsWc0aY0SseOR9ir9 SYTd20m6C94s7K8ESXxklcZSUXoPLVNK+ED238kzAtfqsyRl7mBvcO4egax9hui7YYW0 GrcqUMFUMulJt9BpqZ6E2O2Tzw3zsE79/pJAUVsW8R0ex5gl2ix1PCGiCYb9Nhgfgy6m MBbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Q6f9KG0t; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f35si7043660pgf.449.2019.01.28.10.34.41; Mon, 28 Jan 2019 10:34:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Q6f9KG0t; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728333AbfA1Sek (ORCPT + 31 others); Mon, 28 Jan 2019 13:34:40 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:36827 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727754AbfA1SdV (ORCPT ); Mon, 28 Jan 2019 13:33:21 -0500 Received: by mail-wm1-f68.google.com with SMTP id p6so15011195wmc.1 for ; Mon, 28 Jan 2019 10:33:20 -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=CByMJapU1NSkj2K6jtzA4klxdw2kAUsE2KAShgBobpo=; b=Q6f9KG0tQSMK7v4MMXKg9Vd31jOXjH7CP9t+KgkhFYmdQpoyZV6HBbFm3l4TqXT+PX hr8hgWw4OZxPVL8DpYBSfsPfjAjV/+AHnfBn2DRYjXOl8DbczY4kDSEFL1rC5bCrDLoT ohHlTGHsTYIF6efkQA1tlhU/U3e9wcYqnhm38= 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=CByMJapU1NSkj2K6jtzA4klxdw2kAUsE2KAShgBobpo=; b=MTkSCIaYiOuN1py7J/gVjKPJvLGSe5EMlO2ufyc0F6CHSKTXmQyW3mrUT2wQGp9w4A 4go8VZgdS6d1MFyU7liJNQmdyVU0p5MkHwL2CwbzQSly4aAF8v/3f7p7J7jaiIH0Xi8y MBblfVw9odWxMNyyqHZyBGhtQWEpShsf7O64qw0QUdY0wiMtYQEIJ57uD6k+rCJGaTIo K1yWADp4cqiK3h5PY/yz3g6sSJQ/kQ0G81mwOtYbJuBd9TQk+3anUCnU8lEzagoXiVY3 7lo/+UCTE5Em/r/e3sIr5InyWelyDDceZpbIr0F90BPHQrNbYyRttI2hY9smVPSh1BRz GpKQ== X-Gm-Message-State: AJcUukcz0U9XvsMg4RapdJZobDewyoYvVbYKdhmAmsbT3drIS2WVRCrs hwT9RM+vqpcfGI7J05CX58n8eA== X-Received: by 2002:a1c:dd04:: with SMTP id u4mr18068554wmg.84.1548700399573; Mon, 28 Jan 2019 10:33:19 -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.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:19 -0800 (PST) From: Jorge Ramirez-Ortiz 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2 02/14] mbox: qcom: add APCS child device for QCS404 Date: Mon, 28 Jan 2019 19:32:49 +0100 Message-Id: <1548700381-22376-3-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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There is clock controller functionality in the APCS hardware block of qcs404 devices similar to msm8916. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- drivers/mailbox/qcom-apcs-ipc-mailbox.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) -- 2.7.4 diff --git a/drivers/mailbox/qcom-apcs-ipc-mailbox.c b/drivers/mailbox/qcom-apcs-ipc-mailbox.c index 3cf2937..0d64aa5 100644 --- a/drivers/mailbox/qcom-apcs-ipc-mailbox.c +++ b/drivers/mailbox/qcom-apcs-ipc-mailbox.c @@ -97,16 +97,21 @@ static int qcom_apcs_ipc_probe(struct platform_device *pdev) return ret; } - if (of_device_is_compatible(np, "qcom,msm8916-apcs-kpss-global")) { - apcs->clk = platform_device_register_data(&pdev->dev, - "qcom-apcs-msm8916-clk", - -1, NULL, 0); - if (IS_ERR(apcs->clk)) - dev_err(&pdev->dev, "failed to register APCS clk\n"); - } - platform_set_drvdata(pdev, apcs); + if (of_device_is_compatible(np, "qcom,msm8916-apcs-kpss-global") || + of_device_is_compatible(np, "qcom,qcs404-apcs-apps-global")) + goto register_clk; + + return 0; + +register_clk: + apcs->clk = platform_device_register_data(&pdev->dev, + "qcom-apcs-msm8916-clk", + -1, NULL, 0); + if (IS_ERR(apcs->clk)) + dev_err(&pdev->dev, "failed to register APCS clk\n"); + return 0; } From patchwork Mon Jan 28 18:32:53 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156865 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3748656jaa; Mon, 28 Jan 2019 10:33:35 -0800 (PST) X-Google-Smtp-Source: ALg8bN6sFGQCZi6g7ttDuX+6Amhve6BwPNp4kkN5zZtEmYyeGz4+W+nRKIkywsjDoJSdxM0htSG4 X-Received: by 2002:a65:4ccb:: with SMTP id n11mr21111233pgt.257.1548700415615; Mon, 28 Jan 2019 10:33:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700415; cv=none; d=google.com; s=arc-20160816; b=I02vU6p4G1GlN/ilvbsu3iNL4fmId0F1+ENJlV8X7dC8wYCQOdv/kTPl0CvFfKHGVu uaCDis36gagRA3JN+3dcppLBp2rIqQAuffC0bM9czv69oDQj0DdwQJuG4CW7WIPeLNOO i6RHSaqQcVksrQJOldYAdLLy/N1ZeIg4rNV6hzNK9oUBQn9qaTrpI7/GMXV/9uj9qBO9 PeL0UOXL+vVHTQDA4HFEaFxpHVMfC9gPwRxrZoiQXQ/6ZC/vX5F6BHSsjdmZmTc04VS8 suMidRKN6qewYm3PmUgcXG+GEUsZJZm9mFS9+ZzkU4gTklepFeTgtcx0EZ1kBuvcHGpl g7Jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=CrsB9vDQWUxmYDFtafFb8lMIaGmRCz/1Apw6ozfisK4=; b=D1Vm1lFSL7tRSZWFc13ivQF8bN7kGPXXaYaMg2H5OJwOjVpVlybX4lx8PjB8ZenZc1 RWFkZvYKfrRfjJnAlgIyOIDwMKjoTlzg576z+8mPzWaJscP2Z9m+hOkAN4js/PJyTrPB Fu6z54M08pTsJ6g21p0MAYajhA7UD+KdMi546PLnN/x+COzzMYPMzUMISz/NdnXa32+/ /exhsG0rDhaTP+dvc159vsvRvIA7fLzD1ExVrWviYrum9m0HfN9CdBwrV7QFxA6EMOaT 0XYT6QYgaVNQu4oX9cqK1FepRpzUs+Ef8ua0rr4g0SRB3+TnBwmvZI/jTawRPhjELoWp kN+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KhRO5+cs; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2si10231477pgh.475.2019.01.28.10.33.35; Mon, 28 Jan 2019 10:33:35 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KhRO5+cs; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727981AbfA1Sdc (ORCPT + 31 others); Mon, 28 Jan 2019 13:33:32 -0500 Received: from mail-wm1-f66.google.com ([209.85.128.66]:34348 "EHLO mail-wm1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727909AbfA1Sd2 (ORCPT ); Mon, 28 Jan 2019 13:33:28 -0500 Received: by mail-wm1-f66.google.com with SMTP id y185so11107923wmd.1 for ; Mon, 28 Jan 2019 10:33:27 -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=bRcrz8sdZojTUmlbA1FFPIS+MhPNWvmk587f7sXh8D6fhrl0a9IMNmwDpIZlP8Qas6 mIUf2A1LIIpVr0e+TYwVCzoyG0djStk4zyiZBN9YKx61EVpc9o/WzOSxsH8fAYXVjfr3 Xuyve5MjbHLfhnqDVxLUkFaWJVmGuL2E3yl6Y7eeaB9e3v6NQB+yubf67n1yI3bfKS2Q k8HpSvq2VrD2qsfWCnxLRjWDzLyGupejRuA23JEXNJSuIt0fw2/JJ9gK3N06Yg0NL3CL TezCGo+ziCd6Iy76ZgMq9dZmZKo9MtB5YNmIa200UT6FAG2Za3WhtRGdKYV8cqHAB2Cz qlZA== X-Gm-Message-State: AJcUukf16QVXksXJcRZI5uPXCXFZd5KUHgRIMMdWpykSKMlyVyC2K+AF 03ZjW1OXN83bSKKADTFn0ekZmA== 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 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org 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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Allow accessing the parent clock name required for the driver operation using the device tree node. This permits extending the driver to other platforms without having to modify its source code. For backwards compatibility leave the previous value as default. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- drivers/clk/qcom/hfpll.c | 8 ++++++++ 1 file changed, 8 insertions(+) -- 2.7.4 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); From patchwork Mon Jan 28 18:32:54 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156873 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3749458jaa; Mon, 28 Jan 2019 10:34:22 -0800 (PST) X-Google-Smtp-Source: ALg8bN6v4AUYd22C2f6t5MJrtexlAUtjtTz47DoG9XsOj7amD1++fi5RUmZE/WgixCZqBEmqNKGm X-Received: by 2002:a62:be0c:: with SMTP id l12mr22382822pff.51.1548700462659; Mon, 28 Jan 2019 10:34:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700462; cv=none; d=google.com; s=arc-20160816; b=aUV9V4Ct42tzCeQmbRuQQs5BSBskL+TymxR1Vi1Iq5RlXoR8CGe854Kk4q0rqkOiMa 1lvlt1mVznuwYRrdF5qFdqK8rPp8HgB3EQwJHEApyV7fISUx/qwlot6StGtWbCFynP/+ EBFKeNLPyoM9GvXS7supAQARNSJMDBwAqaC4ZN0Dgcc050EByYdoE9iweFv+g0y61fsM E9a3J0PBF2VfHEKrCqnOoZAbLcyjGJ00hv2zHtFqrVqT//RVB7c7SdkFN360saBvhE3A q5J/cGBk1eXE44NWLF1WtE6NuGpybprx38otxPyHUxueUbpbeAW/ScBazn+v2tx9Pabz 4i2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=jVpmDAqKxQ/sn4lpMw47fV7HcMyJcxjw7jbklh3qbPU=; b=t2P3tazStF21yl8YchXbRB6fN0lbe1LgUB4Hvcur3ORRIEjVK/T1vSEVlx9OeISVI2 8oSKrTZjHCa3p+9eoVOyvm5ETEOTwXYFxaLbxKFfO2/3d9BPdd0b9VJRUugfn5DNo8Fq X/fnLNhSxZAbkC+NChrSzRpJTzLc9MEx6d96w56sN2IS4SttFI6dtUvZkJjKqXgZHHUC LDduqrN9nR6/S2BLGCHC7vuscz6VVQm4+ONaNrZ6J5jFC3OSkp4Bmxhamlxxten/RSbx oSAkkvxs94+89myvRpTvcd4DtaJordeBYtdmNuCWYmEd77a1p/K1sXCMqqQjsLWNMtE5 EfWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=AuLKGXTE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bh5si1763792plb.42.2019.01.28.10.34.22; Mon, 28 Jan 2019 10:34:22 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=AuLKGXTE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728289AbfA1SeU (ORCPT + 31 others); Mon, 28 Jan 2019 13:34:20 -0500 Received: from mail-wr1-f68.google.com ([209.85.221.68]:36001 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727931AbfA1Sda (ORCPT ); Mon, 28 Jan 2019 13:33:30 -0500 Received: by mail-wr1-f68.google.com with SMTP id u4so19239163wrp.3 for ; Mon, 28 Jan 2019 10:33:29 -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=jVpmDAqKxQ/sn4lpMw47fV7HcMyJcxjw7jbklh3qbPU=; b=AuLKGXTEF/zJmA5NsI2ZU/MrY8PjDijYbEC7ayTof56dDleGQHTG8AdDA26ctjQtFa H9vffH4TsWwAOXxxxd05+mUnTuz6FxQttOEvnrvbsi+ho4z7s4/hiM7CyWgAvuJUThDt o1WXVLwa8xB2zcnkoJhZfw3cjiaNoa1Da+AD0= 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=jVpmDAqKxQ/sn4lpMw47fV7HcMyJcxjw7jbklh3qbPU=; b=QIfpsrCZ0KVa2jDgjJ/OZw1XTFEtsDUleiG44M1blCb72elNoBap1isrLDqQ3H9xc2 BfS/T1gtNUEso5WRqFaZZWvgxFaSLt0MCLMvurmYz65chmixIGzKEJExxA6Ej7INdvVD Uvs1+B4Tb4x1ZvTAolpSftvOtUgZUx/PIzPG/u/AOJ+UozKZvIsg/hSj9Sl7oyP4qf83 qlTavukaG0OVciZkTgKGmPRMFvo1a2CX20W6U7+JJa69fEKRIHPeeTzJhtNbiW/fj2Za 1nqYxiNC/cpaM3OIAJPjxikAdlJcNpU0g3uGJWYUd7hCLh4netMmQfx4ZUMmXUvNSFb7 ThPA== X-Gm-Message-State: AJcUukcC1XSMtRmciFw5t3XF4p0/1lDmuMt/Ubr+WvxvKBnS01NKac6N XDDkuqBYCQEQB/oCX4MvWZ6Q3A== X-Received: by 2002:adf:9b11:: with SMTP id b17mr23059241wrc.168.1548700408757; Mon, 28 Jan 2019 10:33:28 -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.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:28 -0800 (PST) From: Jorge Ramirez-Ortiz 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2 07/14] clk: qcom: hfpll: register as clock provider Date: Mon, 28 Jan 2019 19:32:54 +0100 Message-Id: <1548700381-22376-8-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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Make the output of the high frequency pll a clock provider. On the QCS404 this PLL controls cpu frequency scaling. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- drivers/clk/qcom/hfpll.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) -- 2.7.4 diff --git a/drivers/clk/qcom/hfpll.c b/drivers/clk/qcom/hfpll.c index 87b7f46..0ffed0d 100644 --- a/drivers/clk/qcom/hfpll.c +++ b/drivers/clk/qcom/hfpll.c @@ -53,6 +53,7 @@ static int qcom_hfpll_probe(struct platform_device *pdev) struct regmap *regmap; struct clk_hfpll *h; struct clk *pclk; + int ret; struct clk_init_data init = { .parent_names = (const char *[]){ "xo" }, .num_parents = 1, @@ -87,7 +88,14 @@ static int qcom_hfpll_probe(struct platform_device *pdev) h->clkr.hw.init = &init; spin_lock_init(&h->lock); - return devm_clk_register_regmap(&pdev->dev, &h->clkr); + ret = devm_clk_register_regmap(dev, &h->clkr); + if (ret) { + dev_err(dev, "failed to register regmap clock: %d\n", ret); + return ret; + } + + return devm_of_clk_add_hw_provider(dev, of_clk_hw_simple_get, + &h->clkr.hw); } static struct platform_driver qcom_hfpll_driver = { From patchwork Mon Jan 28 18:33:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156869 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3748950jaa; Mon, 28 Jan 2019 10:33:51 -0800 (PST) X-Google-Smtp-Source: ALg8bN4+3O/xuo8Z02/KEjdekNOkpJDGLuXVYPXD1Vx0L0R57kntanZQJaw7vS0hKd9kR5d7f2eN X-Received: by 2002:a17:902:380c:: with SMTP id l12mr22286215plc.326.1548700431525; Mon, 28 Jan 2019 10:33:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700431; cv=none; d=google.com; s=arc-20160816; b=HVjcwztP2ct/phYXzKZfeO+nLOE8RVqVWr/6ebt99VPquovgn/ATdN3mtsFnaycSNe kNZYyg1BxDSHUUkd1skxNmPIXecQzXz2Ub91beIRFtDaEfBdZlTZaKtnoOEdE+UlgDuU ucyZnejZCuIpmm3XkIWRIZ+TNKTceXGbpM/hVeAEeyuLtj+VFzIEPLG54aUqImt7+Tb4 Vgv4zzAiRKDGL/I6nNX8UTXPs5P7cYN0wKFFhrC+ZmNghxY18CXsXOVOpdS/2C7hbioC xzVuaCXOZmAoH1HG1KRNtXBWDC8eDaYHz/n58hMRRfdrgPOpm77D2POHSBCxVo1hVvwu JNmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=5jwkKlS341j7fyk95QNvo70XMLCAjNUCF7cHyyXT/yc=; b=RX7RR2BhJcq8PMNybWeAX89o5TSC8TmnBG2/qCW1pVJGwCWwxpmeWMfVPkK1bs8Gs7 ptbeHWMkPjuJpAFU0GgRCwU4R2qjbiNfy2Too2EwTfaSXLBjK20ajw5fQlMgeRZ/fFM9 xYVH1eMHr4iKGsZUdb8PRv7WANxEEC/bAxpfTOoMyaMDgMkIgz/e5Crum1hSIfY98IOk wWoBpW4XozgMbH3nYDt9bNOv8xCdp9kU1e8xYcmB+Ep/SY2L0w88oUisKdROJkz4WDTg fl4vDV+IqDFbL0eNODh8cj97eC+1Dh/6mRY1mzE8ZgA5WUB9ZPcPkV+AmbuHDeV2jsSj 20EQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=I9vc9C12; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r12si33133521plo.59.2019.01.28.10.33.51; Mon, 28 Jan 2019 10:33:51 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=I9vc9C12; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728160AbfA1Sdn (ORCPT + 31 others); Mon, 28 Jan 2019 13:33:43 -0500 Received: from mail-wr1-f67.google.com ([209.85.221.67]:41573 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727410AbfA1Sdl (ORCPT ); Mon, 28 Jan 2019 13:33:41 -0500 Received: by mail-wr1-f67.google.com with SMTP id x10so19199004wrs.8 for ; Mon, 28 Jan 2019 10:33:40 -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=5jwkKlS341j7fyk95QNvo70XMLCAjNUCF7cHyyXT/yc=; b=I9vc9C123OGGrDPTEKb5TUh/XNiAw4yOfrCyECVMnCLNqO9xZI5rx/Z6EAJpySXVEt xDwDN/UvvPHwcg1qG1Isdt7DytmzEJEQ6U8ew76/GlCl7yThh6ae2lefENgeb8ucGlZt j7YQ1Z3CclpMfyTSM8r8Mj6GPj7DUjfRMOoDk= 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=5jwkKlS341j7fyk95QNvo70XMLCAjNUCF7cHyyXT/yc=; b=MxCgDitvQiGbAVHJYagakuUqSoU/9LJ8z3mlQpSGxCB3U5jYXFz2AslHR4GnBVhudi oL2vOYZt5sUsJsxhrZtNg79RPKML5s9yYd6mchZQzQlT6hFnjG9A1eJGIwdfbC5kAIFo lCoExpZUsoWPUPdGEVG2CIFnnK2c9kYRxfopQRI8rDDxWR+R5tB7qI82P04NNv+kDP1h wILrqXohopRopvA7RLylWpDbOJjbBsaTAZuRJTfmMWPtWQcDvOw3ivNMGTtlNbhIpC8x 5eIC3gLcqIO1f/wnkIXQ4ZR/SchCV029mXmltFuPeQAfTn71ePwPiEhJyoJ3h5KsCgNL Fzew== X-Gm-Message-State: AJcUukeMLWEyzVSLsPAZ7MG1wnv/Elt13dZOtv8HDX6EKu74brdYAePK na+mCfiBma7rfk+5GJJ35v87fMLAHxc= X-Received: by 2002:adf:9521:: with SMTP id 30mr21617095wrs.192.1548700419861; Mon, 28 Jan 2019 10:33:39 -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.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:39 -0800 (PST) From: Jorge Ramirez-Ortiz 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2 13/14] arm64: dts: qcom: qcs404: Add cpufreq support Date: Mon, 28 Jan 2019 19:33:00 +0100 Message-Id: <1548700381-22376-14-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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Support CPU frequency scaling on qcs404. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- arch/arm64/boot/dts/qcom/qcs404.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+) -- 2.7.4 diff --git a/arch/arm64/boot/dts/qcom/qcs404.dtsi b/arch/arm64/boot/dts/qcom/qcs404.dtsi index 948ba3c..a0f58bf 100644 --- a/arch/arm64/boot/dts/qcom/qcs404.dtsi +++ b/arch/arm64/boot/dts/qcom/qcs404.dtsi @@ -30,6 +30,8 @@ reg = <0x100>; enable-method = "psci"; next-level-cache = <&L2_0>; + clocks = <&apcs_glb>; + operating-points-v2 = <&cpu_opp_table>; }; CPU1: cpu@101 { @@ -38,6 +40,8 @@ reg = <0x101>; enable-method = "psci"; next-level-cache = <&L2_0>; + clocks = <&apcs_glb>; + operating-points-v2 = <&cpu_opp_table>; }; CPU2: cpu@102 { @@ -46,6 +50,8 @@ reg = <0x102>; enable-method = "psci"; next-level-cache = <&L2_0>; + clocks = <&apcs_glb>; + operating-points-v2 = <&cpu_opp_table>; }; CPU3: cpu@103 { @@ -54,6 +60,8 @@ reg = <0x103>; enable-method = "psci"; next-level-cache = <&L2_0>; + clocks = <&apcs_glb>; + operating-points-v2 = <&cpu_opp_table>; }; L2_0: l2-cache { From patchwork Mon Jan 28 18:33:01 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 156868 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp3748862jaa; Mon, 28 Jan 2019 10:33:47 -0800 (PST) X-Google-Smtp-Source: ALg8bN5+gRTBSEgZm+SsJVq8gydnuUDIewA1VpYwauRVeeC9OsqU6gaGSpf/9s2M8LFNpA/W7fl0 X-Received: by 2002:a63:ec13:: with SMTP id j19mr20644140pgh.6.1548700427111; Mon, 28 Jan 2019 10:33:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548700427; cv=none; d=google.com; s=arc-20160816; b=aR8VGHIKAXHt43zwWB9wV8qvYHvDZg5NCyEL1fld4a0rmhTig3VOvPtJ8eULEC8608 2quhdWsN7uJZKZc4kvtRWKu3468she/wS+DxKKwxJEqrofo+6Vzm9Dq15tbHZFBYbU7E KqpwV8mvd9nrgCUN5RyOT5cg0d8K6+prfpbe1ZuE0VC4iRQq1IlRSrUunbOb3MdCJhl5 JgjSoDOfdD1Q3bH/KMA4gD2vuR/ggt+wJQO3s4KSnsg6i2KbuyZQbvITgjUJA7NvjYLV 5+BXKdvfiySZMFYeZ0pLZNC+DFTXZ7r3UKSgJ7ubKTsfbk6DC1OqrFH6aGGj5HM9X1PC ttcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=nAEdvq5oOukgk1f4NK11o2gbGIkfrBCRV8yGimK9/ag=; b=iZSAIzoZGHB4KAlR08PCriXdv7bDei+j4xErhUcmYRuQmksHFljOs6ZAEBca2smboS WQ47bC+Q5NkWjNob9uCH7Cfgs7VJCQDHH2cs4JDA8g/J0F67zX3A9BqWim69uxwLDhdG RGIP//xqRd7r1XSy8Pxsn02C/nwRYs4AtFzPr39iKHzxR65v2b1pq8u/cqgnpH+zfu0k a19EHEPjZW7bTfIxWk9NiDEgN6hLxSUUh7xdo0C+qG/YHY+KDXiVaophU31D0/e9+KNi prD4AQWjYK9dZ5T6H1bb1+zi3Zn6P38lIOC382IAZ8tpxKUcSL2ReV//XuH2qjcSKmtm GtkQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NgQTujWo; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2si10231477pgh.475.2019.01.28.10.33.46; Mon, 28 Jan 2019 10:33:47 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NgQTujWo; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728188AbfA1Sdo (ORCPT + 31 others); Mon, 28 Jan 2019 13:33:44 -0500 Received: from mail-wr1-f65.google.com ([209.85.221.65]:36019 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728121AbfA1Sdn (ORCPT ); Mon, 28 Jan 2019 13:33:43 -0500 Received: by mail-wr1-f65.google.com with SMTP id u4so19239795wrp.3 for ; Mon, 28 Jan 2019 10:33:42 -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=nAEdvq5oOukgk1f4NK11o2gbGIkfrBCRV8yGimK9/ag=; b=NgQTujWor9c8VTUEHGHbjOFEgPwu0ve769eQ9xvenDaBYyKgxpegvFKTQxN/s4L62/ Lj1APdMK6Ty1l0V7p70DAqg39xa+A1ji3EU01bGIg1QTzX8XGEhiZbveaMMDjPnnTcl1 w6c4i+C1/6v5X6xcAzuKryU+xNa2qDOPYZopQ= 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=nAEdvq5oOukgk1f4NK11o2gbGIkfrBCRV8yGimK9/ag=; b=qNPHuZpWpapoDP/emByjMbs9BZZVbwYxvOQh5S2wNa0xVqYKogEzmrMDJ6IR5HJ7+z zYpkGkOJRjNkVHns0d24b08k3aCYz+bHxcJZz2CCcjVgsGYvznjKUj52UoH26IhY2SdQ ADimuY/VGoG8KmqP9oZSAp985Rzd4RbYgp78eYgmafd1ri7cIKG3BR8pxwZhxl/BR4Sq clXJWUFtZQS/rJ7BMOq+UP4aRrBIwPFD2B9rXbF62/tL/MEr+unj1JAjfF9S6Lw1z1NZ XIOk15T+vW7M0IV8xeL0paqTmW2qyxgAYyE2Sz8oCpPsEuEe/7sC2pQ/kQH45GIomaze cQ3g== X-Gm-Message-State: AJcUukeSSDgl6Ajngg04rYm0DcDnsVdmxePr7d8anqGS/cS+knR7sOQW suJdZdFuKN0nTxE/Ih6Iz2ONEg== X-Received: by 2002:adf:9205:: with SMTP id 5mr22721276wrj.189.1548700421706; Mon, 28 Jan 2019 10:33:41 -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.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Jan 2019 10:33:41 -0800 (PST) From: Jorge Ramirez-Ortiz 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 Cc: vkoul@kernel.org, niklas.cassel@linaro.org, georgi.djakov@linaro.org, amit.kucheria@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-arm-msm@vger.kernel.org, khasim.mohammed@linaro.org Subject: [PATCH v2 14/14] arm64: defconfig: Enable HFPLL Date: Mon, 28 Jan 2019 19:33:01 +0100 Message-Id: <1548700381-22376-15-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> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The high frequency pll is required on compatible Qualcomm SoCs to support the CPU frequency scaling feature. Co-developed-by: Niklas Cassel Signed-off-by: Niklas Cassel Signed-off-by: Jorge Ramirez-Ortiz --- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) -- 2.7.4 diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index c8432e2..67f0cca 100644 --- a/arch/arm64/configs/defconfig +++ b/arch/arm64/configs/defconfig @@ -628,6 +628,7 @@ CONFIG_MSM_MMCC_8996=y CONFIG_MSM_GCC_8998=y CONFIG_QCS_GCC_404=y CONFIG_SDM_GCC_845=y +CONFIG_QCOM_HFPLL=y CONFIG_HWSPINLOCK=y CONFIG_HWSPINLOCK_QCOM=y CONFIG_ARM_MHU=y