summaryrefslogtreecommitdiffstats
path: root/sys/powerpc
diff options
context:
space:
mode:
authorpfg <pfg@FreeBSD.org>2016-04-30 19:50:59 +0000
committerpfg <pfg@FreeBSD.org>2016-04-30 19:50:59 +0000
commit057f4169cad40be5e286183916f21a82ac5f1069 (patch)
tree052473ac316633f1483a2315e76be862e3a67672 /sys/powerpc
parenta4a64126435b1a0e25214625107187188b9437ae (diff)
downloadFreeBSD-src-057f4169cad40be5e286183916f21a82ac5f1069.zip
FreeBSD-src-057f4169cad40be5e286183916f21a82ac5f1069.tar.gz
powerpc: Replace rounddown() from r298856 with roundup().
Both are equivalent but roundup is more logical for this case. Catch another case while here. Pointed out by: jhibbits
Diffstat (limited to 'sys/powerpc')
-rw-r--r--sys/powerpc/powerpc/exec_machdep.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/powerpc/powerpc/exec_machdep.c b/sys/powerpc/powerpc/exec_machdep.c
index aaa6d9c..c78899d 100644
--- a/sys/powerpc/powerpc/exec_machdep.c
+++ b/sys/powerpc/powerpc/exec_machdep.c
@@ -162,7 +162,7 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
code = siginfo32.si_code;
sfp = (caddr_t)&sf32;
sfpsize = sizeof(sf32);
- rndfsize = rounddown(sizeof(sf32) + 15, 16);
+ rndfsize = roundup(sizeof(sf32), 16);
/*
* Save user context
@@ -189,9 +189,9 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
* 64-bit PPC defines a 288 byte scratch region
* below the stack.
*/
- rndfsize = 288 + rounddown(sizeof(sf) + 47, 48);
+ rndfsize = 288 + roundup(sizeof(sf), 48);
#else
- rndfsize = rounddown(sizeof(sf) + 15, 16);
+ rndfsize = roundup(sizeof(sf), 16);
#endif
/*
OpenPOWER on IntegriCloud