From patchwork Mon Aug 14 10:26:34 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 9898495 X-Patchwork-Delegate: sboyd@codeaurora.org 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 37FBD602D9 for ; Mon, 14 Aug 2017 10:26:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A4C42857F for ; Mon, 14 Aug 2017 10:26:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1D8092859F; Mon, 14 Aug 2017 10:26:42 +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.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID 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 82F412857F for ; Mon, 14 Aug 2017 10:26:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752744AbdHNK0l (ORCPT ); Mon, 14 Aug 2017 06:26:41 -0400 Received: from mail-io0-f179.google.com ([209.85.223.179]:36091 "EHLO mail-io0-f179.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752222AbdHNK0k (ORCPT ); Mon, 14 Aug 2017 06:26:40 -0400 Received: by mail-io0-f179.google.com with SMTP id g35so37121472ioi.3 for ; Mon, 14 Aug 2017 03:26:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=+A9tohSsBBrjjmglUEe9Zeoiy0sUTcp6Q5cFXcWN+Q0=; b=caDfXTP/EniwQ9XLTPlp78/OvnTN7bsawW72gAZ/64/cVZV2PfKsO8PKexVkPX8chP IDmOfEyOE+4okNbceGUHuuMJXC/19vMwdiigscfcNQ1bbqts0GE2itmfDjYDQCk1tJ/+ Ex/5H90+so/uMutPlB/Z+xteJVI2fEq04Od54= 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; bh=+A9tohSsBBrjjmglUEe9Zeoiy0sUTcp6Q5cFXcWN+Q0=; b=TOY70dWoIJWRNCV5yAlgvPnAByIoHS5sWoBu9UYfum5pM7ZMDWUl8a7Ek0vS3jvHmO Y4exkx8xmrEkKfBP2q8EhA5Bgrf/yAvk9nYXJad3GwOf4opXZUrbcmufYCUuYzhfKHH7 vJ0JGADh28GwRjPzE4TrtNVGYT27VrKktFx8ZkyqevcE4OOuI2GjSRRPXNBGGnwEYWd4 aGE1IA1e3ota10ZCPQYOWPZePR1ox+j9QIoGwrOH+Eecn4P3YhCDuWubdoFVk4OjtEjK sdbOvD0BIMlkLSKKBu1htGqkTw3Vgyvg1N9AJdfM8DPVd+jWnFpyW6ZbNe7zEEBwGjUN kxHA== X-Gm-Message-State: AIVw111nF0cVyJ9bCuLqElHiNWVXePR3sqe6fRn2MsDf9iutv+Kff2jk bxCYbslZlyo/Cy/5bTUVUA== X-Received: by 10.107.13.206 with SMTP id 197mr11925695ion.8.1502706399471; Mon, 14 Aug 2017 03:26:39 -0700 (PDT) Received: from localhost.localdomain (static.8.26.4.46.clients.your-server.de. [46.4.26.8]) by smtp.gmail.com with ESMTPSA id f92sm3457077ioi.56.2017.08.14.03.26.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 14 Aug 2017 03:26:38 -0700 (PDT) From: srinivas.kandagatla@linaro.org To: sboyd@codeaurora.org, linux-clk@vger.kernel.org Cc: andy.gross@linaro.org, mturquette@baylibre.com, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Srinivas Kandagatla Subject: [PATCH v2] clk: msm8996-gcc: add missing smmu clks Date: Mon, 14 Aug 2017 12:26:34 +0200 Message-Id: <20170814102634.6445-1-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.11.0 Sender: linux-clk-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Srinivas Kandagatla This patch adds missing LPASS smmu clks which are required by the audio driver. Signed-off-by: Srinivas Kandagatla --- Changes since v1: - Added halt_check flag as suggested by Stephen Boyd drivers/clk/qcom/gcc-msm8996.c | 28 ++++++++++++++++++++++++++++ include/dt-bindings/clock/qcom,gcc-msm8996.h | 2 ++ 2 files changed, 30 insertions(+) diff --git a/drivers/clk/qcom/gcc-msm8996.c b/drivers/clk/qcom/gcc-msm8996.c index d1238cc..9b83743 100644 --- a/drivers/clk/qcom/gcc-msm8996.c +++ b/drivers/clk/qcom/gcc-msm8996.c @@ -2644,6 +2644,32 @@ static struct clk_fixed_factor ufs_rx_cfg_clk_src = { }, }; +static struct clk_branch gcc_hlos1_vote_lpass_core_smmu_clk = { + .halt_reg = 0x7d010, + .halt_check = BRANCH_HALT_VOTED, + .clkr = { + .enable_reg = 0x7d010, + .enable_mask = BIT(0), + .hw.init = &(struct clk_init_data){ + .name = "hlos1_vote_lpass_core_smmu_clk", + .ops = &clk_branch2_ops, + }, + }, +}; + +static struct clk_branch gcc_hlos1_vote_lpass_adsp_smmu_clk = { + .halt_reg = 0x7d014, + .halt_check = BRANCH_HALT_VOTED, + .clkr = { + .enable_reg = 0x7d014, + .enable_mask = BIT(0), + .hw.init = &(struct clk_init_data){ + .name = "hlos1_vote_lpass_adsp_smmu_clk", + .ops = &clk_branch2_ops, + }, + }, +}; + static struct clk_branch gcc_ufs_rx_cfg_clk = { .halt_reg = 0x75014, .clkr = { @@ -3217,6 +3243,8 @@ static struct clk_regmap *gcc_msm8996_clocks[] = { [GCC_UFS_AHB_CLK] = &gcc_ufs_ahb_clk.clkr, [GCC_UFS_TX_CFG_CLK] = &gcc_ufs_tx_cfg_clk.clkr, [GCC_UFS_RX_CFG_CLK] = &gcc_ufs_rx_cfg_clk.clkr, + [GCC_HLOS1_VOTE_LPASS_CORE_SMMU_CLK] = &gcc_hlos1_vote_lpass_core_smmu_clk.clkr, + [GCC_HLOS1_VOTE_LPASS_ADSP_SMMU_CLK] = &gcc_hlos1_vote_lpass_adsp_smmu_clk.clkr, [GCC_UFS_TX_SYMBOL_0_CLK] = &gcc_ufs_tx_symbol_0_clk.clkr, [GCC_UFS_RX_SYMBOL_0_CLK] = &gcc_ufs_rx_symbol_0_clk.clkr, [GCC_UFS_RX_SYMBOL_1_CLK] = &gcc_ufs_rx_symbol_1_clk.clkr, diff --git a/include/dt-bindings/clock/qcom,gcc-msm8996.h b/include/dt-bindings/clock/qcom,gcc-msm8996.h index 1847e13..4df1898 100644 --- a/include/dt-bindings/clock/qcom,gcc-msm8996.h +++ b/include/dt-bindings/clock/qcom,gcc-msm8996.h @@ -229,6 +229,8 @@ #define GCC_PCIE_CLKREF_CLK 216 #define GCC_RX2_USB2_CLKREF_CLK 217 #define GCC_RX1_USB2_CLKREF_CLK 218 +#define GCC_HLOS1_VOTE_LPASS_CORE_SMMU_CLK 219 +#define GCC_HLOS1_VOTE_LPASS_ADSP_SMMU_CLK 220 #define GCC_SYSTEM_NOC_BCR 0 #define GCC_CONFIG_NOC_BCR 1