Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp2382051ioo; Sat, 28 May 2022 11:54:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyIHOfAnA19Dm+Nh8V5Bb949tQ3qquOBZ5IF6dxYMBF5lPBVsiXz/RYbFoYrqGLSkuX0TBP X-Received: by 2002:a63:4459:0:b0:39d:3808:7c84 with SMTP id t25-20020a634459000000b0039d38087c84mr42511459pgk.130.1653764060689; Sat, 28 May 2022 11:54:20 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1653764060; cv=pass; d=google.com; s=arc-20160816; b=LAkVcC0vmisPQ1zGpi30wlbCqYw7l1xEJYZ1WdlruuMx/JUopTrUq6zdLIbusrFlZC po+2LBrRr2OSvsb34ifkk2OEKup6hp5sJFmK1SixXpyqdqjcxgkmF2zvPUB0YF2lHWwr Lpd6tZU4FFpjPJZlKqNou1A2xsnGl55kABx8M+lpP7NEfVBwqQKW+JmMoooTeP7/+iq9 UrKB+s/WNZEfwr/tEqOqfzH4Yui+fKl2eG6SFxugip3QBfySRuqd+skevGg/CL0/Cvfs heYLG7pX1+milLWI1M6wau1n9URo93D4Ujy+mskB/VT9Cumyn8Z5Qe51LoqFqg7XDQxd Rtzg== 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=nvyBBWq/TULyYaW+qtbnBmvmh9ed2b54mEXSIqHerqY=; b=cYQWvo2UE7MVKz6PDTx0RaWLwg7haSPEb8e7joGnJNceiXwJgtqr1eQiokyj/AO7qQ LZZF58v0S8aELGwINx/BzU5YW0Y4uP1sO5gueWQa38egXkx9P7vXhTlTXLq5sha7iHTZ ufjTeJdMaQt3cSKezgKh5zHCG/v2ms0rbDi7eRJaDLWjhDTWOw9bWxsSnE1maBtluept ZvnJu9w6wOCmdXbPbD7R0SSXskiU+QgmvZjwR4sHLPDXlN3nqKYjTLR1BxgOn0DOWU7d tUhr79HvVB3OIJjIgJB3p5BnHkEpxfUo6TXvrZgLkXb/d055UKL2qtS9n78HKoCL/3ua m6/g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=inB291m3; 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 linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id b7-20020a655787000000b003c27c45c0b4si10749351pgr.443.2022.05.28.11.54.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 28 May 2022 11:54:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=inB291m3; 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 linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E044634B86; Sat, 28 May 2022 11:40:48 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347431AbiEZMdM (ORCPT + 99 others); Thu, 26 May 2022 08:33:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34458 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347332AbiEZMdC (ORCPT ); Thu, 26 May 2022 08:33:02 -0400 Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-eopbgr70044.outbound.protection.outlook.com [40.107.7.44]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8B343A188; Thu, 26 May 2022 05:32:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PRyATPuqukFC2KU4RGCGg0V8l7d4WMID6HdGMitSkqp+gk7tZvLQhTTtFU4rdFl8EY4Any+wKjre2hdcJ5WRdNiPRFSFO3J1LuA0EIgaHOyMvlcRZtwql+4vZCoTGhQfuZOEgK9EBMFOfqI8qepZT4v5Z3LsCrMmGybL+/tfGtBWJNBM6LN8sUVA2oG3kdEEid/XJIjnx8w5iPuEKy1PdqDUQzE+gm14BeHIE3SxGRw94RxRPVIt0vZEAk8vApIC9lKCv1rQuvDi+Xq5ZBpuGd/gS3TCLnbHezhip5DetNwigA4zQMF33L2YEnpIIBP3m7aczlIVSSuESpdWTZ6WQQ== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=nvyBBWq/TULyYaW+qtbnBmvmh9ed2b54mEXSIqHerqY=; b=gHVfxPm0uyevMJL7KEdEs3U6EgXTYzfxoBLo+iPwyZFQwhVcqMHKhucYUA9iafTb8L0+XeV3dcBHC8Hy9Hks1ms26wVX3LbqM3yKT91gBnXXUP5UDB1ug/MkiTfgOcwVsd+mOuXRjXjjwO8IPwq96bLA1CKFnNkiW/vaDR7lIYL48olNJX4rhkjmjxl+rT2ol1oZfEV6uRBBzWOXca0QDj2MRqUoX2yZVpQ7oJQwRMBgL/EJ3ZW/2Jk09nMOKb252oQDXZThEIqD44ChEYwOH8scbxQk58ZFUnOnbUaqY9WEHyQL5xQG/pXFexgb2Or6b9U8y1d0ARTs/TDO4J90Rw== 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=nvyBBWq/TULyYaW+qtbnBmvmh9ed2b54mEXSIqHerqY=; b=inB291m3+MkgOjcy11nHMpmKd7+UmBpNkXSkJZ0qPDFyIr3ynbmJfBGja6E5QIdhteUJgLQQPSoNZC9GZ3y/QWosOR2ymmcguVDn9uMn1BgVgu+JlREDNrmNJ7e2NRVQJoB36KHImX41Xy35Jq0N2XXPBGkC7VstaYKoczCU1Nc= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) by AM0PR04MB6515.eurprd04.prod.outlook.com (2603:10a6:208:16f::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5293.13; Thu, 26 May 2022 12:32:46 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::a892:e4a9:4769:13a5]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::a892:e4a9:4769:13a5%7]) with mapi id 15.20.5293.013; Thu, 26 May 2022 12:32:46 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, sboyd@kernel.org, mturquette@baylibre.com, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: aisheng.dong@nxp.com, l.stach@pengutronix.de, kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Peng Fan Subject: [PATCH V2 3/7] clk: export of_clk_bulk_get_all Date: Thu, 26 May 2022 20:34:07 +0800 Message-Id: <20220526123411.270083-4-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220526123411.270083-1-peng.fan@oss.nxp.com> References: <20220526123411.270083-1-peng.fan@oss.nxp.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SI2PR06CA0013.apcprd06.prod.outlook.com (2603:1096:4:186::18) To DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e6d1715f-d78f-4443-465a-08da3f13d64c X-MS-TrafficTypeDiagnostic: AM0PR04MB6515:EE_ X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: nChqFGHE+FNvUN2bOzNclsG1xOw/7mjMtQynLMk3q/nMKFoZzpfSO+s1CQZ3UGXeTqn7fJoScOSe5d5YBtv/aU9g2Y6RBZbFynwTX33LjE7I1qxI69T7Nk/d4RnXPwqxtAVtR9AGoknmWqNixdbLk+Nzv5/CYzgHpb8zZVfeP0vHYTB5zKQvcrh9tQbduNna2yzz2dTnVdfOQGvKx4S+RdsSESmIG/HUBE786VE3ZZzUfNIl/cHlIBrQc7CvnCxVce482RS8K+zgaSL50HDC12rOqZGJF4qDJjRtwEy5HW6eQEnEr8d6vswXt1ULV/oSj3dX6PYulSFlZbrj2j9aYa8SzJoiFhsSyeimhCXiuCbcUZWy3AUiTwGZjA2vj5XZ8n5ksoFKexLdFFRlvwCfS1cnuNUW5jnTL1pQP/P/uhqE/Vn6Yq8Iv9sLDYum8yRWU8oxkLaVCxdxlrLe6yZXekNq/QsVTXgVpOTDPKXYe2KdnPoTXF7igZn5hn5Z1wTSBeu2IFFPQvTdHKeqvV61LaJj45WHX5oUm4z4KWnDuCPeM7s4CXBbDKz43aMT9HKuyKhZ2uTsm8AxcubYAw82WxVdkdcLPDzs+fbQxqPtAplujO9nLGMo58RNZ4nvNVu5m2NXsZc6NsAmbVhgEZWgUE5KROlGCLTk4/RhNRDa95CFoaAahGZylNKUo8Xr+JezcKakOnjtPtOQVlcVD4vbmQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DU0PR04MB9417.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230001)(4636009)(366004)(316002)(52116002)(2616005)(6512007)(86362001)(26005)(38100700002)(38350700002)(6506007)(66946007)(66476007)(66556008)(4326008)(8676002)(6666004)(5660300002)(8936002)(7416002)(508600001)(2906002)(83380400001)(186003)(1076003)(6486002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?ln7ZtKYmQdbwApD6wM/zErJfftA7RiRTuK4rsRpF6Yl2HLDLwSiBm3qV+mv9?= =?us-ascii?Q?+bvWszoSR3pjCUWG9RBI7sA6mqXnVGZ6Vv+hmKA4fXwPOnlX66sMdwbghiii?= =?us-ascii?Q?6rynoeTecVq+FVqI6jl7iTmz2X7c9VHgbdYeO4pSNmBHehgWmtif13MPjwy9?= =?us-ascii?Q?DO2c1Dn/fgNx7ie4M4hhAVJ/aE2iGRtrYb98zicfcEITcS1T7uxJjPxXjEq+?= =?us-ascii?Q?a3HWiaYQTF0hxQGWWTb1zuK6ASrM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-ascii?Q?Ej4gcobZ41ceBy5r5XK3bpN4HW2FbXI0VgBI+bxo2amhGG77SjOtUrFKPGOW?= =?us-ascii?Q?oSH4PGq6ABhNkGhCxhd+HPXJvDJmJVxy49Fw/cckY15H5UYN1xeKMOs1c9pE?= =?us-ascii?Q?DGUxYE47S2Im30GoVqyC9D0nea0BYKfwQsT1xRwcuKOTUM+B4n5+o4mEqbAu?= =?us-ascii?Q?vv/QkLC5myugv4B1LhY+WoRD+n0VsMu1i8yDb7C1Khgl0TdlpWDimOrK2A46?= =?us-ascii?Q?QkUMh4+z3l0uBsM0c3FkIkjMDjXbLvioX7oj7BeYuEBUyFqG3HtDMHWnNDJj?= =?us-ascii?Q?HWc43hKemqvftPc2lNBSTbYDdrLtJK5Bb4P8nC7f+8yInjy9Y5Mtz0Enmhuq?= =?us-ascii?Q?mbpk2mWES4Sycfq7yXmTA/YEtBGR1BqGtS0YOiA0ERFgAFRoESojmppaZxVK?= =?us-ascii?Q?4ac/ltY2S5FewXsT0vRQVkPaPMyfmwVlitQzRh77L9sLGiwd9y2WQWFmLN/U?= =?us-ascii?Q?H9JhAODf9ITO3wbpyOfd6daQQA9rqVqQWh30WZNOqdJAPHX9771WMo8Ld6RF?= =?us-ascii?Q?byfgoqCnAALhwyB9mnMfcxX3N93QYAfid5FGSt/FWmuoJO7SB4SteUpovDRS?= =?us-ascii?Q?4iDSwNwRQw=3D=3D?= X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e6d1715f-d78f-4443-465a-08da3f13d64c X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 May 2022 12:32:46.0941 (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: BdNIM044JzxJQYmJXQlnx2Cjdbfjyv5PUkoWeTFK+I2uYOmPd4QvnquIbZh3YwM2O4sx2s8ZduenzIZRrwfyOw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB6515 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peng Fan Export of_clk_bulk_get_all, so drivers could use this API. Signed-off-by: Peng Fan --- drivers/clk/clk-bulk.c | 3 ++- include/linux/clk.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/clk/clk-bulk.c b/drivers/clk/clk-bulk.c index e9e16425c739..470155856b02 100644 --- a/drivers/clk/clk-bulk.c +++ b/drivers/clk/clk-bulk.c @@ -43,7 +43,7 @@ static int __must_check of_clk_bulk_get(struct device_node *np, int num_clks, return ret; } -static int __must_check of_clk_bulk_get_all(struct device_node *np, +int __must_check of_clk_bulk_get_all(struct device_node *np, struct clk_bulk_data **clks) { struct clk_bulk_data *clk_bulk; @@ -68,6 +68,7 @@ static int __must_check of_clk_bulk_get_all(struct device_node *np, return num_clks; } +EXPORT_SYMBOL_GPL(of_clk_bulk_get_all); void clk_bulk_put(int num_clks, struct clk_bulk_data *clks) { diff --git a/include/linux/clk.h b/include/linux/clk.h index 39faa54efe88..ca74f4e83d25 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h @@ -372,6 +372,8 @@ int __must_check clk_bulk_get(struct device *dev, int num_clks, int __must_check clk_bulk_get_all(struct device *dev, struct clk_bulk_data **clks); +int __must_check of_clk_bulk_get_all(struct device_node *np, + struct clk_bulk_data **clks); /** * clk_bulk_get_optional - lookup and obtain a number of references to clock producer * @dev: device for clock "consumer" -- 2.25.1