Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp382427ybe; Mon, 2 Sep 2019 03:12:43 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvDbWrQOzqRONrqjYqpKz8xJGKFk5LwOGwb83L3KvvCLya7zoTJCbqurUyzJ1n29HKMHJ0 X-Received: by 2002:a62:3887:: with SMTP id f129mr34250892pfa.245.1567419162922; Mon, 02 Sep 2019 03:12:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567419162; cv=none; d=google.com; s=arc-20160816; b=EG/KZ1sGyIX5/lBx8/ocaKF14DrMW0+ogoKN7n3pQNoHM8dKfM0pLwp4NB4YWIJcwK /Jf2dqYeDkZgvYL5ApbzOAqNpXZzwfCFkPLZT3Ix7orqkpUzMhGq/adY+0B4jtumy86O DGacYfqtE1YM5fv9jiy/wGhfkPGlr2I8OP654KZ7PQVBLv4OYziJN8UaFiG2NXIh+2J7 ZAKe/AiNy/ckcGMM+TGPWmCN/KIZ2yHBoeqfoSr8i9s6Sn9S4UbtBLgLvsaJVYD3Clpg 3inmV8skmRyw+yUIP+UYkQllpShUNAWbhT/kyWvbxXNZ6a6Dt7watH69L1BSyvKfrfZt 9gCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=5t6kD0UFv4pOkmdzsUUtSO+edVZqMqiiogSlIBYmblo=; b=VjG9fYohySLKrFJXDWmsdZ1Iszji2O65QaDmP5rnUUl5k29YmBui6GeojNQELBCy04 ZRT63WXQ5geoVHBN2afFSjNu5qtFcQ32pY8KPB9SSbwW5dxBcL3EY5eUu1rajBRctzkD +qNrxBwNWdDYboPUbrNqZBaifMn+1jZyVmBY7FPnTfT3BB9/Pl4RF+1oMh+1A3GLStfp BOIYZGZliLzsO1vxrDkWrPz8vTG9Ww+kFms6y7brSGPrDKE5UpK869VwTwa2zRf8Pr+K SjJVpJAtF9XvoZksPG5IFq8vbyYh9YePqlP3nuDF2lG65KVPCx3Aj4D8RWNSODHR2dzX duHw== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 35si11419884plb.24.2019.09.02.03.12.28; Mon, 02 Sep 2019 03:12:42 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730665AbfIBIfl (ORCPT + 99 others); Mon, 2 Sep 2019 04:35:41 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:26689 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1730142AbfIBIfk (ORCPT ); Mon, 2 Sep 2019 04:35:40 -0400 X-UUID: adab30e64dfd456f8629dc018e855ec6-20190902 X-UUID: adab30e64dfd456f8629dc018e855ec6-20190902 Received: from mtkcas08.mediatek.inc [(172.21.101.126)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 557003518; Mon, 02 Sep 2019 16:35:33 +0800 Received: from mtkcas09.mediatek.inc (172.21.101.178) by mtkmbs02n2.mediatek.inc (172.21.101.101) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Mon, 2 Sep 2019 16:35:33 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkcas09.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Mon, 2 Sep 2019 16:35:32 +0800 From: Weiyi Lu To: Nicolas Boichat , Matthias Brugger , Stephen Boyd , Rob Herring CC: James Liao , Fan Chen , , , , , , CK Hu , Weiyi Lu Subject: [PATCH v1 2/3] clk: mediatek: Runtime PM support for MT8183 mcucfg clock provider Date: Mon, 2 Sep 2019 16:35:09 +0800 Message-ID: <1567413310-2589-3-git-send-email-weiyi.lu@mediatek.com> X-Mailer: git-send-email 1.8.1.1.dirty In-Reply-To: <1567413310-2589-1-git-send-email-weiyi.lu@mediatek.com> References: <1567413310-2589-1-git-send-email-weiyi.lu@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-TM-SNTS-SMTP: 76D189C3F3FD4D87A5DAF2632964FB513D4BE5D2FAFD0D5029E18F840E35C3EA2000:8 X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Enable the runtime PM support and forward the struct device pointer for registration of MT8183 mcucfg clocks. Signed-off-by: Weiyi Lu --- drivers/clk/mediatek/clk-mt8183-mfgcfg.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/clk/mediatek/clk-mt8183-mfgcfg.c b/drivers/clk/mediatek/clk-mt8183-mfgcfg.c index 99a6b02..37b4162 100644 --- a/drivers/clk/mediatek/clk-mt8183-mfgcfg.c +++ b/drivers/clk/mediatek/clk-mt8183-mfgcfg.c @@ -5,6 +5,7 @@ #include #include +#include #include "clk-mtk.h" #include "clk-gate.h" @@ -30,10 +31,12 @@ static int clk_mt8183_mfg_probe(struct platform_device *pdev) struct clk_onecell_data *clk_data; struct device_node *node = pdev->dev.of_node; + pm_runtime_enable(&pdev->dev); + clk_data = mtk_alloc_clk_data(CLK_MFG_NR_CLK); - mtk_clk_register_gates(node, mfg_clks, ARRAY_SIZE(mfg_clks), - clk_data); + mtk_clk_register_gates_with_dev(node, mfg_clks, ARRAY_SIZE(mfg_clks), + clk_data, &pdev->dev); return of_clk_add_provider(node, of_clk_src_onecell_get, clk_data); } -- 1.8.1.1.dirty