diff mbox

clk: mediatek: Fix MT2701 dependencies

Message ID 20170111134146.36878e01@endymion (mailing list archive)
State Superseded
Headers show

Commit Message

Jean Delvare Jan. 11, 2017, 12:41 p.m. UTC
Hi James,

On Wed, 11 Jan 2017 09:56:28 +0800, James Liao wrote:
> On Tue, 2017-01-10 at 13:03 +0100, Jean Delvare wrote:
> > What about MT8135 and MT8173, are they 32-bit SoCs as well?
> 
> MT8135 is a 32-bit SoC and MT8173 is a 64-bit SoC.

OK, so would the following change make sense?

---
 drivers/clk/mediatek/Kconfig |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)


Thanks,

Comments

Yingjoe Chen Jan. 11, 2017, 2:05 p.m. UTC | #1
On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> Hi James,
> 
> On Wed, 11 Jan 2017 09:56:28 +0800, James Liao wrote:
> > On Tue, 2017-01-10 at 13:03 +0100, Jean Delvare wrote:
> > > What about MT8135 and MT8173, are they 32-bit SoCs as well?
> > 
> > MT8135 is a 32-bit SoC and MT8173 is a 64-bit SoC.
> 
> OK, so would the following change make sense?
> 
> ---
>  drivers/clk/mediatek/Kconfig |    8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> --- linux-4.10-rc2.orig/drivers/clk/mediatek/Kconfig	2017-01-09 11:17:37.542344083 +0100
> +++ linux-4.10-rc2/drivers/clk/mediatek/Kconfig	2017-01-11 13:40:21.965890913 +0100
> @@ -52,16 +52,16 @@ config COMMON_CLK_MT2701_BDPSYS
>  
>  config COMMON_CLK_MT8135
>  	bool "Clock driver for Mediatek MT8135"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
> +	depends on (ARCH_MEDIATEK && !ARM64) || COMPILE_TEST


Why not just check for ARM?

+	depends on (ARCH_MEDIATEK && ARM) || COMPILE_TEST

Joe.C

--
To unsubscribe from this list: send the line "unsubscribe linux-clk" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Jean Delvare Jan. 11, 2017, 2:42 p.m. UTC | #2
Hi Joe,

On Wed, 11 Jan 2017 22:05:26 +0800, Yingjoe Chen wrote:
> On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> > @@ -52,16 +52,16 @@ config COMMON_CLK_MT2701_BDPSYS
> >  
> >  config COMMON_CLK_MT8135
> >  	bool "Clock driver for Mediatek MT8135"
> > -	depends on ARCH_MEDIATEK || COMPILE_TEST
> > +	depends on (ARCH_MEDIATEK && !ARM64) || COMPILE_TEST
> 
> 
> Why not just check for ARM?
> 
> +	depends on (ARCH_MEDIATEK && ARM) || COMPILE_TEST

I don't know :D Andreas suggested it for MT2701, so I assumed ARM was
set also for 64-bit kernels (like X86 is set for 64-bit kernels) and
ARM64 had to be used to differentiate. But it seems ARM isn't set for
64-bit kernels, so you are right, checking for ARM should work and is
more straightforward. I'll fix it before submitting the patch.

Thanks for the review,
James Liao Jan. 12, 2017, 3:39 a.m. UTC | #3
Hi Jean,

On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> Hi James,
> 
> On Wed, 11 Jan 2017 09:56:28 +0800, James Liao wrote:
> > On Tue, 2017-01-10 at 13:03 +0100, Jean Delvare wrote:
> > > What about MT8135 and MT8173, are they 32-bit SoCs as well?
> > 
> > MT8135 is a 32-bit SoC and MT8173 is a 64-bit SoC.
> 
> OK, so would the following change make sense?
> 
> ---
>  drivers/clk/mediatek/Kconfig |    8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> --- linux-4.10-rc2.orig/drivers/clk/mediatek/Kconfig	2017-01-09 11:17:37.542344083 +0100
> +++ linux-4.10-rc2/drivers/clk/mediatek/Kconfig	2017-01-11 13:40:21.965890913 +0100
> @@ -52,16 +52,16 @@ config COMMON_CLK_MT2701_BDPSYS
>  
>  config COMMON_CLK_MT8135
>  	bool "Clock driver for Mediatek MT8135"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
> +	depends on (ARCH_MEDIATEK && !ARM64) || COMPILE_TEST
>  	select COMMON_CLK_MEDIATEK
> -	default ARCH_MEDIATEK
> +	default y
>  	---help---
>  	  This driver supports Mediatek MT8135 clocks.
>  
>  config COMMON_CLK_MT8173
>  	bool "Clock driver for Mediatek MT8173"
> -	depends on ARCH_MEDIATEK || COMPILE_TEST
> +	depends on (ARCH_MEDIATEK && ARM64) || COMPILE_TEST
>  	select COMMON_CLK_MEDIATEK
> -	default ARCH_MEDIATEK
> +	default y
>  	---help---
>  	  This driver supports Mediatek MT8173 clocks.
> 
> Thanks,

Although MT8173 is a 64-bit SoC, but 32-bit kernel can run on it. So I
think it no need to limit COMMON_CLK_MT8173 only be enabled on ARM64
platform.


Best regards,

James


--
To unsubscribe from this list: send the line "unsubscribe linux-clk" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Jean Delvare Jan. 12, 2017, 8:40 a.m. UTC | #4
Hi James,

On Thu, 12 Jan 2017 11:39:52 +0800, James Liao wrote:
> On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> >  config COMMON_CLK_MT8173
> >  	bool "Clock driver for Mediatek MT8173"
> > -	depends on ARCH_MEDIATEK || COMPILE_TEST
> > +	depends on (ARCH_MEDIATEK && ARM64) || COMPILE_TEST
> >  	select COMMON_CLK_MEDIATEK
> > -	default ARCH_MEDIATEK
> > +	default y
> >  	---help---
> >  	  This driver supports Mediatek MT8173 clocks.
> 
> Although MT8173 is a 64-bit SoC, but 32-bit kernel can run on it. So I
> think it no need to limit COMMON_CLK_MT8173 only be enabled on ARM64
> platform.

OK, I'll leave that one alone then, thanks for the information.
Stephen Boyd Jan. 20, 2017, 11:22 p.m. UTC | #5
On 01/12, Jean Delvare wrote:
> Hi James,
> 
> On Thu, 12 Jan 2017 11:39:52 +0800, James Liao wrote:
> > On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> > >  config COMMON_CLK_MT8173
> > >  	bool "Clock driver for Mediatek MT8173"
> > > -	depends on ARCH_MEDIATEK || COMPILE_TEST
> > > +	depends on (ARCH_MEDIATEK && ARM64) || COMPILE_TEST
> > >  	select COMMON_CLK_MEDIATEK
> > > -	default ARCH_MEDIATEK
> > > +	default y
> > >  	---help---
> > >  	  This driver supports Mediatek MT8173 clocks.
> > 
> > Although MT8173 is a 64-bit SoC, but 32-bit kernel can run on it. So I
> > think it no need to limit COMMON_CLK_MT8173 only be enabled on ARM64
> > platform.
> 
> OK, I'll leave that one alone then, thanks for the information.
> 

Is this patch going another round? I haven't seen anything on the
list so far.
Jean Delvare Jan. 24, 2017, 9:46 a.m. UTC | #6
On Fri, 20 Jan 2017 15:22:14 -0800, Stephen Boyd wrote:
> On 01/12, Jean Delvare wrote:
> > Hi James,
> > 
> > On Thu, 12 Jan 2017 11:39:52 +0800, James Liao wrote:
> > > On Wed, 2017-01-11 at 13:41 +0100, Jean Delvare wrote:
> > > >  config COMMON_CLK_MT8173
> > > >  	bool "Clock driver for Mediatek MT8173"
> > > > -	depends on ARCH_MEDIATEK || COMPILE_TEST
> > > > +	depends on (ARCH_MEDIATEK && ARM64) || COMPILE_TEST
> > > >  	select COMMON_CLK_MEDIATEK
> > > > -	default ARCH_MEDIATEK
> > > > +	default y
> > > >  	---help---
> > > >  	  This driver supports Mediatek MT8173 clocks.
> > > 
> > > Although MT8173 is a 64-bit SoC, but 32-bit kernel can run on it. So I
> > > think it no need to limit COMMON_CLK_MT8173 only be enabled on ARM64
> > > platform.
> > 
> > OK, I'll leave that one alone then, thanks for the information.
> 
> Is this patch going another round? I haven't seen anything on the
> list so far.

Sorry for the delay, I'll send an update later today.
diff mbox

Patch

--- linux-4.10-rc2.orig/drivers/clk/mediatek/Kconfig	2017-01-09 11:17:37.542344083 +0100
+++ linux-4.10-rc2/drivers/clk/mediatek/Kconfig	2017-01-11 13:40:21.965890913 +0100
@@ -52,16 +52,16 @@  config COMMON_CLK_MT2701_BDPSYS
 
 config COMMON_CLK_MT8135
 	bool "Clock driver for Mediatek MT8135"
-	depends on ARCH_MEDIATEK || COMPILE_TEST
+	depends on (ARCH_MEDIATEK && !ARM64) || COMPILE_TEST
 	select COMMON_CLK_MEDIATEK
-	default ARCH_MEDIATEK
+	default y
 	---help---
 	  This driver supports Mediatek MT8135 clocks.
 
 config COMMON_CLK_MT8173
 	bool "Clock driver for Mediatek MT8173"
-	depends on ARCH_MEDIATEK || COMPILE_TEST
+	depends on (ARCH_MEDIATEK && ARM64) || COMPILE_TEST
 	select COMMON_CLK_MEDIATEK
-	default ARCH_MEDIATEK
+	default y
 	---help---
 	  This driver supports Mediatek MT8173 clocks.