diff options
author | Dave Martin <dave.martin@linaro.org> | 2011-11-29 10:56:19 -0500 |
---|---|---|
committer | Dave Martin <dave.martin@linaro.org> | 2011-12-19 08:46:11 -0500 |
commit | ce5ea9f3767e8589521319cae2eb6e05c52bd056 (patch) | |
tree | 29e08e74c3ecd3a6b8a4875d3e631b17ff456fef /arch/arm/mm | |
parent | caca6a03d365883564885f2c1da3e88dcf65d139 (diff) |
ARM: l2x0/pl310: Refactor Kconfig to be more maintainable
Making CACHE_L2X0 depend on (huge list of MACH_ and ARCH_ configs)
is bothersome to maintain and likely to lead to merge conflicts.
This patch moves the knowledge of which platforms have a L2x0 or
PL310 cache controller to the individual machines. To enable this,
a new MIGHT_HAVE_CACHE_L2X0 config option is introduced to allow
machines to indicate that they may have such a cache controller
independently of each other.
Boards/SoCs which cannot reliably operate without the L2 cache
controller support will need to select CACHE_L2X0 directly from
their own Kconfigs instead. This applies to some TrustZone-enabled
boards where Linux runs in the Normal World, for example.
Signed-off-by: Dave Martin <dave.martin@linaro.org>
Acked-by: Anton Vorontsov <cbouatmailru@gmail.com>
(for cns3xxx)
Acked-by: Tony Lindgren <tony@atomide.com>
(for omap)
Acked-by: Shawn Guo <shawn.guo@linaro.org>
(for imx)
Acked-by: Kukjin Kim <kgene.kim@samsung.com>
(for exynos)
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
(for imx)
Acked-by: Olof Johansson <olof@lixom.net>
(for tegra)
Diffstat (limited to 'arch/arm/mm')
-rw-r--r-- | arch/arm/mm/Kconfig | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index 67f75a0b66d6..acb1c36adadd 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig | |||
@@ -816,14 +816,23 @@ config CACHE_FEROCEON_L2_WRITETHROUGH | |||
816 | Say Y here to use the Feroceon L2 cache in writethrough mode. | 816 | Say Y here to use the Feroceon L2 cache in writethrough mode. |
817 | Unless you specifically require this, say N for writeback mode. | 817 | Unless you specifically require this, say N for writeback mode. |
818 | 818 | ||
819 | config MIGHT_HAVE_CACHE_L2X0 | ||
820 | bool | ||
821 | help | ||
822 | This option should be selected by machines which have a L2x0 | ||
823 | or PL310 cache controller, but where its use is optional. | ||
824 | |||
825 | The only effect of this option is to make CACHE_L2X0 and | ||
826 | related options available to the user for configuration. | ||
827 | |||
828 | Boards or SoCs which always require the cache controller | ||
829 | support to be present should select CACHE_L2X0 directly | ||
830 | instead of this option, thus preventing the user from | ||
831 | inadvertently configuring a broken kernel. | ||
832 | |||
819 | config CACHE_L2X0 | 833 | config CACHE_L2X0 |
820 | bool "Enable the L2x0 outer cache controller" | 834 | bool "Enable the L2x0 outer cache controller" if MIGHT_HAVE_CACHE_L2X0 |
821 | depends on REALVIEW_EB_ARM11MP || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 || \ | 835 | default MIGHT_HAVE_CACHE_L2X0 |
822 | REALVIEW_EB_A9MP || ARCH_IMX_V6_V7 || MACH_REALVIEW_PBX || \ | ||
823 | ARCH_NOMADIK || ARCH_OMAP4 || ARCH_EXYNOS4 || ARCH_TEGRA || \ | ||
824 | ARCH_U8500 || ARCH_VEXPRESS_CA9X4 || ARCH_SHMOBILE || \ | ||
825 | ARCH_PRIMA2 || ARCH_ZYNQ || ARCH_CNS3XXX || ARCH_HIGHBANK | ||
826 | default y | ||
827 | select OUTER_CACHE | 836 | select OUTER_CACHE |
828 | select OUTER_CACHE_SYNC | 837 | select OUTER_CACHE_SYNC |
829 | help | 838 | help |