Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp698149imm; Wed, 6 Jun 2018 04:44:45 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLmhf4+2QnGrVGSYhho279N5akr9edI2ULJ+yBHWbvKvcIbjrLeKUqB8P+q4HBEM+bBCXn/ X-Received: by 2002:aa7:810f:: with SMTP id b15-v6mr2097878pfi.79.1528285485151; Wed, 06 Jun 2018 04:44:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528285485; cv=none; d=google.com; s=arc-20160816; b=L868bDgpLF4O3IlQcbFxq2OEjga9J5/4HkUk+TKmm+dduy2hNDMvt1pfVe/FVkNZgB YaysQLZYCx6nA26zeoOq/iYH6k5mvtatp/oxSKIO0LF5pmMkC6WleGJImqRXNRxEto6I UbyHs1ijxKMZckvkE4HTGSVC/tuXCDucWg4P/re69jlA/Vf5A+MP7GC2NEo5+Yfp+iVC kxO/ar1P5WOQ2t5EOHczMAMg5QCyZ1cFbDgZDy+ODv2BTV0xRJ6hocwPZtZxofLADwtd nUuDWHfoPXc+s1xgupbqVDM3cwkrm0uQjHjHIUJBR8Ept1RCEsOEnsFhAmFcjE03M7qM Nxeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dmarc-filter:dkim-signature:dkim-signature :arc-authentication-results; bh=nmun8k59iRqwRmBiNniLpoHJBGmjl5ZYcWcuyczfTiA=; b=Cc8wYlx2+ER8dvBw/84SrIjKJyRvWgItUQyug1L/JLUCy6UjFj9H3jH5iiDSHR2C6y FB5npHsqU9GvS3CYBujWgy3qlDBOX88yeYJUNSu++ETcCN2Oz78Fb5KhGeSvO8hk6Rzc tgs2DygP0vCzs2vKq3mzM68e+CAy2OR4M6B2bPDQVpcw2PlxjSfsLuAHkEeSZdA+aQNm ykNJVsfJmgQwvq1OzqDMS0AbIaTNaPoN3Pl4qxnDySM2gydtQSO/bopYqT7L/AwdUjYz uVJSSjNnKFrKhF8wOsXM2ap/m3brNMnQ8oWE97kJ377qqk4Tg1ZUd4CO5V6i90Ycv9N1 fYDg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=bzi71yN0; dkim=pass header.i=@codeaurora.org header.s=default header.b=bhv/laEq; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m189-v6si12620588pga.107.2018.06.06.04.44.30; Wed, 06 Jun 2018 04:44:45 -0700 (PDT) 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=@codeaurora.org header.s=default header.b=bzi71yN0; dkim=pass header.i=@codeaurora.org header.s=default header.b=bhv/laEq; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752188AbeFFLmT (ORCPT + 99 others); Wed, 6 Jun 2018 07:42:19 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:43132 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751729AbeFFLmP (ORCPT ); Wed, 6 Jun 2018 07:42:15 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 41144607CF; Wed, 6 Jun 2018 11:42:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1528285335; bh=cIK9iM0Dn4g+bMNzv3lDLuJ6aMoKDFX7UYfLukxbBNU=; h=From:To:Cc:Subject:Date:From; b=bzi71yN0xc9T4/KLIlhHsTsTzToC3kcjZ507toJr5on8394NgOjf65Fmh1GZTuzq9 Zsselr42ybbmclpKq9cZtc86GEpDalMOc7hZpVIv2iIs3h89C0HCSAXZ/K/FO8PWWm ZJvJNTNVdlhIb4J0NDi5pcqw+2pMzxiqXRbYZAqE= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from anischal-linux.qualcomm.com (blr-c-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: anischal@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 73C4360764; Wed, 6 Jun 2018 11:42:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1528285334; bh=cIK9iM0Dn4g+bMNzv3lDLuJ6aMoKDFX7UYfLukxbBNU=; h=From:To:Cc:Subject:Date:From; b=bhv/laEqnTk0qutdDxYO9Xa3zvhBpngCgq/x5quatnIydlzU1nr1/WRErqAnttzYN a+7hJbHJ4G9N85JdHNwrjRpAXOTXXNiMfy76pJATib2PIxXzFNzb4dGWXMQn5IJR9A AZbYZu9NkK+rPgCG0EdGUn0qZdjSJq9cWobZAEEs= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 73C4360764 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=anischal@codeaurora.org From: Amit Nischal To: Stephen Boyd , Michael Turquette Cc: Andy Gross , David Brown , Rajendra Nayak , Odelu Kukatla , Taniya Das , linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Amit Nischal Subject: [PATCH 0/4] Add QCOM graphics clock controller driver for SDM845 Date: Wed, 6 Jun 2018 17:11:44 +0530 Message-Id: <1528285308-25477-1-git-send-email-anischal@codeaurora.org> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch series adds support for graphics clock controller for SDM845. Below is the brief description for each change: 1. For some of the GDSCs, there is requirement to enable/disable the few clocks before turning on/off the gdsc power domain. This patch will add support to enable/disable the clock associated with the gdsc along with power domain on/off callbacks. 2. To turn on the gpu_gx_gdsc, there is a hardware requirement to turn on the root clock (GFX3D RCG) first which would be the turn on signal for the gdsc along with the SW_COLLAPSE. As per the current implementation of clk_rcg2_shared_ops, it clears the root_enable bit in the enable() and set_rate() clock ops. But due to the above said requirement for GFX3D shared RCG, root_enable bit would be already set by gdsc driver and rcg2_shared_ops should not clear the root unless the disable() is called. This patch add support for the same by reusing the existing clk_rcg2_shared_ops and deriving "clk_rcg2_gfx3d_ops" clk_ops for GFX3D clock to take care of the root set/clear requirement. 3. Add device tree bindings for graphics clock controller for SDM845. 4. Add graphics clock controller (GPUCC) driver for SDM845. Amit Nischal (4): clk: qcom: gdsc: Add support to enable/disable the clocks with GDSC clk: qcom: Add clk_rcg2_gfx3d_ops for SDM845 dt-bindings: clock: Introduce QCOM Graphics clock bindings clk: qcom: Add graphics clock controller driver for SDM845 .../devicetree/bindings/clock/qcom,gpucc.txt | 18 + drivers/clk/qcom/Kconfig | 9 + drivers/clk/qcom/Makefile | 1 + drivers/clk/qcom/clk-rcg.h | 1 + drivers/clk/qcom/clk-rcg2.c | 78 +++- drivers/clk/qcom/gdsc.c | 44 ++ drivers/clk/qcom/gdsc.h | 5 + drivers/clk/qcom/gpucc-sdm845.c | 441 +++++++++++++++++++++ include/dt-bindings/clock/qcom,gpucc-sdm845.h | 38 ++ 9 files changed, 614 insertions(+), 21 deletions(-) create mode 100644 Documentation/devicetree/bindings/clock/qcom,gpucc.txt create mode 100644 drivers/clk/qcom/gpucc-sdm845.c create mode 100644 include/dt-bindings/clock/qcom,gpucc-sdm845.h -- QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation