From patchwork Fri Aug 14 12:09:09 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Abel Vesa X-Patchwork-Id: 11714455 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 077CA109B for ; Fri, 14 Aug 2020 12:11:53 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 D30FA206B2 for ; Fri, 14 Aug 2020 12:11:52 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="werBwTN2" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D30FA206B2 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nxp.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:MIME-Version:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id: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:In-Reply-To:References:List-Owner; bh=lo7hbk6u/CAgeLkJkye4Dia4QMnPGjeDHEXeZE0NO7c=; b=werBwTN2ZgkWzw9EfAssqgL3MB PCIdrw66gio1muyRuT4r1ngA5sF91T+yID1LdDHetL1F5lMaiDGSmdgmFpawynnRTgef7kD41NeT4 VeKA+a1iNyz+pX8McrupWOm5LuceYjAorXIg4ODiRAEk9sNX3yUy+KK1MFDO2XHBbKbIDlN3pWk0u 9b+ethMUnUnSGIC3MAmZKHiHqqEufXVnIeMyuboBmdXDFydiTyDPU/EkWbcvRQaXW0DKunFy0Dt4a DRIh8FKo7+aQmLWgSsij/NmfAwdWJHTLZYtr5XgUQir8PoE3Nuozb9lYMYVTllgFIxvOL8M1jVRTT k4Tc0afw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k6YX4-00076m-81; Fri, 14 Aug 2020 12:10:02 +0000 Received: from inva021.nxp.com ([92.121.34.21]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k6YWu-00070t-6y for linux-arm-kernel@lists.infradead.org; Fri, 14 Aug 2020 12:09:53 +0000 Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 10C0B20024A; Fri, 14 Aug 2020 14:09:49 +0200 (CEST) Received: from inva024.eu-rdc02.nxp.com (inva024.eu-rdc02.nxp.com [134.27.226.22]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 03D3C2001AE; Fri, 14 Aug 2020 14:09:49 +0200 (CEST) Received: from fsr-ub1664-175.ea.freescale.net (fsr-ub1664-175.ea.freescale.net [10.171.82.40]) by inva024.eu-rdc02.nxp.com (Postfix) with ESMTP id 51E2B2030E; Fri, 14 Aug 2020 14:09:48 +0200 (CEST) From: Abel Vesa To: Mike Turquette , Stephen Boyd , Rob Herring , Shawn Guo , Sascha Hauer , Fabio Estevam , Philipp Zabel , Anson Huang , Jacky Bai , Peng Fan , Dong Aisheng , Fugang Duan , devicetree@vger.kernel.org Subject: [PATCH v2 00/17] Add BLK_CTRL support for i.MX8MP Date: Fri, 14 Aug 2020 15:09:09 +0300 Message-Id: <1597406966-13740-1-git-send-email-abel.vesa@nxp.com> X-Mailer: git-send-email 2.7.4 X-Virus-Scanned: ClamAV using ClamSMTP X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200814_080952_534040_22C88877 X-CRM114-Status: GOOD ( 15.54 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [92.121.34.21 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Abel Vesa , linux-clk@vger.kernel.org, NXP Linux Team , linux-arm-kernel@lists.infradead.org, Linux Kernel Mailing List MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org The BLK_CTRL according to HW design is basically the wrapper of the entire function specific group of IPs and holds GPRs that usually cannot be placed into one specific IP from that group. Some of these GPRs are used to control some clocks, other some resets, others some very specific function that does not fit into clocks or resets. Since the clocks are registered using the i.MX clock subsystem API, the driver is placed into the clock subsystem, but it also registers the resets. For the other functionalities that other GPRs might have, the syscon is used. Changes since v1: * implemented the runtime pm in blk_ctrl as discussed with Philipp Zabel on v1 thread * changed the blk-ctl to clock-controller in the dts and doc * fixed the yaml doc * removed the power-domains properties since the power-domains driver is not yet upstream for i.MX8MP. Abel Vesa (17): dt-bindings: clocks: imx8mp: Rename audiomix ids clocks to audio_blk_ctrl dt-bindings: reset: imx8mp: Add audio blk_ctrl reset IDs dt-bindings: clock: imx8mp: Add ids for the audio shared gate dt-bindings: clock: imx8mp: Add media blk_ctrl clock IDs dt-bindings: reset: imx8mp: Add media blk_ctrl reset IDs dt-bindings: clock: imx8mp: Add hdmi blk_ctrl clock IDs dt-bindings: reset: imx8mp: Add hdmi blk_ctrl reset IDs clk: imx8mp: Add audio shared gate arm64: dts: Remove imx-hdmimix-reset header file Documentation: bindings: clk: Add bindings for i.MX BLK_CTRL clk: imx: Add blk_ctrl combo driver clk: imx8mp: Add audio blk_ctrl clocks and resets clk: imx8mp: Add hdmi blk_ctrl clocks and resets clk: imx8mp: Add media blk_ctrl clocks and resets arm64: dts: imx8mp: Add audio_blk_ctrl node arm64: dts: imx8mp: Add media_blk_ctrl node arm64: dts: imx8mp: Add hdmi_blk_ctrl node .../bindings/clock/fsl,imx-blk-ctrl.yaml | 60 ++++ arch/arm64/boot/dts/freescale/imx8mp.dtsi | 41 +++ drivers/clk/imx/Makefile | 2 +- drivers/clk/imx/clk-blk-ctrl.c | 339 +++++++++++++++++++++ drivers/clk/imx/clk-blk-ctrl.h | 81 +++++ drivers/clk/imx/clk-imx8mp.c | 281 ++++++++++++++++- include/dt-bindings/clock/imx8mp-clock.h | 200 ++++++++---- include/dt-bindings/reset/imx8mp-reset.h | 45 +++ 8 files changed, 986 insertions(+), 63 deletions(-) create mode 100644 Documentation/devicetree/bindings/clock/fsl,imx-blk-ctrl.yaml create mode 100644 drivers/clk/imx/clk-blk-ctrl.c create mode 100644 drivers/clk/imx/clk-blk-ctrl.h