diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2019-10-27 21:07:14 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2019-10-27 21:07:14 +0000 |
commit | 05d27237debea4c7dd54f002db12755a3ca47d24 (patch) | |
tree | d8992c859b90eef09e15875e8f99033f6ef397d8 /lib | |
parent | c4621639ff59c6ab686b86855d867f8174e28b93 (diff) |
Mark the _Qp_{mul,div,add,sub} functions as 'protected' to eliminate
PLT entries and prevent overriding
ok kettenis@ deraadt@
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/arch/sparc64/fpu/fpu_qp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libc/arch/sparc64/fpu/fpu_qp.c b/lib/libc/arch/sparc64/fpu/fpu_qp.c index c0821b2b487..c2cfbdec9f2 100644 --- a/lib/libc/arch/sparc64/fpu/fpu_qp.c +++ b/lib/libc/arch/sparc64/fpu/fpu_qp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fpu_qp.c,v 1.8 2019/06/21 17:00:58 jca Exp $ */ +/* $OpenBSD: fpu_qp.c,v 1.9 2019/10/27 21:07:13 guenther Exp $ */ /*- * Copyright (c) 2002 Jake Burkholder. @@ -50,7 +50,8 @@ _Qp_ ## op(u_int *c, u_int *a, u_int *b) \ r = __fpu_ ## op(&fe); \ c[0] = __fpu_ftoq(&fe, r, c); \ } \ -DEF_STRONG(_Qp_ ## op); +DEF_STRONG(_Qp_ ## op); \ +asm(".protected _Qp_"#op); #define _QP_TTOQ(qname, fname, ntype, signpos, atype, ...) \ void _Qp_ ## qname ## toq(u_int *c, ntype n); \ |