CPUFreq Kconfig fixes
Subsystems (6)
Viresh Kumar
maintainercover CPUFreq Kconfig fixes
Hi Rafael,
Recently Arnd sent few fixes where drivers were using APIs from freq_table.c but haven't selected CPU_FREQ_TABLE. Based on that, I just crossed checked all the places where it should be selected and where it shouldn't be. These are fixes around that.
I have applied these in my cpufreq-kconfig-fixes branch. Will send you a pull request separately once I get some Acks (will wait for few days).
Viresh Kumar (11):
cpufreq: blackfin: enable driver for CONFIG_BFIN_CPU_FREQ
cpufreq: cris: select CPU_FREQ_TABLE
cpufreq: davinci: select CPU_FREQ_TABLE
cpufreq: exynos: select CPU_FREQ_TABLE
cpufreq: highbank: remove select CPU_FREQ_TABLE
cpufreq: imx: select CPU_FREQ_TABLE
cpufreq: powerpc: CBE_RAS: select CPU_FREQ_TABLE
cpufreq: pxa: select CPU_FREQ_TABLE
cpufreq: S3C2416/S3C64XX: select CPU_FREQ_TABLE
cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
cpufreq: X86_AMD_FREQ_SENSITIVITY: select CPU_FREQ_TABLE
arch/arm/mach-davinci/Kconfig | 1 + arch/arm/mach-pxa/Kconfig | 3 +++ arch/arm/mach-tegra/Kconfig | 4 +--- arch/cris/Kconfig | 2 ++ drivers/cpufreq/Kconfig.arm | 6 +++++- drivers/cpufreq/Kconfig.powerpc | 1 + drivers/cpufreq/Kconfig.x86 | 1 + drivers/cpufreq/Makefile | 2 +- 8 files changed, 15 insertions(+), 5 deletions(-)
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 1/11 cpufreq: blackfin: enable driver for CONFIG_BFIN_CPU_FREQ
By mistake blackfin's cpufreq driver is enabled when CONFIG_BLACKFIN was present, whereas it should have been enabled only when CONFIG_BFIN_CPU_FREQ is present.
Fix it.
--- drivers/cpufreq/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/cpufreq/Makefile +1 -1
@@ -83,7 +83,7 @@ obj-$(CONFIG_CPU_FREQ_MAPLE) += maple-cpufreq.o ################################################################################## # Other platform drivers obj-$(CONFIG_AVR32_AT32AP_CPUFREQ) += at32ap-cpufreq.o -obj-$(CONFIG_BLACKFIN) += blackfin-cpufreq.o +obj-$(CONFIG_BFIN_CPU_FREQ) += blackfin-cpufreq.o obj-$(CONFIG_CRIS_MACH_ARTPEC3) += cris-artpec3-cpufreq.o obj-$(CONFIG_ETRAXFS) += cris-etraxfs-cpufreq.o obj-$(CONFIG_IA64_ACPI_CPUFREQ) += ia64-acpi-cpufreq.o
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [uclinux-dist-devel] [PATCH 01/11] cpufreq: blackfin: enable driver for CONFIG_BFIN_CPU_FREQ
Quoted 3 lines · On Wednesday 12 June 2013 04:15:08 Viresh Kumar wrote:
By mistake blackfin's cpufreq driver is enabled when
CONFIG_BLACKFINwas present, whereas it should have been enabled only whenCONFIG_BFIN_CPU_FREQis present.
-mike
Viresh Kumar
maintainerPATCH 2/11 cpufreq: cris: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- arch/cris/Kconfig | 2 ++ 1 file changed, 2 insertions(+)
arch/cris/Kconfig +2 -0
@@ -134,11 +134,13 @@ config SVINTO_SIM config ETRAXFS bool "ETRAX-FS-V32" + select CPU_FREQ_TABLE if CPU_FREQ help Support CRIS V32. config CRIS_MACH_ARTPEC3 bool "ARTPEC-3" + select CPU_FREQ_TABLE if CPU_FREQ help Support Axis ARTPEC-3.
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 3/11 cpufreq: davinci: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- arch/arm/mach-davinci/Kconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm/mach-davinci/Kconfig +1 -0
@@ -40,6 +40,7 @@ config ARCH_DAVINCI_DA850 bool "DA850/OMAP-L138/AM18x based system" select ARCH_DAVINCI_DA8XX select ARCH_HAS_CPUFREQ + select CPU_FREQ_TABLE select CP_INTC config ARCH_DAVINCI_DA8XX
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 4/11 cpufreq: exynos: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.arm | 2 ++ 1 file changed, 2 insertions(+)
drivers/cpufreq/Kconfig.arm +2 -0
@@ -18,6 +18,7 @@ config ARM_DT_BL_CPUFREQ config ARM_EXYNOS_CPUFREQ bool "SAMSUNG EXYNOS SoCs" depends on ARCH_EXYNOS + select CPU_FREQ_TABLE default y help This adds the CPUFreq driver common part for Samsung
@@ -46,6 +47,7 @@ config ARM_EXYNOS5250_CPUFREQ config ARM_EXYNOS5440_CPUFREQ def_bool SOC_EXYNOS5440 depends on HAVE_CLK && PM_OPP && OF + select CPU_FREQ_TABLE help This adds the CPUFreq driver for Samsung EXYNOS5440 SoC. The nature of exynos5440 clock controller is
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 5/11 cpufreq: highbank: remove select CPU_FREQ_TABLE
In reply to Viresh KumarHighbank cpufreq driver doesn't use any APIs from freq_table.c and so must not select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.arm | 1 - 1 file changed, 1 deletion(-)
drivers/cpufreq/Kconfig.arm +0 -1
@@ -57,7 +57,6 @@ config ARM_EXYNOS5440_CPUFREQ config ARM_HIGHBANK_CPUFREQ tristate "Calxeda Highbank-based" depends on ARCH_HIGHBANK - select CPU_FREQ_TABLE select GENERIC_CPUFREQ_CPU0 select PM_OPP select REGULATOR
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 05/11] cpufreq: highbank: remove select CPU_FREQ_TABLE
Quoted 5 lines · Viresh Kumar
Highbank cpufreq driver doesn't use any APIs from
freq_table.cand so must not selectCPU_FREQ_TABLE.Cc Mark Langsdorf <[email protected]>Signed-off-by Viresh Kumar <[email protected]>
Thanks for catching this.
Quoted 17 lines
--- drivers/cpufreq/Kconfig.arm | 1 - 1 file changed, 1 deletion(-)drivers/cpufreq/Kconfig.arm +0
-1@@ -57,7 +57,6 @@ config ARM_EXYNOS5440_CPUFREQ config ARM_HIGHBANK_CPUFREQ tristate "Calxeda Highbank-based" depends on ARCH_HIGHBANK - select CPU_FREQ_TABLE select GENERIC_CPUFREQ_CPU0 select PM_OPP select REGULATOR
Viresh Kumar
maintainerPATCH 6/11 cpufreq: imx: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.arm | 1 + 1 file changed, 1 insertion(+)
drivers/cpufreq/Kconfig.arm +1 -0
@@ -72,6 +72,7 @@ config ARM_IMX6Q_CPUFREQ tristate "Freescale i.MX6Q cpufreq support" depends on SOC_IMX6Q depends on REGULATOR_ANATOP + select CPU_FREQ_TABLE help This adds cpufreq driver support for Freescale i.MX6Q SOC.
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 06/11] cpufreq: imx: select CPU_FREQ_TABLE
Quoted 5 lines · Viresh Kumar
CPUFreq driver of this platform uses APIs from
freq_table.cand so must selectCPU_FREQ_TABLE.Cc Shawn Guo <[email protected]>Signed-off-by Viresh Kumar <[email protected]>
Quoted 19 lines
--- drivers/cpufreq/Kconfig.arm | 1 + 1 file changed, 1 insertion(+)drivers/cpufreq/Kconfig.arm +1
-0@@ -72,6 +72,7 @@ config ARM_IMX6Q_CPUFREQ tristate "Freescale i.MX6Q cpufreq support" depends on SOC_IMX6Q depends on REGULATOR_ANATOP + select CPU_FREQ_TABLE help This adds cpufreq driver support for Freescale i.MX6Q SOC.Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 7/11 cpufreq: powerpc: CBE_RAS: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.powerpc | 1 + 1 file changed, 1 insertion(+)
drivers/cpufreq/Kconfig.powerpc +1 -0
@@ -1,6 +1,7 @@ config CPU_FREQ_CBE tristate "CBE frequency scaling" depends on CBE_RAS && PPC_CELL + select CPU_FREQ_TABLE default m help This adds the cpufreq driver for Cell BE processors.
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 8/11 cpufreq: pxa: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- arch/arm/mach-pxa/Kconfig | 3 +++ 1 file changed, 3 insertions(+)
arch/arm/mach-pxa/Kconfig +3 -0
@@ -615,12 +615,14 @@ endmenu config PXA25x bool select CPU_XSCALE + select CPU_FREQ_TABLE if CPU_FREQ help Select code specific to PXA21x/25x/26x variants config PXA27x bool select CPU_XSCALE + select CPU_FREQ_TABLE if CPU_FREQ help Select code specific to PXA27x variants
@@ -633,6 +635,7 @@ config CPU_PXA26x config PXA3xx bool select CPU_XSC3 + select CPU_FREQ_TABLE if CPU_FREQ help Select code specific to PXA3xx variants
Signature · 1 line
1.7.12.rc2.18.g61b472e
Viresh Kumar
maintainerPATCH 9/11 cpufreq: S3C2416/S3C64XX: select CPU_FREQ_TABLE
In reply to Viresh KumarCPUFreq driver of this platform uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.arm | 2 ++ 1 file changed, 2 insertions(+)
drivers/cpufreq/Kconfig.arm +2 -0
@@ -101,6 +101,7 @@ config ARM_OMAP2PLUS_CPUFREQ config ARM_S3C2416_CPUFREQ bool "S3C2416 CPU Frequency scaling support" depends on CPU_S3C2416 + select CPU_FREQ_TABLE help This adds the CPUFreq driver for the Samsung S3C2416 and S3C2450 SoC. The S3C2416 supports changing the rate of the
@@ -123,6 +124,7 @@ config ARM_S3C2416_CPUFREQ_VCORESCALE config ARM_S3C64XX_CPUFREQ bool "Samsung S3C64XX" depends on CPU_S3C6410 + select CPU_FREQ_TABLE default y help This adds the CPUFreq driver for Samsung S3C6410 SoC.
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 09/11] cpufreq: S3C2416/S3C64XX: select CPU_FREQ_TABLE
Am Mittwoch, 12. Juni 2013, 10:15:16 schrieb Viresh Kumar:
Quoted 4 lines
CPUFreq driver of this platform uses APIs from
freq_table.cand so must selectCPU_FREQ_TABLE.Cc Heiko Stuebner <[email protected]>
For the s3c2416-part
Quoted 25 lines
Signed-off-by Viresh Kumar <[email protected]>--- drivers/cpufreq/Kconfig.arm | 2 ++ 1 file changed, 2 insertions(+)drivers/cpufreq/Kconfig.arm +2
-0@@ -101,6 +101,7 @@ config ARM_OMAP2PLUS_CPUFREQ config ARM_S3C2416_CPUFREQ bool "S3C2416 CPU Frequency scaling support" depends on CPU_S3C2416 + select CPU_FREQ_TABLE help This adds the CPUFreq driver for the Samsung S3C2416 and S3C2450 SoC. The S3C2416 supports changing the rate of the@@ -123,6 +124,7 @@ config ARM_S3C2416_CPUFREQ_VCORESCALE config ARM_S3C64XX_CPUFREQ bool "Samsung S3C64XX" depends on CPU_S3C6410 + select CPU_FREQ_TABLE default y help This adds the CPUFreq driver for Samsung S3C6410 SoC.
Viresh Kumar
maintainerPATCH 10/11 cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
In reply to Viresh KumarARCH_TEGRA selects ARCH_HAS_CPUFREQ, so CPUFREQ will be enabled for all variants of TEGRA. CPUFreq driver for tegra is enabled if ARCH_TEGRA is selected. Driver uses APIs from freq_table.c and so we must select CPU_FREQ_TABLE for ARCH_TEGRA.
This also removes select CPU_FREQ_TABLE from individual tegra variants.
--- arch/arm/mach-tegra/Kconfig | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
arch/arm/mach-tegra/Kconfig +1 -3
@@ -6,6 +6,7 @@ config ARCH_TEGRA select CLKSRC_MMIO select CLKSRC_OF select COMMON_CLK + select CPU_FREQ_TABLE select GENERIC_CLOCKEVENTS select HAVE_ARM_SCU if SMP select HAVE_ARM_TWD if LOCAL_TIMERS
@@ -28,7 +29,6 @@ config ARCH_TEGRA_2x_SOC select ARM_ERRATA_754327 if SMP select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA20
@@ -46,7 +46,6 @@ config ARCH_TEGRA_3x_SOC select ARM_ERRATA_754322 select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA30
@@ -63,7 +62,6 @@ config ARCH_TEGRA_114_SOC select ARM_ARCH_TIMER select ARM_GIC select ARM_L1_CACHE_SHIFT_6 - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA114
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 10/11] cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
Quoted 5 lines · Viresh Kumar
ARCH_TEGRAselectsARCH_HAS_CPUFREQ, so CPUFREQ will be enabled for all variants of TEGRA. CPUFreq driver for tegra is enabled ifARCH_TEGRAis selected. Driver uses APIs fromfreq_table.cand so we must selectCPU_FREQ_TABLEforARCH_TEGRA.This also removes select
CPU_FREQ_TABLEfrom individual tegra variants.
I guess the real issue here is that drivers/cpufreq/tegra-cpufreq.c gets built based on ARCH_TEGRA, which doesn't depend on nor select CPU_FREQ itself, so:
select CPU_FREQ_TABLE if CPU_FREQ
... isn't guaranteed to fire.
The correct solution seems to be:
* Add CONFIG_ARM_TEGRA_CPUFREQ to drivers/cpufreq/Kconfig.arm.
* Make that Kconfig option selct CPU_FREQ_TABLE.
* Make that Kconfig option be def_bool ARCH_TEGRA.
* Modify drivers/cpufreq/Makefile to build tegra-cpufreq.c based on that.
* Remove all the cpufreq-related stuff from arch/arm/mach-tegra/Kconfig.
That way, tegra-cpufreq.c can't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.
Re: [PATCH 10/11] cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
Quoted 17 lines · Stephen Warren
Quoted 5 lines · Viresh Kumar
ARCH_TEGRAselectsARCH_HAS_CPUFREQ, so CPUFREQ will be enabled for all variants of TEGRA. CPUFreq driver for tegra is enabled ifARCH_TEGRAis selected. Driver uses APIs fromfreq_table.cand so we must selectCPU_FREQ_TABLEforARCH_TEGRA.This also removes select
CPU_FREQ_TABLEfrom individual tegra variants.I guess the real issue here is that
drivers/cpufreq/tegra-cpufreq.cgets built based onARCH_TEGRA, which doesn't depend on nor selectCPU_FREQitself, so:select
CPU_FREQ_TABLEifCPU_FREQ... isn't guaranteed to fire.
The correct solution seems to be:
Quoted 8 lines
* Add
CONFIG_ARM_TEGRA_CPUFREQtodrivers/cpufreq/Kconfig.arm.
* Make thatKconfigoption selctCPU_FREQ_TABLE.
* Make thatKconfigoption bedef_boolARCH_TEGRA.
* Modifydrivers/cpufreq/Makefileto buildtegra-cpufreq.cbased on that.
* Remove all the cpufreq-related stuff fromarch/arm/mach-tegra/Kconfig.That way,
tegra-cpufreq.ccan't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.
Hmmm. check this out (attached too for you to test):
----------x---------------x------------
From: Viresh Kumar <[email protected]>
Date: Wed, 12 Jun 2013 12:05:48 +0530
Subject: [PATCH] cpufreq: tegra: create CONFIG_ARM_TEGRA_CPUFREQ
currently Tegra cpufreq driver gets built based on ARCH_TEGRA, which doesn't depend on nor select CPU_FREQ itself, so:
select CPU_FREQ_TABLE if CPU_FREQ
... isn't guaranteed to fire.
The correct solution seems to be:
* Add CONFIG_ARM_TEGRA_CPUFREQ to drivers/cpufreq/Kconfig.arm.
* Make that Kconfig option selct CPU_FREQ_TABLE.
* Make that Kconfig option be def_bool ARCH_TEGRA.
* Modify drivers/cpufreq/Makefile to build tegra-cpufreq.c based on that.
* Remove all the cpufreq-related stuff from arch/arm/mach-tegra/Kconfig.
That way, tegra-cpufreq.c can't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.
This patch does it.
--- arch/arm/mach-tegra/Kconfig | 3 --- drivers/cpufreq/Kconfig.arm | 8 ++++++++ drivers/cpufreq/Makefile | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-)
arch/arm/mach-tegra/Kconfig +0 -3
@@ -28,7 +28,6 @@ config ARCH_TEGRA_2x_SOC select ARM_ERRATA_754327 if SMP select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA20
@@ -46,7 +45,6 @@ config ARCH_TEGRA_3x_SOC select ARM_ERRATA_754322 select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA30
@@ -63,7 +61,6 @@ config ARCH_TEGRA_114_SOC select ARM_ARCH_TIMER select ARM_GIC select ARM_L1_CACHE_SHIFT_6 - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA114
drivers/cpufreq/Kconfig.arm +8 -0
@@ -154,3 +154,11 @@ config ARM_SPEAR_CPUFREQ default y help This adds the CPUFreq driver support for SPEAr SOCs. + +config ARM_TEGRA_CPUFREQ + bool "TEGRA CPUFreq support" + depends on ARCH_TEGRA + select CPU_FREQ_TABLE + default y + help + This adds the CPUFreq driver support for TEGRA SOCs.
drivers/cpufreq/Makefile +1 -1
@@ -71,7 +71,7 @@ obj-$(CONFIG_ARM_S5PV210_CPUFREQ) += s5pv210-cpufreq.o obj-$(CONFIG_ARM_SA1100_CPUFREQ) += sa1100-cpufreq.o obj-$(CONFIG_ARM_SA1110_CPUFREQ) += sa1110-cpufreq.o obj-$(CONFIG_ARM_SPEAR_CPUFREQ) += spear-cpufreq.o -obj-$(CONFIG_ARCH_TEGRA) += tegra-cpufreq.o +obj-$(CONFIG_ARM_TEGRA_CPUFREQ) += tegra-cpufreq.o ################################################################################## # PowerPC platform drivers
From 389d76878ec1d6eb5383cb6accf5933f35e1bb1a Mon Sep 17 00:00:00 2001
Message-Id: <389d76878ec1d6eb5383cb6accf5933f35e1bb1a.1371097396.git.viresh.kumar@linaro.org>
From: Viresh Kumar <[email protected]>
Date: Wed, 12 Jun 2013 12:05:48 +0530
Subject: [PATCH] cpufreq: tegra: create CONFIG_ARM_TEGRA_CPUFREQ
currently Tegra cpufreq driver gets built based on ARCH_TEGRA, which doesn't depend on nor select CPU_FREQ itself, so:
select CPU_FREQ_TABLE if CPU_FREQ
... isn't guaranteed to fire.
The correct solution seems to be:
* Add CONFIG_ARM_TEGRA_CPUFREQ to drivers/cpufreq/Kconfig.arm.
* Make that Kconfig option selct CPU_FREQ_TABLE.
* Make that Kconfig option be def_bool ARCH_TEGRA.
* Modify drivers/cpufreq/Makefile to build tegra-cpufreq.c based on that.
* Remove all the cpufreq-related stuff from arch/arm/mach-tegra/Kconfig.
That way, tegra-cpufreq.c can't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.
This patch does it.
--- arch/arm/mach-tegra/Kconfig | 3 --- drivers/cpufreq/Kconfig.arm | 8 ++++++++ drivers/cpufreq/Makefile | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-)
arch/arm/mach-tegra/Kconfig +0 -3
@@ -28,7 +28,6 @@ config ARCH_TEGRA_2x_SOC select ARM_ERRATA_754327 if SMP select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA20
@@ -46,7 +45,6 @@ config ARCH_TEGRA_3x_SOC select ARM_ERRATA_754322 select ARM_ERRATA_764369 if SMP select ARM_GIC - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA30
@@ -63,7 +61,6 @@ config ARCH_TEGRA_114_SOC select ARM_ARCH_TIMER select ARM_GIC select ARM_L1_CACHE_SHIFT_6 - select CPU_FREQ_TABLE if CPU_FREQ select CPU_V7 select PINCTRL select PINCTRL_TEGRA114
drivers/cpufreq/Kconfig.arm +8 -0
@@ -154,3 +154,11 @@ config ARM_SPEAR_CPUFREQ default y help This adds the CPUFreq driver support for SPEAr SOCs. + +config ARM_TEGRA_CPUFREQ + bool "TEGRA CPUFreq support" + depends on ARCH_TEGRA + select CPU_FREQ_TABLE + default y + help + This adds the CPUFreq driver support for TEGRA SOCs.
drivers/cpufreq/Makefile +1 -1
@@ -71,7 +71,7 @@ obj-$(CONFIG_ARM_S5PV210_CPUFREQ) += s5pv210-cpufreq.o obj-$(CONFIG_ARM_SA1100_CPUFREQ) += sa1100-cpufreq.o obj-$(CONFIG_ARM_SA1110_CPUFREQ) += sa1110-cpufreq.o obj-$(CONFIG_ARM_SPEAR_CPUFREQ) += spear-cpufreq.o -obj-$(CONFIG_ARCH_TEGRA) += tegra-cpufreq.o +obj-$(CONFIG_ARM_TEGRA_CPUFREQ) += tegra-cpufreq.o ################################################################################## # PowerPC platform drivers
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 10/11] cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
Quoted 24 lines · Viresh Kumar
Quoted 23 lines · Stephen Warren
Quoted 5 lines · Viresh Kumar
ARCH_TEGRAselectsARCH_HAS_CPUFREQ, so CPUFREQ will be enabled for all variants of TEGRA. CPUFreq driver for tegra is enabled ifARCH_TEGRAis selected. Driver uses APIs fromfreq_table.cand so we must selectCPU_FREQ_TABLEforARCH_TEGRA.This also removes select
CPU_FREQ_TABLEfrom individual tegra variants.I guess the real issue here is that
drivers/cpufreq/tegra-cpufreq.cgets built based onARCH_TEGRA, which doesn't depend on nor selectCPU_FREQitself, so:select
CPU_FREQ_TABLEifCPU_FREQ... isn't guaranteed to fire.
The correct solution seems to be:
* Add
CONFIG_ARM_TEGRA_CPUFREQtodrivers/cpufreq/Kconfig.arm.
* Make thatKconfigoption selctCPU_FREQ_TABLE.
* Make thatKconfigoption bedef_boolARCH_TEGRA.
* Modifydrivers/cpufreq/Makefileto buildtegra-cpufreq.cbased on that.
* Remove all the cpufreq-related stuff fromarch/arm/mach-tegra/Kconfig.
Quoted 4 lines
Quoted 2 lines
That way,
tegra-cpufreq.ccan't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.Hmmm. check this out (attached too for you to test):
This certainly generates the correct .config when I "make tegra_defconfig" after applying it, and a build after disabling CPU_FREQ links OK, so,
(I assume this patch would go through the cpufreq tree?)
Viresh Kumar
maintainerRe: [PATCH 10/11] cpufreq: tegra: select CPU_FREQ_TABLE for ARCH_TEGRA
Quoted 25 lines · Stephen Warren
Quoted 24 lines · Viresh Kumar
Quoted 23 lines · Stephen Warren
Quoted 5 lines · Viresh Kumar
ARCH_TEGRAselectsARCH_HAS_CPUFREQ, so CPUFREQ will be enabled for all variants of TEGRA. CPUFreq driver for tegra is enabled ifARCH_TEGRAis selected. Driver uses APIs fromfreq_table.cand so we must selectCPU_FREQ_TABLEforARCH_TEGRA.This also removes select
CPU_FREQ_TABLEfrom individual tegra variants.I guess the real issue here is that
drivers/cpufreq/tegra-cpufreq.cgets built based onARCH_TEGRA, which doesn't depend on nor selectCPU_FREQitself, so:select
CPU_FREQ_TABLEifCPU_FREQ... isn't guaranteed to fire.
The correct solution seems to be:
* Add
CONFIG_ARM_TEGRA_CPUFREQtodrivers/cpufreq/Kconfig.arm.
* Make thatKconfigoption selctCPU_FREQ_TABLE.
* Make thatKconfigoption bedef_boolARCH_TEGRA.
* Modifydrivers/cpufreq/Makefileto buildtegra-cpufreq.cbased on that.
* Remove all the cpufreq-related stuff fromarch/arm/mach-tegra/Kconfig.
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
That way,
tegra-cpufreq.ccan't be built if !CPU_FREQ, and Tegra's cpufreq works the same way as all the other cpufreq drivers.Hmmm. check this out (attached too for you to test):
This certainly generates the correct .config when I "make
tegra_defconfig" after applying it, and a build after disablingCPU_FREQlinks OK, so,
Yeah, I also compile tested it.
Quoted 4 lines
Tested-by Stephen Warren <[email protected]>Acked-by Stephen Warren <[email protected]>(I assume this patch would go through the cpufreq tree?)
Yes. Via my ARM cpufreq tree.
Viresh Kumar
maintainerPATCH 11/11 cpufreq: X86_AMD_FREQ_SENSITIVITY: select CPU_FREQ_TABLE
In reply to Viresh KumarThis CPUFreq driver uses APIs from freq_table.c and so must select CPU_FREQ_TABLE.
--- drivers/cpufreq/Kconfig.x86 | 1 + 1 file changed, 1 insertion(+)
drivers/cpufreq/Kconfig.x86 +1 -0
@@ -132,6 +132,7 @@ config X86_POWERNOW_K8 config X86_AMD_FREQ_SENSITIVITY tristate "AMD frequency sensitivity feedback powersave bias" depends on CPU_FREQ_GOV_ONDEMAND && X86_ACPI_CPUFREQ && CPU_SUP_AMD + select CPU_FREQ_TABLE help This adds AMD-specific powersave bias function to the ondemand governor, which allows it to make more power-conscious frequency
Signature · 1 line
1.7.12.rc2.18.g61b472e
Re: [PATCH 11/11] cpufreq: X86_AMD_FREQ_SENSITIVITY: select CPU_FREQ_TABLE
Quoted 3 lines · Viresh Kumar
This CPUFreq driver uses APIs from
freq_table.cand so must selectCPU_FREQ_TABLE.
Ah, thanks for cathcing this!
Quoted 2 lines
Cc Jacob Shin <[email protected]>Signed-off-by Viresh Kumar <[email protected]>
Quoted 20 lines
--- drivers/cpufreq/Kconfig.x86 | 1 + 1 file changed, 1 insertion(+)drivers/cpufreq/Kconfig.x86 +1
-0@@ -132,6 +132,7 @@ config X86_POWERNOW_K8 config X86_AMD_FREQ_SENSITIVITY tristate "AMD frequency sensitivity feedback powersave bias" depends on CPU_FREQ_GOV_ONDEMAND && X86_ACPI_CPUFREQ && CPU_SUP_AMD + select CPU_FREQ_TABLE help This adds AMD-specific powersave bias function to the ondemand governor, which allows it to make more power-conscious frequencySignature · 1 line
1.7.12.rc2.18.g61b472e
Quoted 7 lines · Viresh Kumar
Recently Arnd sent few fixes where drivers were using APIs from
freq_table.cbut haven't selectedCPU_FREQ_TABLE. Based on that, I just crossed checked all the places where it should be selected and where it shouldn't be. These are fixes around that.I have applied these in my cpufreq-kconfig-fixes branch. Will send you a pull request separately once I get some Acks (will wait for few days).
I don't see a patch for big.LITTLE in either linux-next or this series. Did you miss that or has it just not made into linux-next yet?
Arnd
Viresh Kumar
maintainerQuoted 6 lines · Arnd Bergmann
Quoted 5 lines · Viresh Kumar
Recently Arnd sent few fixes where drivers were using APIs from
freq_table.cbut haven't selectedCPU_FREQ_TABLE. Based on that, I just crossed checked all the places where it should be selected and where it shouldn't be. These are fixes around that.
Quoted 7 lines
Quoted 2 lines
I have applied these in my cpufreq-kconfig-fixes branch. Will send you a pull request separately once I get some Acks (will wait for few days).
Acked-by Arnd Bergmann <[email protected]>I don't see a patch for big.LITTLE in either linux-next or this series. Did you miss that or has it just not made into linux-next yet?
My ARM branch was pulled in by Rafael, 2 days back. Don't know why didn't you saw that.
Quoted 11 lines · Viresh Kumar
Quoted 9 lines · Arnd Bergmann
Quoted 7 lines · Viresh Kumar
Recently Arnd sent few fixes where drivers were using APIs from
freq_table.cbut haven't selectedCPU_FREQ_TABLE. Based on that, I just crossed checked all the places where it should be selected and where it shouldn't be. These are fixes around that.I have applied these in my cpufreq-kconfig-fixes branch. Will send you a pull request separately once I get some Acks (will wait for few days).
Quoted 7 lines
Quoted 4 lines
Acked-by Arnd Bergmann <[email protected]>I don't see a patch for big.LITTLE in either linux-next or this series. Did you miss that or has it just not made into linux-next yet?
My ARM branch was pulled in by Rafael, 2 days back. Don't know why didn't you saw that.
Ah, it seems we haven't had a new linux-next since friday.
Arnd
Quoted 14 lines · Arnd Bergmann
Quoted 13 lines · Viresh Kumar
Quoted 11 lines · Arnd Bergmann
Quoted 7 lines · Viresh Kumar
Recently Arnd sent few fixes where drivers were using APIs from
freq_table.cbut haven't selectedCPU_FREQ_TABLE. Based on that, I just crossed checked all the places where it should be selected and where it shouldn't be. These are fixes around that.I have applied these in my cpufreq-kconfig-fixes branch. Will send you a pull request separately once I get some Acks (will wait for few days).
Acked-by Arnd Bergmann <[email protected]>
Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
I don't see a patch for big.LITTLE in either linux-next or this series. Did you miss that or has it just not made into linux-next yet?
My ARM branch was pulled in by Rafael, 2 days back. Don't know why didn't you saw that.
Ah, it seems we haven't had a new linux-next since friday.
Yup, no linux-next this week.
Rafael
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.