diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2021-06-04 00:09:35 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2021-06-04 00:09:35 +0000 |
commit | 2b206cbd5cb51bbd08044c3302de662bc20d168b (patch) | |
tree | b026c1211dd3abe4787889e44c6e84d882bdbc66 /sys/arch/amd64/stand | |
parent | 31320ef1e46bb17c4216d0f69b03831896afb7c3 (diff) |
yasuoka@ pointed out that amd64 clang now understands
'__attribute((ms_abi))', removing the need for the EFI_CALL
abstraction.
Nuke the amd64 EFI_CALL dance from all copies of eficall.h,
remove eficall.S from the build.
ok kettenis@ yasuoka@
Diffstat (limited to 'sys/arch/amd64/stand')
-rw-r--r-- | sys/arch/amd64/stand/efiboot/bootx64/Makefile | 4 | ||||
-rw-r--r-- | sys/arch/amd64/stand/efiboot/eficall.h | 38 |
2 files changed, 3 insertions, 39 deletions
diff --git a/sys/arch/amd64/stand/efiboot/bootx64/Makefile b/sys/arch/amd64/stand/efiboot/bootx64/Makefile index c9bb38760f4..4bc51d5f705 100644 --- a/sys/arch/amd64/stand/efiboot/bootx64/Makefile +++ b/sys/arch/amd64/stand/efiboot/bootx64/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.3 2020/06/14 16:00:11 deraadt Exp $ +# $OpenBSD: Makefile,v 1.4 2021/06/04 00:09:34 krw Exp $ .include <bsd.own.mk> @@ -7,7 +7,7 @@ NOMAN= # OBJFMT= efi-app-x86_64 SOFTRAID= yes COPTS+= -I${EFIDIR}/include/amd64 -SRCS+= start_amd64.S run_i386.S mdrandom.c eficall.S +SRCS+= start_amd64.S run_i386.S mdrandom.c LDSCRIPT= ldscript.amd64 .include "${.CURDIR}/../Makefile.common" diff --git a/sys/arch/amd64/stand/efiboot/eficall.h b/sys/arch/amd64/stand/efiboot/eficall.h index 0e6276414ce..bf180894333 100644 --- a/sys/arch/amd64/stand/efiboot/eficall.h +++ b/sys/arch/amd64/stand/efiboot/eficall.h @@ -1,4 +1,4 @@ -/* $OpenBSD: eficall.h,v 1.3 2017/11/25 19:02:07 patrick Exp $ */ +/* $OpenBSD: eficall.h,v 1.4 2021/06/04 00:09:34 krw Exp $ */ /* * Copyright (c) 2015 YASUOKA Masahiko <yasuoka@yasuoka.net> @@ -16,40 +16,4 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#if !defined(__amd64__) - #define EFI_CALL(_func_, ...) (_func_)(__VA_ARGS__) - -#else - -extern uint64_t efi_call(int, void *, ...); - -#define _call_0(_func) \ - efi_call(0, (_func)) -#define _call_1(_func, _1) \ - efi_call(1, (_func), (_1)) -#define _call_2(_func, _1, _2) \ - efi_call(2, (_func), (_1), (_2)) -#define _call_3(_func, _1, _2, _3) \ - efi_call(3, (_func), (_1), (_2), (_3)) -#define _call_4(_func, _1, _2, _3, _4) \ - efi_call(4, (_func), (_1), (_2), (_3), (_4)) -#define _call_5(_func, _1, _2, _3, _4, _5) \ - efi_call(5, (_func), (_1), (_2), (_3), (_4), (_5)) -#define _call_6(_func, _1, _2, _3, _4, _5, _6) \ - efi_call(6, (_func), (_1), (_2), (_3), (_4), (_5), (_6)) -#define _call_7(_func, _1, _2, _3, _4, _5, _6, _7) \ - efi_call(7, (_func), (_1), (_2), (_3), (_4), (_5), (_6), (_7)) -#define _call_8(_func, _1, _2, _3, _4, _5, _6, _7, _8) \ - efi_call(8, (_func), (_1), (_2), (_3), (_4), (_5), (_6), (_7), (_8)) -#define _call_9(_func, _1, _2, _3, _4, _5, _6, _7, _8, _9) \ - efi_call(9, (_func), (_1), (_2), (_3), (_4), (_5), (_6), (_7), (_8), (_9)) -#define _call_10(_func, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10) \ - efi_call(10, (_func), (_1), (_2), (_3), (_4), (_5), (_6), (_7), (_8), (_9), (_10)) - -#define _efi_call_fn(_func, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _fn, ...) _fn - -#define EFI_CALL(...) \ - _efi_call_fn(__VA_ARGS__, _call_10, _call_9, _call_8, _call_7, _call_6, \ - _call_5, _call_4, _call_3, _call_2, _call_1, _call_0)(__VA_ARGS__) -#endif |