summaryrefslogtreecommitdiff
path: root/nuttx/arch/arm/src/common
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-07-27 10:03:33 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-07-27 10:03:33 -0600
commit149c502323f818b0a359422f0541d4ba5b77b999 (patch)
tree91226b199d5caf23f7a9b29c71fa03a7b49f8711 /nuttx/arch/arm/src/common
parente15988ed7f9d8212d36ee85e0cf643c1d64aaf4f (diff)
downloadnuttx-149c502323f818b0a359422f0541d4ba5b77b999.tar.gz
nuttx-149c502323f818b0a359422f0541d4ba5b77b999.tar.bz2
nuttx-149c502323f818b0a359422f0541d4ba5b77b999.zip
ARM: Move L2 cache initialization to much later in the sequence
Diffstat (limited to 'nuttx/arch/arm/src/common')
-rw-r--r--nuttx/arch/arm/src/common/up_initialize.c4
-rw-r--r--nuttx/arch/arm/src/common/up_internal.h14
2 files changed, 15 insertions, 3 deletions
diff --git a/nuttx/arch/arm/src/common/up_initialize.c b/nuttx/arch/arm/src/common/up_initialize.c
index f54ead0de..8b6b4bd37 100644
--- a/nuttx/arch/arm/src/common/up_initialize.c
+++ b/nuttx/arch/arm/src/common/up_initialize.c
@@ -246,5 +246,9 @@ void up_initialize(void)
/* Initialize USB -- device and/or host */
up_usbinitialize();
+
+ /* Initialize the L2 cache if present and selected */
+
+ up_l2ccinitialize();
board_led_on(LED_IRQSENABLED);
}
diff --git a/nuttx/arch/arm/src/common/up_internal.h b/nuttx/arch/arm/src/common/up_internal.h
index 1c172db50..4cd464347 100644
--- a/nuttx/arch/arm/src/common/up_internal.h
+++ b/nuttx/arch/arm/src/common/up_internal.h
@@ -449,6 +449,14 @@ void lowconsole_init(void);
void weak_function up_dmainitialize(void);
#endif
+/* Cache control ************************************************************/
+
+#ifdef CONFIG_ARCH_L2CACHE
+void up_l2ccinitialize(void);
+#else
+# define up_l2ccinitialize()
+#endif
+
/* Memory management ********************************************************/
#if CONFIG_MM_REGIONS > 1
@@ -475,10 +483,10 @@ void board_led_off(int led);
/* Networking ***************************************************************/
-/* Defined in board/up_network.c for board-specific ethernet implementations,
- * or chip/xyx_ethernet.c for chip-specific ethernet implementations, or
+/* Defined in board/up_network.c for board-specific Ethernet implementations,
+ * or chip/xyx_ethernet.c for chip-specific Ethernet implementations, or
* common/up_etherstub.c for a cornercase where the network is enabled yet
- * there is no ethernet driver to be initialized.
+ * there is no Ethernet driver to be initialized.
*/
#ifdef CONFIG_NET