Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/arm turn on CPU_CONTROL_SWP_ENABLE.



details:   https://anonhg.NetBSD.org/src/rev/a7bd37b7b570
branches:  trunk
changeset: 955150:a7bd37b7b570
user:      mrg <mrg%NetBSD.org@localhost>
date:      Mon Sep 21 21:26:43 2020 +0000

description:
turn on CPU_CONTROL_SWP_ENABLE.

this allows armv[67] systems to use 'swp' and 'swpb' instructions,
which means they can run armv[45] software.

arm recommends ldrex/strex for armv6 and newer, and it is not
present in armv8 at all or some armv7.  we emulate it on armv8 and
need to add emulation for the some armv7.  using the hardware is
going to be faster, so, enable this path too.

ok jmcneill.

diffstat:

 sys/arch/arm/arm/armv6_start.S |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diffs (17 lines):

diff -r b2344516ebf7 -r a7bd37b7b570 sys/arch/arm/arm/armv6_start.S
--- a/sys/arch/arm/arm/armv6_start.S    Mon Sep 21 20:00:44 2020 +0000
+++ b/sys/arch/arm/arm/armv6_start.S    Mon Sep 21 21:26:43 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: armv6_start.S,v 1.27 2020/08/28 13:36:52 skrll Exp $   */
+/*     $NetBSD: armv6_start.S,v 1.28 2020/09/21 21:26:43 mrg Exp $     */
 
 /*-
  * Copyright (c) 2012, 2017, 2018 The NetBSD Foundation, Inc.
@@ -660,6 +660,7 @@
 
 #define ARMV7_SCTLR_SET        (       \
     CPU_CONTROL_UNAL_ENABLE |  \
+    CPU_CONTROL_SWP_ENABLE |   \
     0)
 
        mrc     p15, 0, r0, c1, c0, 0



Home | Main Index | Thread Index | Old Index