From: Will Deacon <will@kernel.org>
To: mark.rutland@arm.com
Cc: Will Deacon <will@kernel.org>, linux-arm-kernel@lists.infradead.org
Subject: [BOOTWRAPPER PATCH] Enable TME for lower exception levels
Date: Fri, 23 Aug 2019 15:50:15 +0100 [thread overview]
Message-ID: <20190823145015.15974-1-will@kernel.org> (raw)
By default, TME is not available to exception levels below EL3, so
enable it in SCR_EL3 if we detect that it is implemented.
Signed-off-by: Will Deacon <will@kernel.org>
---
arch/aarch64/boot.S | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/arch/aarch64/boot.S b/arch/aarch64/boot.S
index 74705cded338..c2fe92c90297 100644
--- a/arch/aarch64/boot.S
+++ b/arch/aarch64/boot.S
@@ -48,6 +48,13 @@ _start:
orr x0, x0, #(1 << 16) // AP key enable
orr x0, x0, #(1 << 17) // AP insn enable
1:
+ /* Enable TME if present */
+ mrs x1, id_aa64isar0_el1
+ ubfx x1, x1, #24, #4
+ cbz x1, 1f
+
+ orr x0, x0, #(1 << 34) // TME enable
+1:
#ifndef KERNEL_32
orr x0, x0, #(1 << 10) // 64-bit EL2
#endif
--
2.11.0
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next reply other threads:[~2019-08-23 14:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-23 14:50 Will Deacon [this message]
2019-08-27 11:08 ` [BOOTWRAPPER PATCH] Enable TME for lower exception levels Mark Rutland
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=20190823145015.15974-1-will@kernel.org \
--to=will@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=mark.rutland@arm.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.