From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6C5D7C4332F for ; Wed, 28 Dec 2022 07:50:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229745AbiL1Hua (ORCPT ); Wed, 28 Dec 2022 02:50:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34492 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229691AbiL1Hu3 (ORCPT ); Wed, 28 Dec 2022 02:50:29 -0500 Received: from mailgw01.mediatek.com (unknown [60.244.123.138]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A55F7DF0E; Tue, 27 Dec 2022 23:50:24 -0800 (PST) X-UUID: 1b094d4ac08e4836a4752774cf12d347-20221228 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=Xf1g6m2wSSYkxja2mmT0kfCPsNwG64PKQczUalAJj+U=; b=BMWnw7puXNbVtysTKSzugPZF8FIWAhuA43jjk8Xruvl+uKqo3mCXBhkQvff/0BXNQW/8nlboLtpbJtH8kqNumYMTLVy5Soy+preeGArG6YjHOJ2tmRTn0O4b9U2Ult71Dzo0lleugOxA+PYfp/NuDooXikWUivxeAKeee4wcTnw=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.14,REQID:bfeed159-dde9-4c47-bc35-4f03e1fd34ef,IP:0,U RL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTION: release,TS:0 X-CID-META: VersionHash:dcaaed0,CLOUDID:8cd99d8a-8530-4eff-9f77-222cf6e2895b,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:0,File:nil,Bulk:nil,QS:nil,BEC:nil,COL:0 X-UUID: 1b094d4ac08e4836a4752774cf12d347-20221228 Received: from mtkmbs11n1.mediatek.inc [(172.21.101.185)] by mailgw01.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 599852345; Wed, 28 Dec 2022 15:50:18 +0800 Received: from mtkmbs13n1.mediatek.inc (172.21.101.193) by mtkmbs13n2.mediatek.inc (172.21.101.108) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.792.15; Wed, 28 Dec 2022 15:50:17 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs13n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.792.15 via Frontend Transport; Wed, 28 Dec 2022 15:50:17 +0800 From: Miles Chen To: CC: , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH v2 11/23] clk: mediatek: Switch to mtk_clk_simple_probe() where possible Date: Wed, 28 Dec 2022 15:50:16 +0800 Message-ID: <20221228075016.12309-1-miles.chen@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20221223094259.87373-12-angelogioacchino.delregno@collabora.com> References: <20221223094259.87373-12-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org > mtk_clk_simple_probe() is a function that registers mtk gate clocks > and, if reset data is present, a reset controller and across all of > the MTK clock drivers, such a function is duplicated many times: > switch to the common mtk_clk_simple_probe() function for all of the > clock drivers that are registering as platform drivers. > ...snip... > + > +static const struct of_device_id of_match_clk_mt8183_simple[] = { > + { .compatible = "mediatek,mt8183-infracfg", .data = &infra_desc }, > + { .compatible = "mediatek,mt8183-pericfg", .data = &peri_desc, }, > + { /* sentinel */ } > +}; > + > +static struct platform_driver clk_mt8183_simple_drv = { > + .probe = mtk_clk_simple_probe, > + .remove = mtk_clk_simple_remove, > + .driver = { > + .name = "clk-mt8183-simple", > + .of_match_table = of_match_clk_mt8183_simple, > + }, > cool, replace clk_mt8183_infra_probe and clk_mt8183_peri_probe with mtk_clk_simple_probe Reviewed-by: Miles Chen