All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jean Delvare <jdelvare@suse.de>
To: sean.wang@mediatek.com
Cc: matthias.bgg@gmail.com, linux-mediatek@lists.infradead.org,
	arnd@arndb.de, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] soc: mediatek: place Kconfig for all SoC drivers under menu
Date: Thu, 5 Oct 2017 10:52:53 +0200	[thread overview]
Message-ID: <20171005105253.2f8dd7df@endymion> (raw)
In-Reply-To: <41e81ac2998b171ff4715cb2dc17f15aa10b7518.1507173110.git.sean.wang@mediatek.com>

Hi Sean,

On Thu, 5 Oct 2017 11:17:49 +0800, sean.wang@mediatek.com wrote:
> From: Sean Wang <sean.wang@mediatek.com>
> 
> Add cleanup for placing all Kconfig for all MediaTek SoC drivers under
> the independent menu as other SoCs vendor usually did. Since the menu
> would be shown depending on "ARCH_MEDIATEK || COMPILE_TEST" selected and
> MTK_PMIC_WRAP is still safe compiling with the case of "COMPILE_TEST"
> only, the superfluous dependency for those items under the menu also is
> also being removed for the sake of simplicity.
> 
> Signed-off-by: Sean Wang <sean.wang@mediatek.com>
> ---
>  drivers/soc/mediatek/Kconfig | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/soc/mediatek/Kconfig b/drivers/soc/mediatek/Kconfig
> index 609bb34..a7d0667 100644
> --- a/drivers/soc/mediatek/Kconfig
> +++ b/drivers/soc/mediatek/Kconfig
> @@ -1,9 +1,11 @@
>  #
>  # MediaTek SoC drivers
>  #
> +menu "MediaTek SoC drivers"
> +	depends on ARCH_MEDIATEK || COMPILE_TEST
> +
>  config MTK_INFRACFG
>  	bool "MediaTek INFRACFG Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	select REGMAP
>  	help
>  	  Say yes here to add support for the MediaTek INFRACFG controller. The
> @@ -12,7 +14,6 @@ config MTK_INFRACFG
>  
>  config MTK_PMIC_WRAP
>  	tristate "MediaTek PMIC Wrapper Support"
> -	depends on ARCH_MEDIATEK
>  	depends on RESET_CONTROLLER
>  	select REGMAP
>  	help
> @@ -22,7 +23,6 @@ config MTK_PMIC_WRAP
>  
>  config MTK_SCPSYS
>  	bool "MediaTek SCPSYS Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	default ARCH_MEDIATEK
>  	select REGMAP
>  	select MTK_INFRACFG
> @@ -30,3 +30,5 @@ config MTK_SCPSYS
>  	help
>  	  Say yes here to add support for the MediaTek SCPSYS power domain
>  	  driver.
> +
> +endmenu

While trying to test this, I found that I am not able to test-compile
these drivers. The problem is in drivers/soc/Makefile:

obj-$(CONFIG_ARCH_MEDIATEK)     += mediatek/

So while Kconfig lets me select the drivers when COMPILE_TEST is
enabled, the build system itself ignores the directory in which these
drivers reside and they aren't built.

If you really want your drivers to be test-compilable then you must
change the above to:

obj-y				+= mediatek/

I'll send a patch.

Your patch itself looks good to me.

Reviewed-by: Jean Delvare <jdelvare@suse.de>

-- 
Jean Delvare
SUSE L3 Support

WARNING: multiple messages have this Message-ID (diff)
From: jdelvare@suse.de (Jean Delvare)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2] soc: mediatek: place Kconfig for all SoC drivers under menu
Date: Thu, 5 Oct 2017 10:52:53 +0200	[thread overview]
Message-ID: <20171005105253.2f8dd7df@endymion> (raw)
In-Reply-To: <41e81ac2998b171ff4715cb2dc17f15aa10b7518.1507173110.git.sean.wang@mediatek.com>

Hi Sean,

On Thu, 5 Oct 2017 11:17:49 +0800, sean.wang at mediatek.com wrote:
> From: Sean Wang <sean.wang@mediatek.com>
> 
> Add cleanup for placing all Kconfig for all MediaTek SoC drivers under
> the independent menu as other SoCs vendor usually did. Since the menu
> would be shown depending on "ARCH_MEDIATEK || COMPILE_TEST" selected and
> MTK_PMIC_WRAP is still safe compiling with the case of "COMPILE_TEST"
> only, the superfluous dependency for those items under the menu also is
> also being removed for the sake of simplicity.
> 
> Signed-off-by: Sean Wang <sean.wang@mediatek.com>
> ---
>  drivers/soc/mediatek/Kconfig | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/soc/mediatek/Kconfig b/drivers/soc/mediatek/Kconfig
> index 609bb34..a7d0667 100644
> --- a/drivers/soc/mediatek/Kconfig
> +++ b/drivers/soc/mediatek/Kconfig
> @@ -1,9 +1,11 @@
>  #
>  # MediaTek SoC drivers
>  #
> +menu "MediaTek SoC drivers"
> +	depends on ARCH_MEDIATEK || COMPILE_TEST
> +
>  config MTK_INFRACFG
>  	bool "MediaTek INFRACFG Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	select REGMAP
>  	help
>  	  Say yes here to add support for the MediaTek INFRACFG controller. The
> @@ -12,7 +14,6 @@ config MTK_INFRACFG
>  
>  config MTK_PMIC_WRAP
>  	tristate "MediaTek PMIC Wrapper Support"
> -	depends on ARCH_MEDIATEK
>  	depends on RESET_CONTROLLER
>  	select REGMAP
>  	help
> @@ -22,7 +23,6 @@ config MTK_PMIC_WRAP
>  
>  config MTK_SCPSYS
>  	bool "MediaTek SCPSYS Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	default ARCH_MEDIATEK
>  	select REGMAP
>  	select MTK_INFRACFG
> @@ -30,3 +30,5 @@ config MTK_SCPSYS
>  	help
>  	  Say yes here to add support for the MediaTek SCPSYS power domain
>  	  driver.
> +
> +endmenu

While trying to test this, I found that I am not able to test-compile
these drivers. The problem is in drivers/soc/Makefile:

obj-$(CONFIG_ARCH_MEDIATEK)     += mediatek/

So while Kconfig lets me select the drivers when COMPILE_TEST is
enabled, the build system itself ignores the directory in which these
drivers reside and they aren't built.

If you really want your drivers to be test-compilable then you must
change the above to:

obj-y				+= mediatek/

I'll send a patch.

Your patch itself looks good to me.

Reviewed-by: Jean Delvare <jdelvare@suse.de>

-- 
Jean Delvare
SUSE L3 Support

WARNING: multiple messages have this Message-ID (diff)
From: Jean Delvare <jdelvare@suse.de>
To: <sean.wang@mediatek.com>
Cc: <matthias.bgg@gmail.com>, <linux-mediatek@lists.infradead.org>,
	<arnd@arndb.de>, <linux-arm-kernel@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] soc: mediatek: place Kconfig for all SoC drivers under menu
Date: Thu, 5 Oct 2017 10:52:53 +0200	[thread overview]
Message-ID: <20171005105253.2f8dd7df@endymion> (raw)
In-Reply-To: <41e81ac2998b171ff4715cb2dc17f15aa10b7518.1507173110.git.sean.wang@mediatek.com>

Hi Sean,

On Thu, 5 Oct 2017 11:17:49 +0800, sean.wang@mediatek.com wrote:
> From: Sean Wang <sean.wang@mediatek.com>
> 
> Add cleanup for placing all Kconfig for all MediaTek SoC drivers under
> the independent menu as other SoCs vendor usually did. Since the menu
> would be shown depending on "ARCH_MEDIATEK || COMPILE_TEST" selected and
> MTK_PMIC_WRAP is still safe compiling with the case of "COMPILE_TEST"
> only, the superfluous dependency for those items under the menu also is
> also being removed for the sake of simplicity.
> 
> Signed-off-by: Sean Wang <sean.wang@mediatek.com>
> ---
>  drivers/soc/mediatek/Kconfig | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/soc/mediatek/Kconfig b/drivers/soc/mediatek/Kconfig
> index 609bb34..a7d0667 100644
> --- a/drivers/soc/mediatek/Kconfig
> +++ b/drivers/soc/mediatek/Kconfig
> @@ -1,9 +1,11 @@
>  #
>  # MediaTek SoC drivers
>  #
> +menu "MediaTek SoC drivers"
> +	depends on ARCH_MEDIATEK || COMPILE_TEST
> +
>  config MTK_INFRACFG
>  	bool "MediaTek INFRACFG Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	select REGMAP
>  	help
>  	  Say yes here to add support for the MediaTek INFRACFG controller. The
> @@ -12,7 +14,6 @@ config MTK_INFRACFG
>  
>  config MTK_PMIC_WRAP
>  	tristate "MediaTek PMIC Wrapper Support"
> -	depends on ARCH_MEDIATEK
>  	depends on RESET_CONTROLLER
>  	select REGMAP
>  	help
> @@ -22,7 +23,6 @@ config MTK_PMIC_WRAP
>  
>  config MTK_SCPSYS
>  	bool "MediaTek SCPSYS Support"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
>  	default ARCH_MEDIATEK
>  	select REGMAP
>  	select MTK_INFRACFG
> @@ -30,3 +30,5 @@ config MTK_SCPSYS
>  	help
>  	  Say yes here to add support for the MediaTek SCPSYS power domain
>  	  driver.
> +
> +endmenu

While trying to test this, I found that I am not able to test-compile
these drivers. The problem is in drivers/soc/Makefile:

obj-$(CONFIG_ARCH_MEDIATEK)     += mediatek/

So while Kconfig lets me select the drivers when COMPILE_TEST is
enabled, the build system itself ignores the directory in which these
drivers reside and they aren't built.

If you really want your drivers to be test-compilable then you must
change the above to:

obj-y				+= mediatek/

I'll send a patch.

Your patch itself looks good to me.

Reviewed-by: Jean Delvare <jdelvare@suse.de>

-- 
Jean Delvare
SUSE L3 Support

  reply	other threads:[~2017-10-05  8:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-05  3:17 [PATCH v2] soc: mediatek: place Kconfig for all SoC drivers under menu sean.wang
2017-10-05  3:17 ` sean.wang
2017-10-05  3:17 ` sean.wang at mediatek.com
2017-10-05  8:52 ` Jean Delvare [this message]
2017-10-05  8:52   ` Jean Delvare
2017-10-05  8:52   ` Jean Delvare
2017-10-16  7:27   ` Sean Wang
2017-10-16  7:27     ` Sean Wang
2017-10-16  7:27     ` Sean Wang
2017-10-20 10:14 ` Matthias Brugger
2017-10-20 10:14   ` Matthias Brugger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171005105253.2f8dd7df@endymion \
    --to=jdelvare@suse.de \
    --cc=arnd@arndb.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    --cc=sean.wang@mediatek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.