summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-highbank/smc.S
diff options
context:
space:
mode:
authorRob Herring <rob.herring@calxeda.com>2012-06-07 00:20:10 +0200
committerOlof Johansson <olof@lixom.net>2012-06-08 07:39:43 +0200
commit8e56130dcbcc0608c2531c61f93175e36a300e58 (patch)
treebbeccbf47c6f4fc0f727b14b6954b536aa00f47b /arch/arm/mach-highbank/smc.S
parentMerge branch 'imx/fixes' of git://git.pengutronix.de/git/imx/linux-2.6 into f... (diff)
downloadlinux-8e56130dcbcc0608c2531c61f93175e36a300e58.tar.xz
linux-8e56130dcbcc0608c2531c61f93175e36a300e58.zip
ARM: highbank: Add smc calls to enable/disable the L2
Linux runs in non-secure mode on highbank, so we need secure monitor calls to enable and disable the PL310. Rather than invent new smc calls, the same calling convention used by OMAP is used here. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'arch/arm/mach-highbank/smc.S')
-rw-r--r--arch/arm/mach-highbank/smc.S27
1 files changed, 27 insertions, 0 deletions
diff --git a/arch/arm/mach-highbank/smc.S b/arch/arm/mach-highbank/smc.S
new file mode 100644
index 000000000000..407d17baaaa9
--- /dev/null
+++ b/arch/arm/mach-highbank/smc.S
@@ -0,0 +1,27 @@
+/*
+ * Copied from omap44xx-smc.S Copyright (C) 2010 Texas Instruments, Inc.
+ * Copyright 2012 Calxeda, Inc.
+ *
+ * This program is free software,you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/linkage.h>
+
+/*
+ * This is common routine to manage secure monitor API
+ * used to modify the PL310 secure registers.
+ * 'r0' contains the value to be modified and 'r12' contains
+ * the monitor API number.
+ * Function signature : void highbank_smc1(u32 fn, u32 arg)
+ */
+
+ENTRY(highbank_smc1)
+ stmfd sp!, {r4-r11, lr}
+ mov r12, r0
+ mov r0, r1
+ dsb
+ smc #0
+ ldmfd sp!, {r4-r11, pc}
+ENDPROC(highbank_smc1)