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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id F41AAC433F5 for ; Tue, 17 May 2022 12:06:02 +0000 (UTC) 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:References:In-Reply-To: Date:CC:To:From:Subject:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Vqm8ufeneiHg78+py2FnMBtKH1w/Ss/OjCrE13i7sOc=; b=xp74K+bi6SGH9b gz7a4OPZ7kEZY1aSb5KL+SrPK9EFHXsnUQOne9to13MNp/y2wJoDe14j6B7rj/wzk1vMTdcbdzyK6 5682XcF05LMo0+8FpaCTmUnzuMeCrbBVWZrsu1R4Od0XxkQq3r7kLU2CyTiY9Ax6JR3kk7z38pO6n FRe8ryLCiJEhvBMq4fAMtGoODjx2EIFVukSzpZmUI8GRsOOfmNf2NqYm5p1NXej+k80EIDCk8EVAV ZUKsKQNGZDDLRoGAzmFyhmi2dv6rmdMi+Ezmx1+KclAo9/jCmQ4iKLAMNfs75FxlcwxNLifq/TLiO OIDu8eKyE5XNbI5fmQxw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nqvwb-00DSuD-9h; Tue, 17 May 2022 12:04:53 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nqvwX-00DSs1-RY; Tue, 17 May 2022 12:04:51 +0000 X-UUID: 0ba6fe3ed8fa4b9c923daec688c88224-20220517 X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.5, REQID:0f8a76b1-60eb-4026-825d-ad5426b38439, OB:0, LO B:0,IP:0,URL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,RULE:Release_Ham,ACTI ON:release,TS:0 X-CID-META: VersionHash:2a19b09, CLOUDID:af978f79-5ef6-470b-96c9-bdb8ced32786, C OID:IGNORED,Recheck:0,SF:nil,TC:nil,Content:0,EDM:-3,IP:nil,URL:0,File:nil ,QS:0,BEC:nil X-UUID: 0ba6fe3ed8fa4b9c923daec688c88224-20220517 Received: from mtkcas66.mediatek.inc [(172.29.193.44)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 417971037; Tue, 17 May 2022 05:04:37 -0700 Received: from mtkmbs11n2.mediatek.inc (172.21.101.187) by MTKMBS62DR.mediatek.inc (172.29.94.18) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 17 May 2022 04:54:35 -0700 Received: from mtkmbs11n1.mediatek.inc (172.21.101.186) by mtkmbs11n2.mediatek.inc (172.21.101.187) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.792.3; Tue, 17 May 2022 19:54:32 +0800 Received: from mtksdccf07 (172.21.84.99) by mtkmbs11n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.792.3 via Frontend Transport; Tue, 17 May 2022 19:54:32 +0800 Message-ID: Subject: Re: [PATCH v6 1/7] thermal: mediatek: Relocate driver to mediatek folder From: Rex-BC Chen To: Alexandre Bailon , , , , CC: , , , , , , , , , , Michael Kao , , , , , , , Date: Tue, 17 May 2022 19:54:32 +0800 In-Reply-To: <20220512122433.1399802-2-abailon@baylibre.com> References: <20220512122433.1399802-1-abailon@baylibre.com> <20220512122433.1399802-2-abailon@baylibre.com> X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220517_050449_924903_DEF4293A X-CRM114-Status: GOOD ( 27.13 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, 2022-05-12 at 14:24 +0200, Alexandre Bailon wrote: > From: Michael Kao > > Add Mediatek proprietary folder to upstream more thermal zone and > cooler > drivers. Relocate the original thermal controller driver to it and > rename > as soc_temp.c to show its purpose more clearly. > > Signed-off-by: Michael Kao > Signed-off-by: Ben Tseng > Reviewed-by: Matthias Brugger > --- > drivers/thermal/Kconfig | 14 ++++------- > drivers/thermal/Makefile | 2 +- > drivers/thermal/mediatek/Kconfig | 23 > +++++++++++++++++++ > drivers/thermal/mediatek/Makefile | 1 + > .../{mtk_thermal.c => mediatek/soc_temp.c} | 0 > 5 files changed, 29 insertions(+), 11 deletions(-) > create mode 100644 drivers/thermal/mediatek/Kconfig > create mode 100644 drivers/thermal/mediatek/Makefile > rename drivers/thermal/{mtk_thermal.c => mediatek/soc_temp.c} (100%) > > diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig > index e37691e0bf20..8669d7278055 100644 > --- a/drivers/thermal/Kconfig > +++ b/drivers/thermal/Kconfig > @@ -410,16 +410,10 @@ config DA9062_THERMAL > zone. > Compatible with the DA9062 and DA9061 PMICs. > > -config MTK_THERMAL > - tristate "Temperature sensor driver for mediatek SoCs" > - depends on ARCH_MEDIATEK || COMPILE_TEST > - depends on HAS_IOMEM > - depends on NVMEM || NVMEM=n > - depends on RESET_CONTROLLER > - default y > - help > - Enable this option if you want to have support for thermal > management > - controller present in Mediatek SoCs > +menu "Mediatek thermal drivers" Hello Alexandre, could you help to do this? s/Mediatek/MediaTek/ and please also apply this to this series. Thanks. > +depends on ARCH_MEDIATEK || COMPILE_TEST > +source "drivers/thermal/mediatek/Kconfig" > +endmenu > > config AMLOGIC_THERMAL > tristate "Amlogic Thermal Support" > diff --git a/drivers/thermal/Makefile b/drivers/thermal/Makefile > index f0c36a1530d5..9ade39bdb525 100644 > --- a/drivers/thermal/Makefile > +++ b/drivers/thermal/Makefile > @@ -55,7 +55,7 @@ obj-y += st/ > obj-$(CONFIG_QCOM_TSENS) += qcom/ > obj-y += tegra/ > obj-$(CONFIG_HISI_THERMAL) += hisi_thermal.o > -obj-$(CONFIG_MTK_THERMAL) += mtk_thermal.o > +obj-$(CONFIG_MTK_THERMAL) += mediatek/ > obj-$(CONFIG_GENERIC_ADC_THERMAL) += thermal-generic-adc.o > obj-$(CONFIG_UNIPHIER_THERMAL) += uniphier_thermal.o > obj-$(CONFIG_AMLOGIC_THERMAL) += amlogic_thermal.o > diff --git a/drivers/thermal/mediatek/Kconfig > b/drivers/thermal/mediatek/Kconfig > new file mode 100644 > index 000000000000..0351e73170b7 > --- /dev/null > +++ b/drivers/thermal/mediatek/Kconfig > @@ -0,0 +1,23 @@ > +config MTK_THERMAL > + tristate "Mediatek thermal drivers" > + depends on THERMAL_OF > + help > + This is the option for Mediatek thermal software > + solutions. Please enable corresponding options to > + get temperature information from thermal sensors or > + turn on throttle mechaisms for thermal mitigation. > + > +if MTK_THERMAL > + > +config MTK_SOC_THERMAL > + tristate "Temperature sensor driver for mediatek SoCs" > + depends on HAS_IOMEM > + depends on NVMEM > + depends on RESET_CONTROLLER > + help > + Enable this option if you want to get SoC temperature > + information for Mediatek platforms. This driver > + configures thermal controllers to collect temperature > + via AUXADC interface. > + > +endif > diff --git a/drivers/thermal/mediatek/Makefile > b/drivers/thermal/mediatek/Makefile > new file mode 100644 > index 000000000000..f75313ddce5e > --- /dev/null > +++ b/drivers/thermal/mediatek/Makefile > @@ -0,0 +1 @@ > +obj-$(CONFIG_MTK_SOC_THERMAL) += soc_temp.o > diff --git a/drivers/thermal/mtk_thermal.c > b/drivers/thermal/mediatek/soc_temp.c > similarity index 100% > rename from drivers/thermal/mtk_thermal.c > rename to drivers/thermal/mediatek/soc_temp.c We should remain the original file "mtk_thermal.c" ? I think it's a old hardware structure for mtk socs, like mt8183. For mt8183, we still need to use this file. Therefore, I think we should use a config to handle this? And also, I think we can rename the mtk_thermal.c to mtk_thermal_adc.c. soc_temp.c to mtk_thermal_lvts.c. maybe we can discuss the file name offline. The new owner of mtk thermal is James Lo. Ben Tseng is no longer in mtk. Please remove this email. Please also cc these mail in next version. james.lo@mediatek.com fan.chen@mediatek.com louis.yu@mediatek.com rex-bc.chen@mediatek.com BRs, Rex _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel