From owner-svn-src-head@freebsd.org Sat Apr 30 19:51:00 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9D66EB2235F; Sat, 30 Apr 2016 19:51:00 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 63B1D1AE2; Sat, 30 Apr 2016 19:51:00 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3UJoxSo042681; Sat, 30 Apr 2016 19:50:59 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3UJoxwG042680; Sat, 30 Apr 2016 19:50:59 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201604301950.u3UJoxwG042680@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sat, 30 Apr 2016 19:50:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r298860 - head/sys/powerpc/powerpc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Apr 2016 19:51:00 -0000 Author: pfg Date: Sat Apr 30 19:50:59 2016 New Revision: 298860 URL: https://svnweb.freebsd.org/changeset/base/298860 Log: 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 Modified: head/sys/powerpc/powerpc/exec_machdep.c Modified: head/sys/powerpc/powerpc/exec_machdep.c ============================================================================== --- head/sys/powerpc/powerpc/exec_machdep.c Sat Apr 30 19:29:03 2016 (r298859) +++ head/sys/powerpc/powerpc/exec_machdep.c Sat Apr 30 19:50:59 2016 (r298860) @@ -162,7 +162,7 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, 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, * 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 /*