From patchwork Fri May 28 11:34:00 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: 12286793 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A80E2C47087 for ; Fri, 28 May 2021 11:34:27 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 6CBFE613D4 for ; Fri, 28 May 2021 11:34:27 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6CBFE613D4 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=oss.nxp.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :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=+lT3ofoeczWH7/zneNX35YTcppdq/9ViX111WGXxGkQ=; b=WTkHPXZlETNR2r m5cE8AbOnk4PmWj2BaULLI1xKwRDLaoC6wD4mKpfLiqCcwod7zNjuXN11Qxl5w9/CHhJpN37i5ySJ 9IIjebmMlZ+mu88IsONUKUKaFeQ7WICxRlB/Wuo7yZNeIqCzHei3byZHwyl0d4fMaYocPNwW83Hg3 a7f7tOPdJxEOo3ctqQoN8XnVbDdrQyMvJYmZxkklCkz2C+dpZwBImNnhbynM0ox0Oad89TXjC4MY4 nrIkzX0cfdWWG71jKXZ6CEi+NpQBMe8LG5iNxpBWzSZJ6IoBQDBp6zJCDv9tm4sisjV15nPUzlcD0 u5Yt9wD3mSwoY9Viyylw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lmaia-00EslT-D9; Fri, 28 May 2021 11:31:57 +0000 Received: from mail-eopbgr30047.outbound.protection.outlook.com ([40.107.3.47] helo=EUR03-AM5-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lmaEr-00EdYc-2K for linux-arm-kernel@lists.infradead.org; Fri, 28 May 2021 11:01:18 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=D4IKnbxplPrK5zXSn6T3tVeU0rergC0usdz0mScuPAuUd965JOxOis7TTQI22Vg+isN4VUhKmTOZZ7zsrHC/i4d0G3H3wzWUB8dthwV5d5/kxYXEUbfzitjWd6bGFBQ0k0Xf5GzPcIndkhn1morPdqTqLKzjZCJXEGqwePJuo6ftAKZK1DhBU+j0SCiuPEM31pA8oNcHd79BMnUYg7qPDHrxO23wgjCjxV5NvmxS9xh46YLpcdEXENPd2UeEaxKtrShSb6wc2fIifangYqlFn5tWyGMkQss5wijsKmwsizi1cJXCAkepx5C8K7///GMFiWgTD5f9Ab7Hpi+TTL2sWw== 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=uBKIz7uuv+JaoWYEwybxRq91UfUKZQZSJzlwYsk50vI=; b=NgfokGHwZHoBX8FCivGf96+O6VIYL/uDhBo05LWi0Uaxta0IkMZsk/cgUrX7CxXHbGsUBvZtfS90CLQARGKvCjKEPJJ7Qk4FXIlFeCzBZgmQqZPxDxX/PceR/J/38KnZDczVwAbd1Gg5LGSfiJ0ORGEnCAoIOlZW4S2BRmEAwiQoldxdumYGIXeutuNhnjsI9gPTxqmjq8cjv/GpcGWWHy7utS73XEBwEb5mXcmKEFH+CutOBnA7ufJrChvyA4e0Hi7WnN8lhikTIZ9SmvA6cBe8kxosz4e1e9n/cZ14PLRyPtp23nsTz3CT9E2C8XHcRYrHfm3XTF+cOwvx+Z9V6Q== 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=uBKIz7uuv+JaoWYEwybxRq91UfUKZQZSJzlwYsk50vI=; b=kDqsnlqgjTdgST6woI28dMhu7kikSbsvRZHbhqM4+hEqwNvgWMQoEnt+EIGWaZ9O2NC1hn9BKWb86CIwxS2W90C3+kNNI/AkwG0HrZlmOQKgAdRZhoIspaRtKjIyxNOdQ+46s1M4V1kacbne4swj2W0PInDKTQJZOi2hjvuG0Uo= 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 DBBPR04MB7515.eurprd04.prod.outlook.com (2603:10a6:10:202::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4173.24; Fri, 28 May 2021 11:01:09 +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.4173.024; Fri, 28 May 2021 11:01:09 +0000 From: "Peng Fan (OSS)" To: sboyd@kernel.org, mturquette@baylibre.com Cc: linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de, Peng Fan Subject: [PATCH 0/3] clk: support regmap Date: Fri, 28 May 2021 19:34:00 +0800 Message-Id: <20210528113403.5374-1-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: SG2PR06CA0158.apcprd06.prod.outlook.com (2603:1096:1:1e::12) 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 SG2PR06CA0158.apcprd06.prod.outlook.com (2603:1096:1:1e::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4173.20 via Frontend Transport; Fri, 28 May 2021 11:01:06 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0ac2ecb8-5c0d-4dc7-a546-08d921c7e5ee X-MS-TrafficTypeDiagnostic: DBBPR04MB7515: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6430; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: SxzOFYaikBNrU8CJBD212hsXGhUyaUJB1DdPiRjYCV5TNDvo4TCjJVV/aVDfmuFe+rH7YKz+ZMNIH27TOoQcCOagbFQMF+g57DZtBqlnP3nVRecieyk9aXWM0zwE7dv+KRpx78X64j3qeHYVHTY+PRYXcQ8syFnk7tnMvxOjMyKgL705mvwM0PcnIMM5g2qxynApo86xJyIScJ3iHNZWlu/rTN2U9Wqu4FFkhyhwVVvaJqq3W9v5MXQVBiI5Wv8KUFWjDh2BQk1vZFTIUIVW8TgMeuBezmM6I5UBFv/5c8AclE4AMTXBQ3FIfKiV8OITFwEnw/wB40GJGn7cy8Jwxo36WW4mD84k6dcl6fsR2nQ5UEtbY3p468QLKekz/hgHAk57pIFM9z4t7vcvroVyiUtG8VwoqMjQSG1pbhDYET869DHNNly1+hTdD0ovxOWdo8IGFZkws2GXTARBLXee/nv1J1zBtpLhX1DW3O6hDE4uocRMuUgxqAyUF8EgpjriDYHFAlB6jiKfjNERAWx1TEf2BFhsUAADRHUqogtIUIP374uRvdi0x8M85PUqCvDb0BuKm1AvV18o97d7uZmx/Cn8e9BJngwIJQpwugTawu+paj6+eToaunUVdj/ngwllZwobBniFH/bATSSyYmjMNNZ9VrrsGdotIrYjX36zG8A= 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)(39850400004)(346002)(136003)(376002)(396003)(366004)(52116002)(6506007)(38100700002)(38350700002)(26005)(86362001)(83380400001)(2906002)(1076003)(8936002)(66476007)(2616005)(956004)(16526019)(186003)(4326008)(6666004)(66556008)(66946007)(6486002)(8676002)(4744005)(5660300002)(316002)(478600001)(6512007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: bP1vfSnCZI6jTVUJlVVi1o8wjX2ackpxX48/95KmM+EDXbyFt6I0hji2b9qa/vIF6G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OIzGtqxZbvIduqVdH4VRZ3gCb39t0Xlwpf5nhpXRrTSOBCeWVd8LyaKP/abBtM0b10Rt92ICDXOmVA0VxJnhLdlcktp791KA4E0qzdFpOUi+GNV+SJCUeSsaMkRCKoWA83QDM9yXBXhUyG/C5L+MDxoZnaxuxX67OVTNxUjd/4nXjR9XGSQLb25AC15GKdQ6cEBsgBTVeeR3gy4/SYztgpmfasA== X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0ac2ecb8-5c0d-4dc7-a546-08d921c7e5ee X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 May 2021 11:01:09.3204 (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: IikaXJ/zul17+zCsj+nJsUZUm0rj79i+CSLkLxVL9ustBMZKgVqxCT5wA2BeJhV5e+S4JIDYM6ZcCmz+RdQCUw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBBPR04MB7515 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210528_040113_243976_ECC1212D X-CRM114-Status: UNSURE ( 6.87 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Peng Fan To i.MX8ULP, a PCC register provides clk(mux, gate, divider) and peripheral reset functionality, so we need make sure the access to the PCC register be protected to avoid concurrent access from clk and reset subsystem. So let's use regmap here. The i.MX specific code will be posted if this patchset is ok for you. Peng Fan (3): clk: mux: support regmap clk: fractional-divider: support regmap clk: gate: support regmap drivers/clk/clk-fractional-divider.c | 26 +++++++++++++++++++++++--- drivers/clk/clk-gate.c | 26 +++++++++++++++++++++++--- drivers/clk/clk-mux.c | 26 +++++++++++++++++++++++--- include/linux/clk-provider.h | 14 ++++++++++++++ 4 files changed, 83 insertions(+), 9 deletions(-)