summaryrefslogtreecommitdiffstats
path: root/libexec
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2020-03-11 12:53:19 +0000
committerderaadt <deraadt@openbsd.org>2020-03-11 12:53:19 +0000
commitf377c7672bd38a70b428cd7751ceff0af609e750 (patch)
treef513ba805b364ed7490f062132397828c6e0dd9b /libexec
parentfix spelling of IMSG_VMDOP_TERMINATE_VM_RESPONSE in comment (diff)
downloadwireguard-openbsd-f377c7672bd38a70b428cd7751ceff0af609e750.tar.xz
wireguard-openbsd-f377c7672bd38a70b428cd7751ceff0af609e750.zip
Anthony Steinhauser reports that 32-bit arm cpus have the same speculation
problems as 64-bit models. For the syscall instruction issue, add nop;nop after swi 0, in preparation for jumping over a speculation barrier here later. ok kettenis
Diffstat (limited to 'libexec')
-rw-r--r--libexec/ld.so/arm/SYS.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/libexec/ld.so/arm/SYS.h b/libexec/ld.so/arm/SYS.h
index e20b67ae0ae..2147c2a81c5 100644
--- a/libexec/ld.so/arm/SYS.h
+++ b/libexec/ld.so/arm/SYS.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: SYS.h,v 1.1 2017/08/27 21:59:52 deraadt Exp $ */
+/* $OpenBSD: SYS.h,v 1.2 2020/03/11 12:53:21 deraadt Exp $ */
/*
* Copyright (c) 2004 Dale Rahn
@@ -31,7 +31,9 @@
#define SYSTRAP(x) \
ldr r12, =SYS_ ## x; \
- swi 0
+ swi 0; \
+ nop; \
+ nop
#define DL_SYSCALL(n) \
.global __CONCAT(_dl_,n) ;\