From 78599c32efed3247d165302a1fbe8d9203e38974 Mon Sep 17 00:00:00 2001 From: Conrad Meyer Date: Sat, 5 Dec 2020 00:33:28 +0000 Subject: Add CFI start/end proc directives to arm64, i386, and ppc Follow-up to r353959 and r368070: do the same for other architectures. arm32 already seems to use its own .fnstart/.fnend directives, which appear to be ARM-specific variants of the same thing. Likewise, MIPS uses .frame directives. Reviewed by: arichardson Differential Revision: https://reviews.freebsd.org/D27387 --- stand/libsa/powerpc/_setjmp.S | 2 ++ stand/powerpc/kboot/host_syscall.S | 13 +++++++++++++ stand/powerpc/uboot/start.S | 1 + 3 files changed, 16 insertions(+) (limited to 'stand') diff --git a/stand/libsa/powerpc/_setjmp.S b/stand/libsa/powerpc/_setjmp.S index 7c7c24b1237cd..485050f003a11 100644 --- a/stand/libsa/powerpc/_setjmp.S +++ b/stand/libsa/powerpc/_setjmp.S @@ -76,6 +76,7 @@ ASENTRY_NOPROF(_setjmp) /* f14-f31, fpscr */ li 3, 0 blr +ASEND(_setjmp) .extern sigsetmask @@ -113,3 +114,4 @@ ASENTRY_NOPROF(_longjmp) /* f14-f31, fpscr */ mr 3, 4 blr +ASEND(_longjmp) diff --git a/stand/powerpc/kboot/host_syscall.S b/stand/powerpc/kboot/host_syscall.S index 1cb9016715ac3..dc236afdeda7c 100644 --- a/stand/powerpc/kboot/host_syscall.S +++ b/stand/powerpc/kboot/host_syscall.S @@ -13,11 +13,13 @@ ENTRY(host_read) 1: li %r3, 0 blr +END(host_read) ENTRY(host_write) li %r0, 4 # SYS_write sc blr +END(host_write) ENTRY(host_seek) mr %r4,%r5 @@ -26,11 +28,13 @@ ENTRY(host_seek) li %r0, 140 # SYS_llseek sc blr +END(host_seek) ENTRY(host_llseek) li %r0, 140 # SYS_llseek sc blr +END(host_llseek) ENTRY(host_open) li %r0, 5 # SYS_open @@ -40,45 +44,54 @@ ENTRY(host_open) 1: li %r3, 0 blr +END(host_open) ENTRY(host_close) li %r0, 6 # SYS_close sc blr +END(host_close) ENTRY(host_mmap) li %r0, 90 # SYS_mmap sc blr +END(host_mmap) ENTRY(host_uname) li %r0, 122 # SYS_uname sc blr +END(host_uname) ENTRY(host_gettimeofday) li %r0, 78 # SYS_gettimeofday sc blr +END(host_gettimeofday) ENTRY(host_select) li %r0, 142 # SYS_select sc blr +END(host_select) ENTRY(kexec_load) lis %r6,21 # KEXEC_ARCH_PPC64 li %r0,268 # __NR_kexec_load sc blr +END(kexec_load) ENTRY(host_reboot) li %r0,88 # SYS_reboot sc blr +END(host_reboot) ENTRY(host_getdents) li %r0,141 # SYS_getdents sc blr +END(host_getdents) diff --git a/stand/powerpc/uboot/start.S b/stand/powerpc/uboot/start.S index 3c8d64ae724ff..cee56e6ea75b4 100644 --- a/stand/powerpc/uboot/start.S +++ b/stand/powerpc/uboot/start.S @@ -85,6 +85,7 @@ ENTRY(syscall) lwz %r30, 12(%r1) mr %r1, %r11 blr +END(syscall) /* * Data section -- cgit v1.2.3