From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760987AbbCDJyr (ORCPT ); Wed, 4 Mar 2015 04:54:47 -0500 Received: from mout.kundenserver.de ([212.227.126.131]:49433 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1760971AbbCDJyp (ORCPT ); Wed, 4 Mar 2015 04:54:45 -0500 From: Arnd Bergmann To: Yingjoe Chen Cc: Catalin Marinas , Mark Rutland , devicetree@vger.kernel.org, Vladimir Murzin , Russell King , Hongzhou Yang , Linus Walleij , eddie.huang@mediatek.com, linux-kernel@vger.kernel.org, Rob Herring , maoguang.meng@mediatek.com, alan.cheng@mediatek.com, toby.liu@mediatek.com, Sascha Hauer , Matthias Brugger , dandan.he@mediatek.com, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH 1/3] arm64: mediatek: Add config option for mt8173. Date: Wed, 04 Mar 2015 10:53:39 +0100 Message-ID: <2108883.zjHYNOn4mC@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: <1425436267.21342.39.camel@mtksdaap41> References: <1422342836-27689-1-git-send-email-hongzhou.yang@mediatek.com> <20150225111107.GA29206@localhost> <1425436267.21342.39.camel@mtksdaap41> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Provags-ID: V03:K0:FxGLOO6h6FvSfb082ZaZy1PShjaIY1fxMTG4QRiV4XlzqmHXK5/ uHUaD+/F1AoHGrMdEkQvAspg0W7cVr781sNkNMNdoAgDB0BomNFn7yBrgqiBJWr318Y2cpM c/Iwi3+LD6wVjE9wal5uGb3VNQjX2tGTe9+zC+G2d0e2QM4W1j83oGmBgcfBqOYAS7+oQw+ JC6tlo+GHeQZyZRFpq/FQ== X-UI-Out-Filterresults: notjunk:1; Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wednesday 04 March 2015 10:31:07 Yingjoe Chen wrote: > Hi, > > Since we support devicetree, we don't need MACH_* to build a working > kernel. This is true even for our v7 soc. We intend to use it to reduce > numbers of drivers in product kernel binary. > Most drivers are shared among the same SoCs family, but some are not. > Currently for pinctrl driver, we are doing this so user don't need to > select them one by one: > > config PINCTRL_MT8173 > def_bool MACH_MT8173 > select PINCTRL_MTK_COMMON > > Alternatively, we could add these MACH_* to some other places, eg, > drivers/soc/mediatek. Or we don't add MACH_* at all, and have all > drivers export their own Kconfig option. User will need to select each > of them one-by-one. > > What do you think? I would rather see these as user-selectable options, which has the other benefit of giving compile-time coverage. For your example, I'd suggest doing config PINCTRL_MT8173 bool "Mediatek MT8173 pin control" depends on ARCH_MEDIATEK || COMPILE_TEST select PINCTRL_MTK_COMMON help ... a useful description ... Arnd From mboxrd@z Thu Jan 1 00:00:00 1970 From: arnd@arndb.de (Arnd Bergmann) Date: Wed, 04 Mar 2015 10:53:39 +0100 Subject: [PATCH 1/3] arm64: mediatek: Add config option for mt8173. In-Reply-To: <1425436267.21342.39.camel@mtksdaap41> References: <1422342836-27689-1-git-send-email-hongzhou.yang@mediatek.com> <20150225111107.GA29206@localhost> <1425436267.21342.39.camel@mtksdaap41> Message-ID: <2108883.zjHYNOn4mC@wuerfel> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Wednesday 04 March 2015 10:31:07 Yingjoe Chen wrote: > Hi, > > Since we support devicetree, we don't need MACH_* to build a working > kernel. This is true even for our v7 soc. We intend to use it to reduce > numbers of drivers in product kernel binary. > Most drivers are shared among the same SoCs family, but some are not. > Currently for pinctrl driver, we are doing this so user don't need to > select them one by one: > > config PINCTRL_MT8173 > def_bool MACH_MT8173 > select PINCTRL_MTK_COMMON > > Alternatively, we could add these MACH_* to some other places, eg, > drivers/soc/mediatek. Or we don't add MACH_* at all, and have all > drivers export their own Kconfig option. User will need to select each > of them one-by-one. > > What do you think? I would rather see these as user-selectable options, which has the other benefit of giving compile-time coverage. For your example, I'd suggest doing config PINCTRL_MT8173 bool "Mediatek MT8173 pin control" depends on ARCH_MEDIATEK || COMPILE_TEST select PINCTRL_MTK_COMMON help ... a useful description ... Arnd