linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: viresh.kumar@st.com (Viresh KUMAR)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V2 49/69] ST SPEAr13xx: add L2 cache support
Date: Fri,  1 Oct 2010 17:26:09 +0530	[thread overview]
Message-ID: <cfeb5d8653735f68acee9dfed7d91e4e2441d329.1285933332.git.viresh.kumar@st.com> (raw)
In-Reply-To: <cover.1285933331.git.viresh.kumar@st.com>

From: Shiraz Hashim <shiraz.hashim@st.com>

Signed-off-by: shiraz hashim <shiraz.hashim@st.com>
Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
---
 arch/arm/mach-spear13xx/spear13xx.c |   19 +++++++++++++++++++
 arch/arm/mm/Kconfig                 |    2 +-
 2 files changed, 20 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-spear13xx/spear13xx.c b/arch/arm/mach-spear13xx/spear13xx.c
index c86bd1c..8c8a21d 100644
--- a/arch/arm/mach-spear13xx/spear13xx.c
+++ b/arch/arm/mach-spear13xx/spear13xx.c
@@ -22,6 +22,7 @@
 #include <asm/irq.h>
 #include <asm/localtimer.h>
 #include <asm/mach/arch.h>
+#include <asm/hardware/cache-l2x0.h>
 #include <asm/smp_twd.h>
 #include <mach/irqs.h>
 #include <mach/generic.h>
@@ -526,6 +527,17 @@ struct platform_device spear13xx_pcie_gadget2_device = {
 /* Do spear13xx familiy common initialization part here */
 void __init spear13xx_init(void)
 {
+#ifdef CONFIG_CACHE_L2X0
+	/*
+	 * 512KB (64KB/way), 8-way associativity, parity supported
+	 *
+	 * TODO: 0x249, picked from nomadik, to be analyzed
+	 * Comment from nomadik:
+	 * At full speed latency must be >=2, so 0x249 in low bits
+	 */
+	l2x0_init(__io_address(SPEAR13XX_L2CC_BASE), 0x00260249, 0xfe00ffff);
+#endif
+
 	sdhci_enable();
 }
 
@@ -548,6 +560,13 @@ struct map_desc spear13xx_io_desc[] __initdata = {
 		.pfn		= __phys_to_pfn(SPEAR13XX_A9SM_PERIP_BASE),
 		.length		= SZ_8K,
 		.type		= MT_DEVICE
+#ifdef CONFIG_CACHE_L2X0
+	}, {
+		.virtual	= IO_ADDRESS(SPEAR13XX_L2CC_BASE),
+		.pfn		= __phys_to_pfn(SPEAR13XX_L2CC_BASE),
+		.length		= SZ_4K,
+		.type		= MT_DEVICE
+#endif
 	}, {
 		.virtual	= IO_ADDRESS(SPEAR13XX_MISC_BASE),
 		.pfn		= __phys_to_pfn(SPEAR13XX_MISC_BASE),
diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig
index a0a2928..f3eea13 100644
--- a/arch/arm/mm/Kconfig
+++ b/arch/arm/mm/Kconfig
@@ -772,7 +772,7 @@ config CACHE_L2X0
 	depends on REALVIEW_EB_ARM11MP || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 || \
 		   REALVIEW_EB_A9MP || ARCH_MX35 || ARCH_MX31 || MACH_REALVIEW_PBX || \
 		   ARCH_NOMADIK || ARCH_OMAP4 || ARCH_S5PV310 || ARCH_TEGRA || \
-		   ARCH_U8500 || ARCH_VEXPRESS_CA9X4
+		   ARCH_SPEAR13XX || ARCH_U8500 || ARCH_VEXPRESS_CA9X4
 	default y
 	select OUTER_CACHE
 	select OUTER_CACHE_SYNC
-- 
1.7.2.2

  parent reply	other threads:[~2010-10-01 11:56 UTC|newest]

Thread overview: 91+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-01 11:55 [PATCH V2 00/69] Updating SPEAr Support Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 01/69] ARM: move sev definition to common system.h include file Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 02/69] sp810 Fix: Switch to slow mode before sysctl_soft_reset Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 03/69] ST SPEAr: Padmux code Updated Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 04/69] ST SPEAr: Making clock functions more generic Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 05/69] ST SPEAr: Formalized timer support Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 06/69] ST SPEAr13XX: Adding machine specific header files Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 07/69] ST SPEAr13XX: Adding machine specific src files Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 08/69] ST SPEAr: Adding support for SPEAr13xx SoC in spear generic plat/ Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 09/69] ST SPEAr13XX: Added compilation support in arch/arm/ Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 10/69] ST SPEAr1300: Adding default config file Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 11/69] ST SPEAr: Adding support for CLCD on SPEAr3xx/6xx Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 12/69] ST SPEAr: Updating Clock Support Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 13/69] ST SPEAr: Adding Debugfs support on clock framework Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 14/69] ST SPEAr: Correcting SOC Config base address for spear320 Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 15/69] ST SPEAr: Adding PLGPIO driver for spear platform Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 16/69] rtc: Adding support for spear rtc Viresh KUMAR
2010-10-04 22:52   ` Alessandro Zummo
2010-10-05  3:37     ` viresh kumar
2010-10-01 11:55 ` [PATCH V2 17/69] ST SPEAr: Adding machine support for rtc-spear Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 18/69] ST SPEAr: adding support for synopsis i2c designware Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 19/69] USB host: Adding USB ehci & ohci support for spear platform Viresh KUMAR
2010-10-19  5:51   ` viresh kumar
2010-10-01 11:55 ` [PATCH V2 20/69] ST SPEAr: Adding machine support for USB host Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 21/69] Keyboard: Adding support for spear-keyboard Viresh KUMAR
2010-10-05 15:47   ` Dmitry Torokhov
2010-10-06  3:58     ` viresh kumar
2010-10-06  6:16       ` Dmitry Torokhov
2010-10-06  7:11         ` viresh kumar
2010-11-10  6:44         ` viresh kumar
2010-10-01 11:55 ` [PATCH V2 22/69] ST SPEAr: Adding machine support for keyboard Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 23/69] ST SPEAr: Added ARM PL061 GPIO Support on SPEAr13xx and modified resource size Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 24/69] ST SPEAr: Adding support for ST's PWM IP Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 25/69] ST SPEAr: Add smi driver for serial NOR flash Viresh KUMAR
2010-10-19  5:55   ` viresh kumar
2010-10-01 11:55 ` [PATCH V2 26/69] ST SPEAr: Adding support for serial nor flash in all spear platforms Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 27/69] ST SPEAr: Adding Watchdog support Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 28/69] ST SPEAr: Adding machine support for nand Viresh KUMAR
2010-11-28  6:27   ` stanley.miao
2010-11-29  4:21     ` viresh kumar
2010-10-01 11:55 ` [PATCH V2 29/69] Newly erased page read workaround Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 30/69] ST SPEAr: Added PCIE host controller base driver support Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 31/69] ST SPEAr: Adding support for SSP PL022 Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 32/69] ST SPEAr: Adding support for SDHCI (SDIO) Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 33/69] ST SPEAr: Changing resource size of amba devices to SZ_4K Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 34/69] ST SPEAr: Replacing SIZE macro's with actual required size Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 35/69] SPEAr: defines base addresses as ulong Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 36/69] ST SPEAr: Adding miscellaneous devices Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 37/69] ST SPEAr 13xx : Adding support for SPEAr1310 Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 38/69] ST SPEAr: Adding support for DDR in clock framework Viresh KUMAR
2010-10-01 11:55 ` [PATCH V2 39/69] ST SPEAr : EMI (Extrenal Memory Interface) controller driver Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 40/69] ST SPEAr : FSMC (Flexible Static Memory Controller) NOR interface driver Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 41/69] SPEAr Clock Framework: Adding support for PLL frequency change Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 42/69] SPEAr Power Management: Added the support for Standby mode Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 43/69] GIC: Added dummy handlers for Power Management Suspend Resume Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 44/69] SPEAr CPU freq: Adding support for CPU Freq framework Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 45/69] ST SPEAr: PCIE gadget suppport Viresh KUMAR
2010-10-19  5:59   ` viresh kumar
2010-10-19 21:48     ` Andrew Morton
2010-10-20  3:49       ` viresh kumar
2010-10-19 21:47   ` Andrew Morton
2010-10-21 14:18     ` Pratyush ANAND
2010-10-21 17:25       ` Andrew Morton
2010-10-01 11:56 ` [PATCH V2 46/69] ST SPEAr13xx: Adding machine support for pci gadget Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 47/69] ST SPEAr13xx: Adding CPU hotplug support added for SMP platforms Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 48/69] ST SPEAr: replace readl, writel with __raw_readl, __raw_writel in uncompress.h Viresh KUMAR
2010-10-01 11:56 ` Viresh KUMAR [this message]
2010-10-01 11:56 ` [PATCH V2 50/69] ST SPEAr13xx: Modified static mappings Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 51/69] SPEAr: Adding and Updating Clock definitions Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 52/69] SPEAr : Pad multiplexing handling modified Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 53/69] SPEAr13xx : Fixed part devices in SPEAr13xx addded to the generic implementation Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 54/69] SPEAr : Updating pad multiplexing support Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 55/69] ST SPEAr3xx: Passing pmx devices address from machine *.c files Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 56/69] ST SPEAr Clock Framework: Updating for single image solution Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 57/69] SPEAr3xx: Make local structures static Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 58/69] SPEAR3xx: Rename register/irq defines to remove naming conflicts Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 59/69] SPEAr3xx: Rework pmx_dev code to remove conflicts Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 60/69] SPEAr3xx: Rework KConfig to allow all boards to be compiled in Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 61/69] SPEAr3xx: Replace defconfigs with single unified defconfig Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 62/69] ST SPEAr: Appending spear3** with global structures Viresh KUMAR
2010-10-01 16:21   ` viresh kumar
2010-10-04  6:01     ` viresh kumar
2010-10-01 11:56 ` [PATCH V2 63/69] ST SPEAr3xx: Updating plgpio and emi source to make it compliant with single image strategy Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 64/69] SPEAr6xx: Rework Kconfig for single image solution Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 65/69] ST SPEAR6xx: renaming spear600_defconfig as spear6xx_defconfig Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 66/69] ST SPEAr13xx: Pass default padmux settings as parameter to spear13**_init routine Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 67/69] ST SPEAr: Adding devices & clocks Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 68/69] ST SPEAr: Adding information in Documentation/ and MAINTAINERS Viresh KUMAR
2010-10-01 11:56 ` [PATCH V2 69/69] ST SPEAr: Updating defconfigs Viresh KUMAR
2010-10-12  6:55 ` [PATCH V2 00/69] Updating SPEAr Support viresh kumar
2010-10-25  8:39   ` viresh kumar

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=cfeb5d8653735f68acee9dfed7d91e4e2441d329.1285933332.git.viresh.kumar@st.com \
    --to=viresh.kumar@st.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).