From patchwork Fri Apr 30 05:27:43 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 429754 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp91285jao; Thu, 29 Apr 2021 21:55:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzGJB9o7Zsa5uQ2MdUc1CcVJqkySDpwVHJPiUjt7rlKipiHsZ0hqCLcjkUolXjjlTJrGzQC X-Received: by 2002:a63:c49:: with SMTP id 9mr2959529pgm.381.1619758552167; Thu, 29 Apr 2021 21:55:52 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1619758552; cv=pass; d=google.com; s=arc-20160816; b=RoUs2RvMr5SCAFnLPyWvO07pVLux2o4FJLO+QDLNu3T42RLiOuHL11F4wb8xkQJpER eCOZ+L8/VH6qZHiC6mayHxC5Knzbc7T88sYRDbyYhGaztONdoDN29pH9P9vo0Y2xmTb6 GffEkX3Q6hlj8bR+2VMJDcW3tMQeJioQy4Dtg5ODtcaKhjtx5JZRla8QuOcWumRT6wXC kieCjNGC4NXagV8GRXGxihMFgOyeftT9g5vKVCbHI87MqFx8cRqXUWWwvYl13t8EGdeA zHEr3e9WVekL5e7/iMz0fXNum+25VfZpfVSvBwRJSFTNOHyq1+jFq7+mrONbgWxAP9vr SEMw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=A+F9ydPzZQL7+HYXXydKkW6iHvplYGD6tVCXh+5X5vM=; b=wYqkQ7aHyuEpagunZvL0y5OPne5zhFCRz9KGitiQV1ubbAxCSKnTQM7oePGXuTz9c3 Of7/KW0zrSA+/slMGULhVbRZLrNIWWTKDc4fXrN9ag2ou+jeMIzPubo5qUgLI70NYLYh I3Fzs0qrTnVBwY4iNRyd4VkK8BVfOFKRUFsGUpunpHtk3E4tYneI2m0UKKOipRnOKe3g rZiCflk3r6f8MJy198oM+ww77/OvY5YG+9rQPNifT/kWwL9GE4NhimsNQyKbvr53TKAy R0wns+COoNjI4hqrBKNPsdtVr4sXVrtznn+tkX8jE3BQPE2yQjtqkbyhnHLbZDwBvbk5 845A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=QxFmj1ll; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i10si985490pfa.101.2021.04.29.21.55.51; Thu, 29 Apr 2021 21:55:52 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=QxFmj1ll; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229482AbhD3E4f (ORCPT + 6 others); Fri, 30 Apr 2021 00:56:35 -0400 Received: from mail-eopbgr10040.outbound.protection.outlook.com ([40.107.1.40]:43908 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S230058AbhD3E4d (ORCPT ); Fri, 30 Apr 2021 00:56:33 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZF8ILkW9r30pdYt4aF9k3SACUwLrfp61Df/10hUWHxvKLnDdL+tydsCl0UXbjCiJw/uGH1efAtdLQ8puV1+JQHzIN+PXHhjwhj3Ml4EwRE0437WPEu2A+qnqY0LTWH5XDZNoz3t55Nyn4HuIWyHnFAN5U4zW9gCDH3n3/ENAWbsOrTAqKEj8Jr6bHHdZL6AL04IItw366eLdQETdVvgJGFoWVVkEinD05lMGP6+feLM+8i1qB0X6VJ0X9DRyquyJf8WkCdl81VTip7wCvBeSP5I38llaS9IBLHqLaUiCjJGKEqJsZyDrjQV701tEvqo+3bqQpexpdvRrXo3yR8LJtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=A+F9ydPzZQL7+HYXXydKkW6iHvplYGD6tVCXh+5X5vM=; b=dHHiZdsq6FSKNNb6zKxkyMci+7xO91jiMs0Mr7/wunsAcjoyNYywRolMdCy5Jf8yX0zsti9a02ueXkPABCOr/D7dlD2kn1XPnXUgfash4268v4UZR6LRgb4X+LGLBfw0KfvasASI/KBIMDNar1lPebZsiWP4XBeGaBdhzZgwpnhu0Vu+g1nhJGOMkrbba7Qel5DBQ924GmMHkH0Dgvmd/NC4SkyXjZctYzMksQtVF+4w4ENm9AMJWstWMAiMOAkRN/roK63o3/ciyrO0L5TxqmeT/YWvRjDPeDTX6Mbih/Z7yZDgKPXV3Cbd/GtVembQQNhx+K2QJR/uC7bXdgfYbg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=A+F9ydPzZQL7+HYXXydKkW6iHvplYGD6tVCXh+5X5vM=; b=QxFmj1llZa1nPMLTjm1J1xXyYS5TcBdnvmgdrZDUkdEzTw4wfDTaMadxR24t5ShxWko9Knr98ThvcbOPFcvGjXp2Wd19rDlf/+SVnyPGRqKl469zMYwPYIzAL4zqpOMM04trHTFjcB0q5IUYkbFLw1A+I4kYxoAnob5attFOVyY= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none; kernel.org; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DB3PR0402MB3916.eurprd04.prod.outlook.com (2603:10a6:8:10::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4065.21; Fri, 30 Apr 2021 04:55:44 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64%8]) with mapi id 15.20.4065.023; Fri, 30 Apr 2021 04:55:44 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, p.zabel@pengutronix.de, l.stach@pengutronix.de, krzk@kernel.org, agx@sigxcpu.org, marex@denx.de, andrew.smirnov@gmail.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ping.bai@nxp.com, frieder.schrempf@kontron.de, aford173@gmail.com, abel.vesa@nxp.com, Peng Fan Subject: [PATCH V2 1/4] dt-bindings: power: Add defines for i.MX8MM BLK-CTL power domains Date: Fri, 30 Apr 2021 13:27:43 +0800 Message-Id: <20210430052746.10815-2-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210430052746.10815-1-peng.fan@oss.nxp.com> References: <20210430052746.10815-1-peng.fan@oss.nxp.com> X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) To DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.25 via Frontend Transport; Fri, 30 Apr 2021 04:55:38 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 716c3e32-9262-4fa5-b577-08d90b9435bb X-MS-TrafficTypeDiagnostic: DB3PR0402MB3916: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1850; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: jCbqgNr5hhRD62lEUKL3WLN0AhUXg9gzkGufs3OKgfXxUvpPrmf/Cv5KkoBswZUtOFU8//0qfTNY0pzhmxZ8SMfgXe+1XKDBIVOdMm7CAd7r0vr/zPT7Obo3uRj/7VRT9gkAEZENqCV2rUg/01HnrU29j47fs4tHoz1SHxQN1NEhWDXLXiI3m2KAnedXAGxl2K9mphTKEHlH0JPygDVOydRcPI6sSRJKVY/YRglge6tws6xw8ztEvdASdOvttUPP2rEAstWt0tiL80kvo/jzZacuAEM5JdZWiwOdWGWBcak9JjRHugAloyZlds5cZ96zeHyeEzGhewgO5hI5mtGLWf9S7KMFYe1dmdFBq5u8labZPSOFvixD/Sqh40ZpDxDdsNzy7k5VtTHpFNtALcZpnWWGzxalSO25XcMvvafIqmuP8gGsSN8VXbj0O9qV3s8uH945gXM2pc2itufZC4zuV3NzNTQV40iph2ZReaf+4LY0UhB7GKfsY22a4A9HqxJSPpJnkgu5fchre5d2Q0EDuElcpMWXPTGl4SFZOUZ2fnQLxk2yqZf+xMLjripqkJu6BaFmUuEN+RTszRD68t+Hua0bzKyJdlx6Nd8XIrOhy8Gum1HVVgCozB7yfD7wopZ5/5iPa1GJkW5YV19JKY6AFw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB6PR0402MB2760.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(136003)(39850400004)(346002)(376002)(366004)(396003)(316002)(8936002)(5660300002)(66476007)(66946007)(7416002)(66556008)(4326008)(6512007)(6486002)(6666004)(16526019)(956004)(186003)(86362001)(2616005)(6506007)(1076003)(2906002)(38100700002)(38350700002)(8676002)(4744005)(478600001)(52116002)(26005); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: wRHH4qy3FNb2oGEn5a+Ysq6x/KJgLzOeU7WkkGE24YjPImzniXUMu5ItsE5DFWVsdcZLjfjnJRfXzSjtQYwkWpftuVOLsh0kTpnHLAVEufT/hbJAPw966NLwKoIICeeC1pugNOIOZaldrF+LBYbNbNS8I98zGwbQSG+ZAIbdeG85B0uFxPNUoZkLca4imGbmoaNCp3z7RWArO4WjlUYO1L9yrLhBYkbbx29dr3ZQESmzASao9D2j7w3rO6iZJj8CUCFWanPjDUv+dfY4yLb8Jimb5P0v6k4uOROahfUbSNpwTJALCHEip6V1tt7nLcCJXM7QhcPot2ERRfjC8KFI/FBDobBRNQsIr8HiSOBqVUPQVoAcpIOR4hBHJRhCU9Z6ddHZuAD3lTiOKf0VzBAcIPo2jYO4Doh7CqY76OSmC7ngQhu/umCW/gFLjPBsuSO4Ns5uB9lNfXn8xPOshwwTjWyHt+sVpKmdxiKzh1qm9i/ape0cqEFZF7hRYrcEm9AWuolLmo7DreotymACadoXAMeotH5b1p/hXBJovQh2ddpdIzwKRVy3GXB+GrLk0IoPkiA+rs+ExcxCe+DYQhbz5/eW5Yq/bFhKLL+ObxLf1Yx7WuIZtDdfKlioJ2hE+m++6uBxhYIc+Jg3N6uqIddPKK+3A/JbV1R7C7X64pPnWtE30HvpZA9OYF6rM5sBo0JJg4ENP6dbwRXeNxzNLqtl2z5YamCPmfiEyiW1FEptSNIvG03+mbnGDx56qN/lXeOgyu6KhFH7vwWlWBxJzB5NL2y2rMz4kFa2AHwHi7voUSrr85BvTmSk3TEwgCaAF0B+Twd2rSBF577DuAQUu61e4V6u00Megutf8LiCxZLuaajOGSCeMghnkYXkLwzNanNcIY/BBesr213QEpa1DCOgzDekOGmarKwIMnmhGd2qoGGJwj8Eu33C1ZEASmeWd/TotcCVv8fPfFZQcAGf0knlEdnG+0InUyHZYQSwek/8ckFlfQeMURI6a7fAXuerhOYo0n30SpJdY/pmbB5Tz277RkduyXkW882ESvPK2F0uwYGkE87UJI1TmeoN3xxFZK4MiSO5OzLPms067vN7Pw6uOciX2DwDH/bNr0CAifSeM6xTpJfbcUrnMCYRV+B8AUGMhUwv0ZYeipsg9ltjQGvtvOcyRHvXNzyfH4VHDXbDW3bdCfLBJEPyJ9vMVl2zB0Xo0lCBhLffVPplykXFvQah4tt7uHbnSyIS8LzYlwtZBav7bFOctICx4oR4TF1bfrgPXU+ACGFQfDrH/rWW8j9YzZ1FfcB0vIMWyFrvOwNfzTXBSYsWPXobd1JYcYbkKPjw X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 716c3e32-9262-4fa5-b577-08d90b9435bb X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Apr 2021 04:55:43.8823 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: g7zu4bQ+R1eidLKiFxFyCpNQV0bD8+EWEznoPgmDSWvj3Ty0JXxxQq0CSLEr6mF6d4jCAxYPJYBw0dnUbgrdNg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3916 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan Adding the defines for i.MX8MM BLK-CTL power domains. Signed-off-by: Peng Fan --- include/dt-bindings/power/imx8mm-power.h | 11 +++++++++++ 1 file changed, 11 insertions(+) -- 2.30.0 diff --git a/include/dt-bindings/power/imx8mm-power.h b/include/dt-bindings/power/imx8mm-power.h index fc9c2e16aadc..510e383d1953 100644 --- a/include/dt-bindings/power/imx8mm-power.h +++ b/include/dt-bindings/power/imx8mm-power.h @@ -19,4 +19,15 @@ #define IMX8MM_POWER_DOMAIN_DISPMIX 10 #define IMX8MM_POWER_DOMAIN_MIPI 11 +#define IMX8MM_BLK_CTL_G2_PD 0 +#define IMX8MM_BLK_CTL_G1_PD 1 +#define IMX8MM_BLK_CTL_H1_PD 2 +#define IMX8MM_BLK_CTL_MAX_PD 3 + +#define IMX8MM_BLK_CTL_DISPMIX_CSI_BRIDGE 0 +#define IMX8MM_BLK_CTL_DISPMIX_LCDIF 1 +#define IMX8MM_BLK_CTL_DISPMIX_MIPI_DSI 2 +#define IMX8MM_BLK_CTL_DISPMIX_MIPI_CSI 3 +#define IMX8MM_BLK_CTL_DISPMIX_MAX_PD 4 + #endif From patchwork Fri Apr 30 05:27:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 429755 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp91359jao; Thu, 29 Apr 2021 21:55:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzd5kGCUB7E9zm6s2V+PfRA7FYjViaZqVO4pMy1AE3d3LoQSjTGkaCjHoQzrAFVLk3gQf8S X-Received: by 2002:a17:902:7b8e:b029:ec:f35a:918e with SMTP id w14-20020a1709027b8eb02900ecf35a918emr3541121pll.77.1619758557919; Thu, 29 Apr 2021 21:55:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1619758557; cv=pass; d=google.com; s=arc-20160816; b=V8GpjOcs88q03lfRFpdYkJrFa+OoAH+K44Y7Lend6CYAh8txEXvFc5oYWtWqQly2Vq ETIz+mMo/6J3xTcslQMLeYjZCNd+jMX1qt74XxZSkp2urZGsMYf8vlTxopF+1kAjlShT 8yQdpwpmO7AisXbfScWp7cBbItTRVJcITpySB5cIZL7zBdvT5FpQwW9U3yrX2Ek0lTIl fR2Uy1nsnSqdLh3lte5oak6tx1oNjQo2cZ/R8TuCXIK/mtNKnwTLRlyibTIGbgOBGtvk GRlDHKGExHI4g2LM3jcCfgctocMlpf3c9jLsz6dsh+Np848xM6jpLg6L0JthIf/xh38+ Jz7w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=YR+u5uF7d7coX0epUL25kqfnOaANKttOKhr++MoUumA=; b=VKDBeqgfTaLwa20BGptHkew4fbVrEpZ25mkQYFtliLbGpKZ5uozCugmgPrF7zvDeZx LcGC6i835Veyj93IVORY9y38y3miYXzE6DvfQkKdeCcm0Wn/07Qv2lmfeRft3ioJNPY/ 9mdaDytysHuiljMFFTvClwGgVHc1eVJf0pfCjYUlJk9cdS9qtZZQomjK+Z9JKxgYij4l qX+2h8VXJ58j1UOxDAiIoFlXE9y+MX/nBzwzFZuJg9r7nFU4jS0wAWMlSRPDMiHCaPpM ij28yWVxGKJSd2geHfcs2HKfqxKih10xr2VAm0H7W6BFebcj8WX4xO+mu/P41AI0/oJ3 JYvA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=bBMeL2TC; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i10si919173pjx.40.2021.04.29.21.55.57; Thu, 29 Apr 2021 21:55:57 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=bBMeL2TC; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230203AbhD3E4k (ORCPT + 6 others); Fri, 30 Apr 2021 00:56:40 -0400 Received: from mail-eopbgr10045.outbound.protection.outlook.com ([40.107.1.45]:19013 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S230167AbhD3E4k (ORCPT ); Fri, 30 Apr 2021 00:56:40 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=n8oivMZ+Ohml8V4Po3EroeO+tMSYobowyfp4jDA2C8J3jImZbIoPKKRb+vv20BVV7LCZLBxxn0sMMGoWRkDhX00rg/y4YvoChgmq51Bm9xCeSWGkmsobXfyqvP80eq9oto3SpUUQJ+B5we9aKyJu8AZfMDZW1aYqHMTDMQad3sD7tNY9iRLMiV0h+mPgkj2Ibdn11G6uOhhTDPB2Ajdp4w63LCRtyM62rsPs/G8ROFKOMALA76gfKZ41iSqXc9+47K2AM8IrHcsbS8RdaV/TDL+UM8etlLpfBn6Syb1iUcg3jWPEkaphO7qra3D+jKPMSZYDmsefiqd4sm3L9lNNsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YR+u5uF7d7coX0epUL25kqfnOaANKttOKhr++MoUumA=; b=Xzqs/IOtd4J8MLoaFVZdPMg8jJhBpziCl7174mCSmQbDSh8TtPhf8/EZKquWODrmOHjNjip9pynH3WQh5hKWRmACnPFqQS7utP5muAuZAqBqvqQ89RK9l8kMm6YugETOO1qFQCBFZUwaK+ejk2PKF04FUIUPlnWFG1dBClm3YC8bB0mmb7W8pxYUJeRZBNwMKdiL122n+FCt+cC0V3OUr0X6/YvYcQ4GgDllZzPDZ8pskv0H/mgBnhwlukqUf0r/adHc/iu0k3Q3W4Uu4zSu8SpKzakr1CUp/PDel8jemUC0tpVDeCQr6/3zjzeozW7VgLFuTEH502l0LoFHS7JtHQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YR+u5uF7d7coX0epUL25kqfnOaANKttOKhr++MoUumA=; b=bBMeL2TCleG2ftTk0K70wuw9/5T64gS5W/jx3agd8lz7OOUILgFYWme4vXwaSLoXMf+4ZT/7qUqW5F19LfPSxwzdFicNzZz6Hjrpo4U1b8lVNreZICrepN5DhwMph2jNNzMOWR5OlbAqm6lLRZwL7tR9jZjwCCj4ejzLn/YmOuk= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none; kernel.org; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DB3PR0402MB3916.eurprd04.prod.outlook.com (2603:10a6:8:10::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4065.21; Fri, 30 Apr 2021 04:55:49 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64%8]) with mapi id 15.20.4065.023; Fri, 30 Apr 2021 04:55:49 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, p.zabel@pengutronix.de, l.stach@pengutronix.de, krzk@kernel.org, agx@sigxcpu.org, marex@denx.de, andrew.smirnov@gmail.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ping.bai@nxp.com, frieder.schrempf@kontron.de, aford173@gmail.com, abel.vesa@nxp.com, Peng Fan Subject: [PATCH V2 2/4] Documentation: bindings: clk: Add bindings for i.MX BLK_CTL Date: Fri, 30 Apr 2021 13:27:44 +0800 Message-Id: <20210430052746.10815-3-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210430052746.10815-1-peng.fan@oss.nxp.com> References: <20210430052746.10815-1-peng.fan@oss.nxp.com> X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) To DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.25 via Frontend Transport; Fri, 30 Apr 2021 04:55:44 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 16dd7b17-0232-4ac4-8fa1-08d90b94396c X-MS-TrafficTypeDiagnostic: DB3PR0402MB3916: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2887; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Q45s5D7yydEKIJlD2bTKicNAtDKfqe5wgkHtUsRijis8s73wDXMIVpxNX5MFawNF028rfaxHrdHNEmefpr+eUK6J3sHxv36XSbuhnrdLs2sSKHtcSJnjYBHo+NbBAHOQGjwTJc27NYJWj+G8slfl88uu7JC3e/izXW9xT5HM+1CaRL7WTiwAiK9prwISm3GJbTLXY3hXlf3CDdg9Rg8yYpBcXtZuwU4FkKuHCbNFkELMTg6jO7ed3rDWhj29ujifB8sE89FoyYJxvWYTJKmZU1SYNRvB787gGqBiLXodnMyaJLiyQ02awrWzxNRL5Sv19/lr+O13NU0XVgIYlV8ER4hL5nDSm1HAnnvBGxxU6uqFxrXRJKWY2kD1UIGABdHbinlvrTX2zxeVXzFc0dZVsAxqtV+O1Q7bwMdg9NBIxiEIYfiBo9H7irNIC4KCjUVu8381MY7uiXTYzRYxRxWaJNqaw17ZUEPdYpfwikQaJcIVmKed2z6If4rxIXg48brXXnxPeAHy8tmHZph6OhkSwto1LVk1H/5Ubsb3GHl9gha7nZsS8xbJNaLdiiZOVitwUbs2AgDCdYGNUp9A+iuXMdv8rbAyYIPzDgFbCcMQfp9Wtd7DL1BebRVQ6B05dMCHcM+JJMcpVxN8AUbQfWsuhoTg+GnVNtb3JY1eTL+8c3qrfXiTXbziskZjvpmEK94k/XB4+ZoXprenMAfl6w+il4H+cppPE2sdteoyuSqmNcE= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB6PR0402MB2760.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(136003)(39850400004)(346002)(376002)(366004)(396003)(316002)(8936002)(5660300002)(83380400001)(66476007)(66946007)(7416002)(66556008)(4326008)(6512007)(6486002)(16526019)(956004)(186003)(86362001)(2616005)(966005)(6506007)(1076003)(2906002)(38100700002)(38350700002)(8676002)(478600001)(52116002)(26005); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: kp8AFAbHDtYbDyT6ZFPamV/jatY5gQXiX0jGvLhgkh+qtKtMuZEIA+5cbI9gKPAtXfFtZCXP2MdnjLJnc5R9Bqty0rY6kJfABSg+IZLWpggFoa4kmGC8CuwC+VVmgbwdvPXqRQoJBn3Zxk51HDyIvN64OlE7+lIYSYVu2oFaZzuXO+5eZ5Nt0elCm5+tJlOTS85PiHoWt4CHO/j20+SP43pPYM5Og+L3OyqxeM2qPF7R4cdcvWYh6SIt3Z3E5jjXatTrj9ZVjqzWxNDcLaEb+kp3kgt0FoxSh5f2A44jvlV2rDe7udtFDkl49Bi6KEoVBTFjL0eCGXHR9x05BgBpOMCo4vntkctfP14lo/ftzVzFkW2Tm404Q242itsV9sIBJheMFpmjeUsUzPnxVVM7GJoqkU8kWFOuMG7J+AuRpBlYRRl4zTQmpnYWfq5IgSV6Q1EtMIFzDTyoybcYJB+/JyIP6AjWycKFlG1rvTF8cTlDO7aztE7UJMeB9md4Ggd9j1L3Udj71giAToPUormZ7S8p9kPAiQH3vKCw4TOa0YvSPtwTnE6eckTzmPqe/wu/bgsD+f+nxh7NqsIROwzqj6i9pqy3rfRZix8nSjg69/lddMy8LZAzaccxvy4Ouo87Tjfg6S5JSO//HJKZkmywh7PnK3OoftGPlK3Pvj8UKCSPK8jgGv9XH8oP5ghMrTyUOT91hD3PLkmEu3yj0wn6nr37LJvblIncM1ddzJx9jfxM1bxzOJiGrnYVJQLuAxv6nEofen9ayK8GrP9qvZ295X8xJv7VdKkXSzNuR7zoaDBKSBUDkyFGHE9dXcHx3cfxGEcPvMSkiBVBqM7GCSxYh4xIR7nDFwqpf8z6xI6pRlUhmKiSp/DKYsRn4IRE1qHO0ug8nZjWZwhDd0F3a4wlWGmeDDTuG1LVrlNLNA1ofIRpRye3dauTQpBxkhIhUwSvSuDHMK5Zku297xm8DlM1O+KD9who+CdzQsK5CduslJfk0AutDfSmBA2Sz58UslDZ3olB27Iq/XLvwrvhrp1dIqVJkYkzaEHAxN8fRLNOcrMU4sy1PwACWuq2z0GJi5z/QjroIRtIOrY8gymlUnnoK8zRr4lygefUvh2LTPKiK5icZ75V1Y5bG8bjsso1U6lPv7YI9AG/Z9nDx/svgjxVqVY4XNkalMR06gJ51Q1XLBYr4TK+mEaXkfspxyyxoBF5fC0winUgdsI+Qw4LcjHnSLjgoTD9/Y/ofJxTz3xK1SGgegw+rczFzV0nMaA9fsFIdYF+eD+W+CSNJh8xZxYOdO7DQvi5n/LRS0NDnLQvT/DpEYvQbG3EvE5DWafM4R+r X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 16dd7b17-0232-4ac4-8fa1-08d90b94396c X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Apr 2021 04:55:49.8176 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ATCj9rYc/4zdbCu4ym8EERAuR/K01XzNr5EaIeSpgObbzKlnowclrT/GktS9vmH2mJpGYpS23e89j7DJYVmJQw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3916 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan Document the i.MX BLK_CTL with its devicetree properties. Signed-off-by: Peng Fan --- .../bindings/soc/imx/fsl,imx-blk-ctl.yaml | 73 +++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 Documentation/devicetree/bindings/soc/imx/fsl,imx-blk-ctl.yaml -- 2.30.0 diff --git a/Documentation/devicetree/bindings/soc/imx/fsl,imx-blk-ctl.yaml b/Documentation/devicetree/bindings/soc/imx/fsl,imx-blk-ctl.yaml new file mode 100644 index 000000000000..a491b63de50c --- /dev/null +++ b/Documentation/devicetree/bindings/soc/imx/fsl,imx-blk-ctl.yaml @@ -0,0 +1,73 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/soc/imx/fsl,imx-blk-ctl.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP i.MX BLK_CTL + +maintainers: + - Peng Fan + +description: + i.MX BLK_CTL is a conglomerate of different GPRs that are + dedicated to a specific subsystem. It usually contains + clocks and resets amongst other things. Here we take the clocks + and resets as virtual PDs, the reason we could not take it as + clock provider is there is A/B lock issue between power domain + and clock. + +properties: + compatible: + items: + - enum: + - fsl,imx8mm-dispmix-blk-ctl + - fsl,imx8mm-vpumix-blk-ctl + - const: syscon + + reg: + maxItems: 1 + + "#power-domain-cells": + const: 1 + + power-domains: + minItems: 1 + maxItems: 32 + + power-domain-names: + minItems: 1 + maxItems: 32 + + '#reset-cells': + const: 1 + + clocks: + minItems: 1 + maxItems: 32 + + clock-names: + minItems: 1 + maxItems: 32 + +required: + - compatible + - reg + - power-domains + +additionalProperties: false + +examples: + - | + #include + + dispmix_blk_ctl: blk-ctl@32e28000 { + compatible = "fsl,imx8mm-dispmix-blk-ctl", "syscon"; + reg = <0x32e28000 0x100>; + #power-domain-cells = <1>; + power-domains = <&pgc_dispmix>, <&pgc_mipi>; + power-domain-names = "dispmix", "mipi"; + clocks = <&clk IMX8MM_CLK_DISP_ROOT>, <&clk IMX8MM_CLK_DISP_AXI_ROOT>, + <&clk IMX8MM_CLK_DISP_APB_ROOT>; + clock-names = "disp", "axi", "apb"; + }; From patchwork Fri Apr 30 05:27:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 429756 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp91482jao; Thu, 29 Apr 2021 21:56:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx03O9o5keVxXeVN2sVYreWHkJmOV39ywv1e/+Ih8ThyrJCM4IDw78mBvQifBoFWgrKTlkw X-Received: by 2002:a63:be43:: with SMTP id g3mr2971631pgo.191.1619758569847; Thu, 29 Apr 2021 21:56:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1619758569; cv=pass; d=google.com; s=arc-20160816; b=IYeL4IA5fuXhMLzKsFqQYkhPnbdb1ju5M1sNb5ItzA+kJkRMHx+ZOS3cWX3HQ0DhD7 zaKje6lXBjlBnbhj92DTQ2GNX7mnNzpHJhj1A4cF7ZNpw4fZ8jIGLQIF8k9GhzuQ2DJx MmIRUF3msG8luOmIPQAtClfgX7QoUi6p8qQgc7nHAur8DUvVDiYAhtDKxLGosbnXLQUC 6G+EHXDKanJqX/3YK1GuD7/yiRMhlMOGUxM1KcUXf3GhLiU7Z3MAWyDEWMMopsuzbpvN jhHdjA0+lNKDkscJs+ZOtJ5M5wNYaale75V8hUtNJra6vCA3f+V0bqpFR5HyZnNnKHsc ulPw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=+BWnfzYybWl/scTuY5FD9VOLt2LECai+WE378UnVPK0=; b=voRbYWAnS2p5RZ2H8qAfHyU4OJOcPmZAnNwbu0aDl8SS3dAcVFi8OD5W5YRcYxkPkF EF8xqmtD6+IUG2zCAbkCy4LHFAGx+ile4T2Uxy93472bvWKznkMBcC3dogzmxu5JBj4D gYoMj7WL97Hzb+NPTPxPzbKd2EF9ODWHjqF1w1x2/7MsrDuE8SXIOUcXQwOCLSDTT/qi iY5tG21LceIdbe8l1S7hsqjngboy9SlLbZL7qv8d2jsYeFMLje68IBE85PsjzDut+Xq0 DuWx4Zke5MskYAOAsTQeGk9XR46Lzt5yY9bJ/sVOFddLNYzAW54Q5gnE4Bmh8g1AmfBJ Fjlg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=bFWHLIuQ; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i10si919173pjx.40.2021.04.29.21.56.09; Thu, 29 Apr 2021 21:56:09 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=bFWHLIuQ; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230167AbhD3E4y (ORCPT + 6 others); Fri, 30 Apr 2021 00:56:54 -0400 Received: from mail-eopbgr10071.outbound.protection.outlook.com ([40.107.1.71]:36610 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S230263AbhD3E4q (ORCPT ); Fri, 30 Apr 2021 00:56:46 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=O60/GXJv3qB6wFgZUruVhuM6PYaPLYZ+b9RW8Uk0d+SpxVXpInPT70IU+dGYthoYHhRuguOWY4VtwlCo3xPX5+BmuGa48gY+4nceogIJcsntBuJu/wZIpkR6/rhoz4XHD+NeC5urpMFkoneDGl0onTx5HnBHbNky7MFEyFo4WKjbVPjAv0map8Rbp08NidWOXx/7ZKWOyoP5K5qMxrYAvkHSuILszbN5Ii25PvMwTIn+EmJ/DNOwO0zCgnE2S8DNGRB+xrtBdleXnsiAGGVOwh518m353s1+5iiG19mZSb5lavG+BVb4cnvpOw0npbDRg+7CP1QVLSU60GMV8bKYEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+BWnfzYybWl/scTuY5FD9VOLt2LECai+WE378UnVPK0=; b=f3xVMKPORuucII5WkbCdwVV5YhxETzx4Ke6YSQuBRGvU4cirQomVJ+T9udFdzX3JxKnb8I8qk/EvUWkLRIy42xLIUjr4NQB9EBM0G3C/kXdQh/cjI6DfKGZ98qqz31gishOSZq12bGJJIDujUHNbJ/bLqjst3tFNGzWrxp8mQAWzCBjVvoNK0D5rqZe/uPE31QH5kUJXulgPEkM7uIw6DldwwF+j+jAPEwngtoLTAU2fQ6o3vCRulDVUOmxE3/nqd7MX9EWRVvEpf6yAhBxqUKQAEj9TNsxaAtAQEd9ztSkzeZM6iPDp20qA9AHxrK2DhvkB5H5E2VTv7YkNEmJJpg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+BWnfzYybWl/scTuY5FD9VOLt2LECai+WE378UnVPK0=; b=bFWHLIuQMAKQQ1hHwu6nCDZ2ndxfSpX/3z45WTB/BC853GJRo2rHO08icS5sl8VEcUwmwxynxdBHvrzfXXvtD2zvIA0/GwS7Jzwgos9de1MENI7svYOTtb6UMMl1lUEEgJtwhHfrtRSYp4yk3y/2dt0d5kDsr5pcA2vO8z2uoGM= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none; kernel.org; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DB3PR0402MB3916.eurprd04.prod.outlook.com (2603:10a6:8:10::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4065.21; Fri, 30 Apr 2021 04:55:55 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64%8]) with mapi id 15.20.4065.023; Fri, 30 Apr 2021 04:55:55 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, p.zabel@pengutronix.de, l.stach@pengutronix.de, krzk@kernel.org, agx@sigxcpu.org, marex@denx.de, andrew.smirnov@gmail.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ping.bai@nxp.com, frieder.schrempf@kontron.de, aford173@gmail.com, abel.vesa@nxp.com, Peng Fan Subject: [PATCH V2 3/4] soc: imx: Add generic blk-ctl driver Date: Fri, 30 Apr 2021 13:27:45 +0800 Message-Id: <20210430052746.10815-4-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210430052746.10815-1-peng.fan@oss.nxp.com> References: <20210430052746.10815-1-peng.fan@oss.nxp.com> X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) To DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.25 via Frontend Transport; Fri, 30 Apr 2021 04:55:50 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f58ba903-0fd3-48bf-dc40-08d90b943cf2 X-MS-TrafficTypeDiagnostic: DB3PR0402MB3916: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3044; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: aMu3v4qY9hRsXyVhXA6S24pqu06Ni+TxYoIPbBx3IQyjSM+bkKodQHnRQfp2yyEypK6+kKgqfi3KYoUr1QEWSRQSyxLS1AM8TE+QUcGXVx+VSyOVZ0SOeWdPuXdURHVSjls1Lnksq14iViGFVKCqnY/9Db29gp/YmqdYoQ0NeFTMX3Rh1bJwVaNBMbKvaA9G6izItoUjefPgbAcn4N4JX2z5qHMyq8f6MqfO2rX8mvm9rQsvqqRSwFEAsdJRlFa9lZ22fuluDJbFBWfIVYgbrmnNjJPX3O+0rx4kjhqUJeSU9Xx5u9IpXXo4Bt3s/oFWuPCx7xUrluyu846gIqi9QJvDQg4LihNVzOUAFx/SGz2PxcIhg7X40P5Vff6ameH0upop6EVQgC2lV3bddbReN0BIcTmKoqUF58D/Wb26J+Da0gTIrpDtQTbgrCq+I/ikgBvxlXKxTT2tL2DXb90m1d9/FvfIk6NGGy1VPutkgT78lysUtYVn9mX3ljkHL7V3JIdMy+ufit3N0GYxEnPbJZh0JD4x9WKDCTLSMfGTrNCP9drJTliMnm1/Jtui8TSSH4kChTzCTt2T+7HNvgyg0hin4K4aHElSgzc37UYKggMksoXwsD8W4K+gBpr1XFtRfmMmSw/fU29zfPcwRN7dscEVrPbVq6k928SkofLQCApPAYVwsZ6DCvaiRA4ChnBy X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB6PR0402MB2760.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(136003)(39850400004)(346002)(376002)(366004)(396003)(316002)(8936002)(5660300002)(83380400001)(66476007)(66946007)(7416002)(66556008)(4326008)(6512007)(6486002)(6666004)(16526019)(956004)(186003)(86362001)(2616005)(6506007)(1076003)(2906002)(38100700002)(38350700002)(8676002)(478600001)(52116002)(26005)(30864003)(41533002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: OE3gEpDZT372i1eh5G7TKbEBd7C7cwqdxeLT6nyAZTvQq4k1nl8teVERWg8R81KPKzMJqE3vay6r0JiMo+uMH9Fu2jd91R/Gcc8EWpbCXy+K0JNbAYJc8E9CLeMmImwEqJeUiPFQ1+AwVLPvoSn8wFHLXpoaoPs7p6B5AvmqBf6jG7drzHNnixg/VMYKiYVST4TJsVS/1oBRmDcattBUBtWgFQxSTne6GjBSeGWj45b8xbDt2o1I45mCCGHwOl4SBDkjSyLsP5vXyW+Ha1Zyy3ZM10VvxF6zkRv0mB1gghLAPUW8TtT6B8GXK98++L2W2czgF6YdWxXdofUHCIJ3wXCPBZl0J70M2DeIAZ9XzsmeSnWCEyJLmIeuMR61yL55Q5LeWXzbX2kvnAZEZITv66eRPvYqUO1jiVIJsiWCy/ZBwMQSd92BMrFpxIq1FVEBFAW7SN2yZxzyUwjqv8wTU0FEoi+3KsPFE93PxnD95yMRjtZT+O6t4mwbMCD6wuRVlP37fZLn5ikkUoWnS+2EKBaysa0fb06VnHEiB/Uy1AQSWyjV8gTq0PznFBVFSt+jDCj8xV1vs9jXViYu2QsEaJGeT06Luy+5/xrXIb5b9r7tACMz6MFlsPcLa3Uexy4/VRo3wpIxuGZ+pOd+rYt8t0zefcAtrlVG3AczhoZOAksvWB1nN1/Cy4zmtSG9FO3jzJuQ0Pic6GEY3AQhun5HhSg59on87PaTripiKddoXyWGcNkIHIOHtrNJCNiKFz3gK6WHeIMT1mGnfwhelJPdmqxnATZB2tq90NK9mrhfWZwlNYTXb1bEuFvYPV3MNRJLbnI129303lJwaBnKyP/jRSAAxh4W4tzEV7CsxzvGfMjxg1VSth9AAaQicPvjoU8mf7pG9+VGpKTGkigZnOEMoXJmhpfRjnjt7300mDL+fDdXcZITBf27IwCYMlONIQBahFD9hKyCnr/WZr7KUthuTPjeN+76/g/JgdeR015hnGrRvA2xCTIXSTyG5eNkw0eF/GE4gw6hkNEP0JM7yISBVJXa0g9ec3c0xK2Zbh+pw9QGZ0s2wBKq7mjAGhahGLxj924KQaK9E5ybdnUS9jYZIqLAMHBGDXhhrTec+HKwLE6WqPNiGbfh9D+XvwujxyQiyX5IgUkpyrrpFWrH0oa+OSLpD/KYfkTnG1ZMj2HVuIc6J0FjkfYG4uXXvko4I0Tr+3ARMSCWk2/cu6SwyRJ9LXlgC1S/Fdd11qFxjXcWjPhv6bbdLzp321O4EKTUUgmwuWDMHeCHpbYQa2NRRWPxTxQPlRwjxG7+bEgEIJ8U87Qx4FQDmZAa0j70LrPulojt X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: f58ba903-0fd3-48bf-dc40-08d90b943cf2 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Apr 2021 04:55:55.7599 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: xPGTroPYaCMd8tGTLJQSJD5B6KgDi41qdAM0g9/NZonugLrhwl5bOBabbGCCj9C3ifVUUPWLrEGcZC4BH4yvdA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3916 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan The i.MX8MM introduces an IP named BLK_CTL and usually is comprised of some GPRs. The GPRs has some clock bits and reset bits, but here we take it as virtual PDs, because of the clock and power domain A/B lock issue when taking it as a clock controller. For some bits, it might be good to also make it as a reset controller, but to i.MX8MM, we not add that support for now. Signed-off-by: Peng Fan --- drivers/soc/imx/Makefile | 2 +- drivers/soc/imx/blk-ctl.c | 303 ++++++++++++++++++++++++++++++++++++++ drivers/soc/imx/blk-ctl.h | 76 ++++++++++ 3 files changed, 380 insertions(+), 1 deletion(-) create mode 100644 drivers/soc/imx/blk-ctl.c create mode 100644 drivers/soc/imx/blk-ctl.h -- 2.30.0 diff --git a/drivers/soc/imx/Makefile b/drivers/soc/imx/Makefile index 078dc918f4f3..d3d2b49a386c 100644 --- a/drivers/soc/imx/Makefile +++ b/drivers/soc/imx/Makefile @@ -4,4 +4,4 @@ obj-$(CONFIG_ARCH_MXC) += soc-imx.o endif obj-$(CONFIG_HAVE_IMX_GPC) += gpc.o obj-$(CONFIG_IMX_GPCV2_PM_DOMAINS) += gpcv2.o -obj-$(CONFIG_SOC_IMX8M) += soc-imx8m.o +obj-$(CONFIG_SOC_IMX8M) += soc-imx8m.o blk-ctl.o diff --git a/drivers/soc/imx/blk-ctl.c b/drivers/soc/imx/blk-ctl.c new file mode 100644 index 000000000000..1f764dfd308d --- /dev/null +++ b/drivers/soc/imx/blk-ctl.c @@ -0,0 +1,303 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright 2021 NXP. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "blk-ctl.h" + +static inline struct imx_blk_ctl_domain *to_imx_blk_ctl_pd(struct generic_pm_domain *genpd) +{ + return container_of(genpd, struct imx_blk_ctl_domain, pd); +} + +static int imx_blk_ctl_enable_hsk(struct device *dev) +{ + struct imx_blk_ctl *blk_ctl = dev_get_drvdata(dev); + const struct imx_blk_ctl_hw *hw = &blk_ctl->dev_data->hw_hsk; + struct regmap *regmap = blk_ctl->regmap; + int ret; + + + if (hw->flags & IMX_BLK_CTL_PD_RESET) + ret = regmap_update_bits(regmap, hw->rst_offset, hw->rst_mask, hw->rst_mask); + + ret = regmap_update_bits(regmap, hw->offset, hw->mask, hw->mask); + + /* Wait for handshake */ + udelay(5); + + return ret; +} + +int imx_blk_ctl_power_off(struct generic_pm_domain *domain) +{ + struct imx_blk_ctl_domain *pd; + struct imx_blk_ctl *blk_ctl; + const struct imx_blk_ctl_hw *hw; + struct regmap *regmap; + int ret; + + pd = to_imx_blk_ctl_pd(domain); + blk_ctl = pd->blk_ctl; + regmap = blk_ctl->regmap; + hw = &blk_ctl->dev_data->pds[pd->id]; + + ret = clk_bulk_prepare_enable(blk_ctl->num_clks, blk_ctl->clks); + if (ret) + return ret; + + ret = regmap_update_bits(regmap, hw->offset, hw->mask, 0); + if (ret) + goto hsk_fail; + + if (hw->flags & IMX_BLK_CTL_PD_RESET) + ret = regmap_update_bits(regmap, hw->rst_offset, hw->rst_mask, 0); + + if (atomic_dec_and_test(&blk_ctl->power_count)) { + ret = imx_blk_ctl_enable_hsk(blk_ctl->dev); + if (ret) { + dev_err(blk_ctl->dev, "Hankshake fail\n"); + goto hsk_fail; + } + } + +hsk_fail: + clk_bulk_disable_unprepare(blk_ctl->num_clks, blk_ctl->clks); + + return ret; +} + +int imx_blk_ctl_power_on(struct generic_pm_domain *domain) +{ + struct imx_blk_ctl_domain *pd; + struct regmap *regmap; + const struct imx_blk_ctl_hw *hw; + int ret; + struct imx_blk_ctl *blk_ctl; + + pd = to_imx_blk_ctl_pd(domain); + blk_ctl = pd->blk_ctl; + regmap = blk_ctl->regmap; + hw = &blk_ctl->dev_data->pds[pd->id]; + + ret = clk_bulk_prepare_enable(blk_ctl->num_clks, blk_ctl->clks); + if (ret) + return ret; + + if ((atomic_read(&blk_ctl->power_count) == 0)) { + ret = imx_blk_ctl_enable_hsk(blk_ctl->dev); + if (ret) { + dev_err(blk_ctl->dev, "Hankshake fail\n"); + goto disable_clk; + } + } + + if (hw->flags & IMX_BLK_CTL_PD_RESET) + ret = regmap_update_bits(regmap, hw->rst_offset, hw->rst_mask, 0); + + /* Wait for reset propagate */ + udelay(5); + + if (hw->flags & IMX_BLK_CTL_PD_RESET) + ret = regmap_update_bits(regmap, hw->rst_offset, hw->rst_mask, hw->rst_mask); + + ret = regmap_update_bits(regmap, hw->offset, hw->mask, hw->mask); + if (ret) + goto disable_clk; + + atomic_inc(&blk_ctl->power_count); + +disable_clk: + clk_bulk_disable_unprepare(blk_ctl->num_clks, blk_ctl->clks); + + return ret; +} + +static int imx_blk_ctl_attach_pd(struct device *dev, struct device **devs, char **pd_names, + u32 num_pds) +{ + int i, ret; + + if (!pd_names) + return 0; + + if (dev->pm_domain) { + devs[0] = dev; + pm_runtime_enable(dev); + return 0; + } + + for (i = 0; i < num_pds; i++) { + devs[i] = dev_pm_domain_attach_by_name(dev, pd_names[i]); + if (IS_ERR_OR_NULL(devs[i])) { + ret = PTR_ERR(devs[i]) ? : -ENODATA; + goto detach_pm; + } + } + + return 0; + +detach_pm: + for (i--; i >= 0; i--) + dev_pm_domain_detach(devs[i], false); + + return ret; +} + +static int imx_blk_ctl_register_pd(struct device *dev) +{ + struct imx_blk_ctl *blk_ctl = dev_get_drvdata(dev); + const struct imx_blk_ctl_dev_data *dev_data = blk_ctl->dev_data; + int num = dev_data->pds_num; + struct imx_blk_ctl_domain *domain; + int i, ret; + + blk_ctl->onecell_data.num_domains = num; + blk_ctl->onecell_data.domains = devm_kcalloc(dev, num, + sizeof(struct generic_pm_domain *), + GFP_KERNEL); + + if (!blk_ctl->onecell_data.domains) + return -ENOMEM; + + for (i = 0; i < num; i++) { + domain = devm_kzalloc(dev, sizeof(*domain), GFP_KERNEL); + if (!domain) { + ret = -ENOMEM; + goto remove_genpd; + } + domain->pd.name = dev_data->pds[i].name; + domain->pd.power_off = imx_blk_ctl_power_off; + domain->pd.power_on = imx_blk_ctl_power_on; + domain->blk_ctl = blk_ctl; + domain->id = i; + + ret = pm_genpd_init(&domain->pd, NULL, true); + if (ret) + return ret; + + blk_ctl->onecell_data.domains[i] = &domain->pd; + } + + return 0; + +remove_genpd: + for (i = i - 1; i >= 0; i--) + pm_genpd_remove(blk_ctl->onecell_data.domains[i]); + + return ret; +} + +static int imx_blk_ctl_hook_pd(struct device *dev) +{ + struct imx_blk_ctl *blk_ctl = dev_get_drvdata(dev); + const struct imx_blk_ctl_dev_data *dev_data = blk_ctl->dev_data; + const struct imx_blk_ctl_hw *pds = dev_data->pds; + int num_active_pd = dev_data->num_active_pd; + int num = dev_data->pds_num; + struct generic_pm_domain *genpd, *child_genpd; + int ret; + int i, j; + + blk_ctl->active_pds = devm_kcalloc(dev, num_active_pd, sizeof(struct device *), GFP_KERNEL); + if (!blk_ctl->active_pds) + return -ENOMEM; + + ret = imx_blk_ctl_attach_pd(dev, blk_ctl->active_pds, dev_data->active_pd_names, + num_active_pd); + if (ret) { + if (ret == -EPROBE_DEFER) + return ret; + dev_err(dev, "Failed to attach active pd: %d\n", ret); + return ret; + } + + for (i = 0; i < num; i++) { + for (j = 0; j < num_active_pd; j++) { + genpd = pd_to_genpd(blk_ctl->active_pds[j]->pm_domain); + if (!strcmp(genpd->name, pds[i].parent_name)) + break; + } + + child_genpd = blk_ctl->onecell_data.domains[i]; + if (pm_genpd_add_subdomain(genpd, child_genpd)) + pr_warn("failed to add subdomain:\n"); + } + + return 0; +} + +int imx_blk_ctl_register(struct device *dev) +{ + struct imx_blk_ctl *blk_ctl = dev_get_drvdata(dev); + const struct imx_blk_ctl_dev_data *dev_data = blk_ctl->dev_data; + int num = dev_data->pds_num; + int i, ret; + + if (!blk_ctl) + return -ENODEV; + + ret = imx_blk_ctl_register_pd(dev); + if (ret) + return ret; + + ret = imx_blk_ctl_hook_pd(dev); + if (ret) + goto unregister_pd; + + ret = of_genpd_add_provider_onecell(dev->of_node, &blk_ctl->onecell_data); + if (ret) + goto detach_pd; + + pm_runtime_get_noresume(dev); + pm_runtime_set_active(dev); + pm_runtime_enable(dev); + + pm_runtime_put(dev); + + return 0; + +detach_pd: + for (i = blk_ctl->dev_data->num_active_pd; i >= 0; i--) + dev_pm_domain_detach(blk_ctl->active_pds[i], false); +unregister_pd: + for (i = num - 1; i >= 0; i--) + pm_genpd_remove(blk_ctl->onecell_data.domains[i]); + + return ret; +} +EXPORT_SYMBOL_GPL(imx_blk_ctl_register); + +static int __maybe_unused imx_blk_ctl_runtime_suspend(struct device *dev) +{ + return 0; +} + +static int __maybe_unused imx_blk_ctl_runtime_resume(struct device *dev) +{ + return 0; +} + +const struct dev_pm_ops imx_blk_ctl_pm_ops = { + SET_RUNTIME_PM_OPS(imx_blk_ctl_runtime_suspend, + imx_blk_ctl_runtime_resume, NULL) + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, + pm_runtime_force_resume) +}; +EXPORT_SYMBOL_GPL(imx_blk_ctl_pm_ops); diff --git a/drivers/soc/imx/blk-ctl.h b/drivers/soc/imx/blk-ctl.h new file mode 100644 index 000000000000..e736369406a1 --- /dev/null +++ b/drivers/soc/imx/blk-ctl.h @@ -0,0 +1,76 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef __SOC_IMX_BLK_CTL_H +#define __SOC_IMX_BLK_CTL_H + +enum imx_blk_ctl_pd_type { + BLK_CTL_PD, +}; + +struct imx_blk_ctl_hw { + int type; + char *name; + char *parent_name; + u32 offset; + u32 mask; + u32 flags; + u32 id; + u32 rst_offset; + u32 rst_mask; +}; + +struct imx_blk_ctl_domain { + struct generic_pm_domain pd; + struct imx_blk_ctl *blk_ctl; + u32 id; +}; + +struct imx_blk_ctl_dev_data { + struct regmap_config config; + struct imx_blk_ctl_hw *pds; + struct imx_blk_ctl_hw hw_hsk; + u32 pds_num; + char **active_pd_names; + u32 num_active_pd; +}; + +struct imx_blk_ctl { + struct device *dev; + struct regmap *regmap; + struct device **active_pds; + u32 pds_num; + u32 active_pd_count; + struct genpd_onecell_data onecell_data; + const struct imx_blk_ctl_dev_data *dev_data; + struct clk_bulk_data *clks; + u32 num_clks; + + atomic_t power_count; +}; + +#define IMX_BLK_CTL(_type, _name, _parent_name, _id, _offset, _mask, _rst_offset, _rst_mask, \ + _flags) \ + { \ + .type = _type, \ + .name = _name, \ + .parent_name = _parent_name, \ + .id = _id, \ + .offset = _offset, \ + .mask = _mask, \ + .flags = _flags, \ + .rst_offset = _rst_offset, \ + .rst_mask = _rst_mask, \ + } + +#define IMX_BLK_CTL_PD(_name, _parent_name, _id, _offset, _mask, _rst_offset, _rst_mask, _flags) \ + IMX_BLK_CTL(BLK_CTL_PD, _name, _parent_name, _id, _offset, _mask, _rst_offset, \ + _rst_mask, _flags) + +int imx_blk_ctl_register(struct device *dev); + +#define IMX_BLK_CTL_PD_HANDSHAKE BIT(0) +#define IMX_BLK_CTL_PD_RESET BIT(1) +#define IMX_BLK_CTL_PD_BUS BIT(2) + +const extern struct dev_pm_ops imx_blk_ctl_pm_ops; + +#endif From patchwork Fri Apr 30 05:27:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 429757 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp91504jao; Thu, 29 Apr 2021 21:56:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxUH2GrzQhLTYGMB/+dVcWLWX/GJTumA+9uWXMQEEK1VhUBBhdolASkIFD4Me2v7tNuByQ6 X-Received: by 2002:a17:902:aa06:b029:ec:c083:8787 with SMTP id be6-20020a170902aa06b02900ecc0838787mr3179196plb.45.1619758571746; Thu, 29 Apr 2021 21:56:11 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1619758571; cv=pass; d=google.com; s=arc-20160816; b=I/YyY2Zjh1GJJXRhUkfVf5umz0zHqYiBOIg+YZWcdGGlEc4NhMbWeR8Ak3Vbcx8pWA JzTDqtcix/5CXljY58LtiCwbSDk/yi9XJdzgqIupAJ7o48TdXJmC4yZDz3o6ioIP4hxZ ZFpF3SnO34HhrJF0t10YNDl/KJYy/9mph/uccu7rrsGN2BzwC1XrUwMcuUmoHr3PwBnM Er6LwKcK5oY9dVMoi2RKfYwbqVWvJXM6Dz9rDQWILgn2CpkpMrYWge9bJCA+ISqFH4nD jRcaWMw2F8pB+hh42ltkj63I3l3TwOspGF/XVdHwtQVkXHCe+3xYtBZwwuGmvBd9y6TC 9nrw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=h15TxzHnPEFPnun3tKl5O+7Y9A7E+k+i03nQ5iN1Pdk=; b=0Vm1SyxOxkCQF7gQTt7mADKNPBYLxBHAW+tnQQ5aSLqUgP3uiqhW4lJRu3XK9h9PS9 5S1ls3nqmSzZzhNjVxTc9+zycMkZS0vlr7e39SrOJQFgH1wfJ0o9BlUDgI60ns6qvJNR 6yJeVYwXIsH64Q0w8MRHiLPjJvK5Sutn4w5YLVPyW7qOxC7o4y+XO/rjP4LGjEgPui0q aA2PpITG20zT5i5ibPKnoX4OYFGqt21pnHAsBUVinAJk70muw16dzEThcRHXf1qAXBXi 5xVnexRwb4NUQvzgWW2V5/yi50B+v+a9x1vXl3lOPAP9oqOplW95STsKcYk0ynf7uEea ObWQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=aKhSct2S; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i10si919173pjx.40.2021.04.29.21.56.11; Thu, 29 Apr 2021 21:56:11 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=aKhSct2S; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230182AbhD3E45 (ORCPT + 6 others); Fri, 30 Apr 2021 00:56:57 -0400 Received: from mail-eopbgr10071.outbound.protection.outlook.com ([40.107.1.71]:36610 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S229977AbhD3E4z (ORCPT ); Fri, 30 Apr 2021 00:56:55 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jWREmLJUz2edw3mNpklKpe95dlMFf5r+GxZi1EGR3eo0ASwtDqVh0M/TUA1yIJ/q79eqLIKngaQFJmRjKleiKI1PQ7hIICVLLkt4EiQ7hfbFppO6NtfzHtWNc7cQbEhfLWcSkLSqRHX9kTj/Lc36oMQsDLmNtN6WdGo2LUtStREO55eR5cEfETokfrghti4IlwfWmCqsZjjmUcyg684ndQ8n2LAOVAoaluG+a6/3Cuu3/UbDRtIsilvDfV+dhFWTuln+KB0sqH2rWzMC7V10Y8z8YWZ6/Hgy5zB2R7T5jLHQ8wdtEM8kUihwaBYvXiqZkYbHbY8L6SjT79yTUOyolQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=h15TxzHnPEFPnun3tKl5O+7Y9A7E+k+i03nQ5iN1Pdk=; b=i0t05nlJZHH2NHrATpColsWiNn5fb7sY3ew4aBH+NmR7NX1bo7qckCkh9xibzlg8jm4z0Z92txfJ5S5X+yr5E3xyQLs36XUdlzByD4MBFdANjMmMqZ82pL0V5OaW/acSTEb0EbiKV4Q2uEv6uIlQgH3A+VoK7DnM8uIWnWst8B0Fc5iT4RgyZ9Ec2LfzbXYRa4zKZYaJOkLWF4HPh0bCQIyLVEVj3ew3M/L2X0pgdpxtjqikjf+Q+ss5sSi/Fry24j9iAcowxnfgtXKIUtYyre720wCGE7zJ95jmYgp+Aod+n+lrgsDOvCqqB0GIb1aM0yhKaMJUJn3VSU8w34ThOw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=h15TxzHnPEFPnun3tKl5O+7Y9A7E+k+i03nQ5iN1Pdk=; b=aKhSct2S0gzmQ3VE/rNdVhz20lo0VqIFIAdTXITQIxOcQ0+VB30A+J/QyfxeBuB/DS/5kH/R5Ah+ycCfHeY2AzS9S5XWoD5EsPw24hAxkQgXt9kNPvPTqAuGVCCVhJY5o4YJFYR8LY6GewyU+lL7hfwVcbXdzvJ3c6LRE9yyoJU= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none; kernel.org; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DB3PR0402MB3916.eurprd04.prod.outlook.com (2603:10a6:8:10::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4065.21; Fri, 30 Apr 2021 04:56:01 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64%8]) with mapi id 15.20.4065.023; Fri, 30 Apr 2021 04:56:01 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, p.zabel@pengutronix.de, l.stach@pengutronix.de, krzk@kernel.org, agx@sigxcpu.org, marex@denx.de, andrew.smirnov@gmail.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ping.bai@nxp.com, frieder.schrempf@kontron.de, aford173@gmail.com, abel.vesa@nxp.com, Peng Fan Subject: [PATCH V2 4/4] soc: imx: Add blk-ctl driver for i.MX8MM Date: Fri, 30 Apr 2021 13:27:46 +0800 Message-Id: <20210430052746.10815-5-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210430052746.10815-1-peng.fan@oss.nxp.com> References: <20210430052746.10815-1-peng.fan@oss.nxp.com> X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) To DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by HKAPR04CA0006.apcprd04.prod.outlook.com (2603:1096:203:d0::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.25 via Frontend Transport; Fri, 30 Apr 2021 04:55:56 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8b324583-d69f-4bae-9e01-08d90b944079 X-MS-TrafficTypeDiagnostic: DB3PR0402MB3916: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:366; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: M95TjDZWdHiekFxGsDN8P8EjXnfBmlqc1xC5FnXxZsNgf8Yr+XfP4twD1gGRsuismYii/JZYNrdLLLAT+oIWOHDUMXmey8IeqlkZaYbMHOTgGXt8RimuR0Tv9ZTNDLGVJ8l40LggUa3idH2onR7UFYm4UVxbnl7LYWzJO9GoiOBQlDfsOL+fBKROIwTW1xHsZtJvbgnJiZmtXdK/nmQb2RqvExe1nkl0hJQw3VoQb/qZM53uZiKuvqHaLZQZv7/swofizz/w+Nd/7/sPuwOtAUBnvc1Jlvn6UTT5Q/AhwY/TqvY9Hi5MahxgeEDknhq1dZkAk+F1OFGIJzDP5JSirVewkencUxg30ABPmDLgax+Jfly08G97Frs2vRcDKNHfek0Z0teeYmUcciAR/JXY93u+I3jBUROZA3XJbgb4BnPQZiRfryEJcjerkVZ2huiIN1rR+uW+n3UNoDOdpCPSJWSSkYzkNPHTBlhCilZ0+9Zq5C7FF4F3kNXKPzfI7TsNIN3sKqf5pu2zzan7Ce5mNin4hj8WsiAH/qWEvUV5EkhaKpAsPxdlS9ZSFi8p3bjm8PcYMx+ouajmF/nly26lqakPptjkUctQWPap9NkRE0kiUtuLWpyACl34JVZ8fb0HHXPJNitFoR5D3T2qivAp6+fbRSzYgpZiiOpB4Fw/3IY= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB6PR0402MB2760.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(136003)(39850400004)(346002)(376002)(366004)(396003)(316002)(8936002)(5660300002)(83380400001)(66476007)(66946007)(7416002)(66556008)(4326008)(6512007)(6486002)(6666004)(16526019)(956004)(186003)(86362001)(2616005)(6506007)(1076003)(2906002)(38100700002)(38350700002)(8676002)(478600001)(52116002)(26005); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: omQPMzQ0U2btW0btSIi3eOH7O/40p5baIFTF9cgBe2IArQhXGEKAUakaKbHIA8x7feUDH2HNUlwrtgCBfz31vzv9IfBfQLVigMZhpBw5C2htt91oFSYEEOrqe3crIpyiMvAF7DQ9oDMMpVIcaluYeDAp8D/35iGkbnnYFfJbZDPCKCx5iFWxo5KB0r4VsKM//0S/rJHDYb/bUgH7LbI+iV0U/lwCpk/EnR0PJhzFBLAuUcIi6o3ZjDgG+3kc3khOBQoMwLoRhUpWvW5VaDYGYyoKXCywZHwGfFQEMMzH47Py/aEPIkKJZbuFaGqCjCWOB/wNB/tG7tkXthTwR2FosPcOSQRAjgrzkgDAg7eP2/XuM00fcCZ+Yu9TBn3f0cEhLqbc3x/N3/Vuk60GLVAaEnWyVFkDkWfjv9BI+aCaBwymz5/27rAJIpD1+se5DeSlG5GgLpylwoyYZz7yWs6wYsNmj744STCfYiJ7uRg+uNNUmheNM3UELvoeFg7kHwH762jXXTGkx5GpqOW2+vDc0wm8smFfWfEL2Sor1cMRButm3c0hDMcsu2BAuUnlwo16h2njCdHIvK1g6HD9ZD8lBm/BDOySuSRuB9F+U8GDk58een7cdrre5ynU0w6N3I3KAu6q9prTqpAXtyWGIpbXpf7BqBOaVDdrGu0RLA10rqnGNtTLZKMV0BkP2SFvyf1jHHIDmbQA3UDED/k333KGNNabz2Y6yELPmGtQvPpozwyefvC/+5NZwo4naCsed6NORBkBeGzQR6yprL6adtX+WH4w96tVwkr2VEuXiiP5AZ6KnG+H8ZwGv/z1DVIiCQyZJx90Mtvur4dQy6LSy6H55E03miqpvOqREd1GLMA+mYh2e9vI9oam4PqQ5ATLg36OUlDFRdMlHF6UGnC3CMPd9ySEz66u+pIVc0H6XSdSibF6Lq5+cEIpolProMIQSvUwj4ZKqB3A2u3xdEIfNXbQiq/rmlhuTspHfHjI24rxcLwTAcOwQn6ljPULRjkkvLjv+fuAUc3a8PHw3GNJ2xkQhvXpVFHuzbnbpVtpivX2c07XVsXeFCWPKO6cQd0yXesJUAeUq83TkA5ONhEuPR3Vemz2Wo9ay3gt2vO3Op8RIYqM7iNew422pqMX0XAfpj54IXCxvsE/MQKzzvPhRfF3K5EgUuEUS1K8A18Ylj7ObQJdX7+zJMthVKov1va5cshMO+Wgqf1SbOM1S7XF9bZColQ/sGAhhIFCKZvDYR7Ah4tyoEyGb6ZcVk48ItNoHp/jCOhJo8HXai+FozQwgiNfpjqXjOW8q/mBIE0gm0eBdXCcbGP3LwYfLM7d90rJ6CNs X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8b324583-d69f-4bae-9e01-08d90b944079 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Apr 2021 04:56:01.6232 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: oHihwNfHurlsZp/2/AJ87OcCpiepK251O5pyvdVKK6XT+bQJh7PSC7phW45uPs2ek3p8Ii58LXzXkYF4TP4pNg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR0402MB3916 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan The i.MX8MM SoC has dispmix BLK-CTL and vpumix BLK-CTL, so we add that support in this driver. Signed-off-by: Peng Fan --- drivers/soc/imx/Makefile | 2 +- drivers/soc/imx/blk-ctl-imx8mm.c | 138 +++++++++++++++++++++++++++++++ 2 files changed, 139 insertions(+), 1 deletion(-) create mode 100644 drivers/soc/imx/blk-ctl-imx8mm.c -- 2.30.0 diff --git a/drivers/soc/imx/Makefile b/drivers/soc/imx/Makefile index d3d2b49a386c..c260b962f495 100644 --- a/drivers/soc/imx/Makefile +++ b/drivers/soc/imx/Makefile @@ -4,4 +4,4 @@ obj-$(CONFIG_ARCH_MXC) += soc-imx.o endif obj-$(CONFIG_HAVE_IMX_GPC) += gpc.o obj-$(CONFIG_IMX_GPCV2_PM_DOMAINS) += gpcv2.o -obj-$(CONFIG_SOC_IMX8M) += soc-imx8m.o blk-ctl.o +obj-$(CONFIG_SOC_IMX8M) += soc-imx8m.o blk-ctl.o blk-ctl-imx8mm.o diff --git a/drivers/soc/imx/blk-ctl-imx8mm.c b/drivers/soc/imx/blk-ctl-imx8mm.c new file mode 100644 index 000000000000..77e0a5d3fdac --- /dev/null +++ b/drivers/soc/imx/blk-ctl-imx8mm.c @@ -0,0 +1,138 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright 2021 NXP + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "blk-ctl.h" + +#define MEDIA_BLK_BUS_RSTN_BLK_SYNC_SFT_EN BIT(6) +#define MEDIA_BLK_MIPI_DSI_I_PRESETN_SFT_EN BIT(5) +#define MEDIA_BLK_MIPI_CSI_I_PRESETN_SFT_EN BIT(4) +#define MEDIA_BLK_CAMERA_PIXEL_RESET_N_SFT_EN BIT(3) +#define MEDIA_BLK_CSI_BRIDGE_SFT_EN GENMASK(2, 0) + +#define MEDIA_BLK_BUS_PD_MASK BIT(12) +#define MEDIA_BLK_MIPI_CSI_PD_MASK GENMASK(11, 10) +#define MEDIA_BLK_MIPI_DSI_PD_MASK GENMASK(9, 8) +#define MEDIA_BLK_LCDIF_PD_MASK GENMASK(7, 6) +#define MEDIA_BLK_CSI_BRIDGE_PD_MASK GENMASK(5, 0) + +static struct imx_blk_ctl_hw imx8mm_dispmix_blk_ctl_pds[] = { + IMX_BLK_CTL_PD("CSI_BRIDGE", "dispmix", IMX8MM_BLK_CTL_DISPMIX_CSI_BRIDGE, 0x4, + MEDIA_BLK_CSI_BRIDGE_PD_MASK, 0, MEDIA_BLK_CSI_BRIDGE_SFT_EN, + IMX_BLK_CTL_PD_RESET), + IMX_BLK_CTL_PD("LCDIF", "dispmix", IMX8MM_BLK_CTL_DISPMIX_LCDIF, 0x4, + MEDIA_BLK_LCDIF_PD_MASK, -1, -1, 0), + IMX_BLK_CTL_PD("MIPI_DSI", "mipi", IMX8MM_BLK_CTL_DISPMIX_MIPI_DSI, 0x4, + MEDIA_BLK_MIPI_DSI_PD_MASK, 0, MEDIA_BLK_MIPI_DSI_I_PRESETN_SFT_EN, + IMX_BLK_CTL_PD_RESET), + IMX_BLK_CTL_PD("MIPI_CSI", "mipi", IMX8MM_BLK_CTL_DISPMIX_MIPI_CSI, 0x4, + MEDIA_BLK_MIPI_CSI_PD_MASK, 0, + MEDIA_BLK_MIPI_CSI_I_PRESETN_SFT_EN | MEDIA_BLK_CAMERA_PIXEL_RESET_N_SFT_EN, + IMX_BLK_CTL_PD_RESET) +}; + +static struct imx_blk_ctl_hw imx8mm_vpumix_blk_ctl_pds[] = { + IMX_BLK_CTL_PD("VPU_BLK_CTL_G2", "vpu-g2", IMX8MM_BLK_CTL_G2_PD, 0x4, + BIT(0), 0, BIT(0), IMX_BLK_CTL_PD_RESET), + IMX_BLK_CTL_PD("VPU_BLK_CTL_G1", "vpu-g1", IMX8MM_BLK_CTL_G1_PD, 0x4, + BIT(1), 0, BIT(1), IMX_BLK_CTL_PD_RESET), + IMX_BLK_CTL_PD("VPU_BLK_CTL_H1", "vpu-h1", IMX8MM_BLK_CTL_H1_PD, 0x4, + BIT(2), 0, BIT(2), IMX_BLK_CTL_PD_HANDSHAKE | IMX_BLK_CTL_PD_RESET), +}; + +static const struct regmap_config imx8mm_blk_ctl_regmap_config = { + .reg_bits = 32, + .reg_stride = 4, + .val_bits = 32, + .max_register = 0x30, + .fast_io = true, +}; + +static const struct imx_blk_ctl_dev_data imx8mm_vpumix_blk_ctl_dev_data = { + .pds = imx8mm_vpumix_blk_ctl_pds, + .pds_num = ARRAY_SIZE(imx8mm_vpumix_blk_ctl_pds), + .hw_hsk = IMX_BLK_CTL_PD(NULL, NULL, IMX8MM_BLK_CTL_H1_PD, 0x4, BIT(2), 0, BIT(2), + IMX_BLK_CTL_PD_HANDSHAKE), + .config = imx8mm_blk_ctl_regmap_config, + .active_pd_names = (char*[]){"vpumix", "g1", "g2", "h1"}, + .num_active_pd = 4, +}; + +static const struct imx_blk_ctl_dev_data imx8mm_dispmix_blk_ctl_dev_data = { + .pds = imx8mm_dispmix_blk_ctl_pds, + .pds_num = ARRAY_SIZE(imx8mm_dispmix_blk_ctl_pds), + .hw_hsk = IMX_BLK_CTL_PD(NULL, NULL, -1, 0x4, MEDIA_BLK_BUS_PD_MASK, 0, + MEDIA_BLK_BUS_RSTN_BLK_SYNC_SFT_EN, + IMX_BLK_CTL_PD_HANDSHAKE | IMX_BLK_CTL_PD_RESET), + .config = imx8mm_blk_ctl_regmap_config, + .active_pd_names = (char*[]){"dispmix", "mipi"}, + .num_active_pd = 2, +}; + +static int imx8mm_blk_ctl_probe(struct platform_device *pdev) +{ + struct device *dev = &pdev->dev; + const struct imx_blk_ctl_dev_data *dev_data = of_device_get_match_data(dev); + struct regmap *regmap; + struct resource *res; + struct imx_blk_ctl *ctl; + void __iomem *base; + + ctl = devm_kzalloc(dev, sizeof(*ctl), GFP_KERNEL); + if (!ctl) + return -ENOMEM; + + res = platform_get_resource(pdev, IORESOURCE_MEM, 0); + base = devm_ioremap_resource(dev, res); + if (IS_ERR(base)) + return PTR_ERR(base); + + regmap = devm_regmap_init_mmio(dev, base, &dev_data->config); + if (IS_ERR(regmap)) + return PTR_ERR(regmap); + + ctl->regmap = regmap; + ctl->dev = dev; + atomic_set(&ctl->power_count, 0); + + ctl->num_clks = devm_clk_bulk_get_all(dev, &ctl->clks); + if (ctl->num_clks < 0) + return ctl->num_clks; + + dev_set_drvdata(dev, ctl); + ctl->dev_data = of_device_get_match_data(dev); + + return imx_blk_ctl_register(dev); +} + +static const struct of_device_id imx_blk_ctl_of_match[] = { + { .compatible = "fsl,imx8mm-vpumix-blk-ctl", .data = &imx8mm_vpumix_blk_ctl_dev_data }, + { .compatible = "fsl,imx8mm-dispmix-blk-ctl", .data = &imx8mm_dispmix_blk_ctl_dev_data }, + { /* Sentinel */ } +}; +MODULE_DEVICE_TABLE(of, imx_blk_ctl_of_match); + +static struct platform_driver imx_blk_ctl_driver = { + .probe = imx8mm_blk_ctl_probe, + .driver = { + .name = "imx8mm-blk-ctl", + .of_match_table = of_match_ptr(imx_blk_ctl_of_match), + .pm = &imx_blk_ctl_pm_ops, + }, +}; +module_platform_driver(imx_blk_ctl_driver);