diff options
author | 2018-07-03 23:22:48 +0000 | |
---|---|---|
committer | 2018-07-03 23:22:48 +0000 | |
commit | 1d66f0a004efa322e2047d0371a4cfe69dca0a66 (patch) | |
tree | 0721a18719a6bd71b839607a66e6ecea036ff60d /sys/lib/libkern/arch/amd64/strcmp.S | |
parent | Add retguard macros for kernel asm. (diff) | |
download | wireguard-openbsd-1d66f0a004efa322e2047d0371a4cfe69dca0a66.tar.xz wireguard-openbsd-1d66f0a004efa322e2047d0371a4cfe69dca0a66.zip |
Add retguard macros for libkern
ok deraadt
Diffstat (limited to 'sys/lib/libkern/arch/amd64/strcmp.S')
-rw-r--r-- | sys/lib/libkern/arch/amd64/strcmp.S | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/lib/libkern/arch/amd64/strcmp.S b/sys/lib/libkern/arch/amd64/strcmp.S index 7f1656ee80a..3ba13a49c34 100644 --- a/sys/lib/libkern/arch/amd64/strcmp.S +++ b/sys/lib/libkern/arch/amd64/strcmp.S @@ -1,4 +1,4 @@ -/* $OpenBSD: strcmp.S,v 1.3 2014/12/09 15:13:57 reyk Exp $ */ +/* $OpenBSD: strcmp.S,v 1.4 2018/07/03 23:22:48 mortimer Exp $ */ /* $NetBSD: strcmp.S,v 1.2 2014/03/22 19:16:34 jakllsch Exp $ */ /* @@ -9,6 +9,7 @@ #include <machine/asm.h> ENTRY(strcmp) + RETGUARD_SETUP(strcmp, r10) /* * Align s1 to word boundary. * Consider unrolling loop? @@ -68,4 +69,5 @@ ENTRY(strcmp) movzbq %al,%rax movzbq %dl,%rdx subq %rdx,%rax + RETGUARD_CHECK(strcmp, r10) ret |