From owner-svn-src-all@FreeBSD.ORG Thu Jun 16 08:16:51 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E56B7106566C; Thu, 16 Jun 2011 08:16:51 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail02.syd.optusnet.com.au (mail02.syd.optusnet.com.au [211.29.132.183]) by mx1.freebsd.org (Postfix) with ESMTP id 7F7938FC19; Thu, 16 Jun 2011 08:16:50 +0000 (UTC) Received: from c122-106-165-191.carlnfd1.nsw.optusnet.com.au (c122-106-165-191.carlnfd1.nsw.optusnet.com.au [122.106.165.191]) by mail02.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5G8Gl93009601 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 16 Jun 2011 18:16:48 +1000 Date: Thu, 16 Jun 2011 18:16:47 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Garrett Cooper In-Reply-To: Message-ID: <20110616180803.D1005@besplex.bde.org> References: <201106160714.p5G7Etfx017112@svn.freebsd.org> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-2089999118-1308212207=:1005" Cc: Tai-hwa Liang , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r223139 - head/lib/libstand X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 08:16:52 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-2089999118-1308212207=:1005 Content-Type: TEXT/PLAIN; charset=X-UNKNOWN; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Thu, 16 Jun 2011, Garrett Cooper wrote: > On Thu, Jun 16, 2011 at 12:19 AM, Garrett Cooper wro= te: >> On Thu, Jun 16, 2011 at 12:14 AM, Tai-hwa Liang wro= te: >>> Author: avatar >>> Date: Thu Jun 16 07:14:55 2011 >>> New Revision: 223139 >>> URL: http://svn.freebsd.org/changeset/base/223139 >>> >>> Log: >>> =A0Unbreaking build on sparc64. Why not fix it on all arches? This seems to break it on all 32-bit arches. >>> =A0Submitted by: Garrett Cooper >>> >>> Modified: >>> =A0head/lib/libstand/zalloc.c >>> >>> Modified: head/lib/libstand/zalloc.c >>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D >>> --- head/lib/libstand/zalloc.c =A0Thu Jun 16 05:26:03 2011 =A0 =A0 =A0 = =A0(r223138) >>> +++ head/lib/libstand/zalloc.c =A0Thu Jun 16 07:14:55 2011 =A0 =A0 =A0 = =A0(r223139) >>> @@ -154,7 +154,7 @@ zfree(MemPool *mp, void *ptr, iaddr_t by >>> =A0 =A0 if ((char *)ptr < (char *)mp->mp_Base || >>> =A0 =A0 =A0 =A0(char *)ptr + bytes > (char *)mp->mp_End || >>> =A0 =A0 =A0 =A0((iaddr_t)ptr & MEMNODE_SIZE_MASK) !=3D 0) >>> - =A0 =A0 =A0 panic("zfree(%p,%d): wild pointer", ptr, bytes); >>> + =A0 =A0 =A0 panic("zfree(%p,%ju): wild pointer", ptr, bytes); >> >> All of those need to be cast to (uintmax_t). Sorry :(.. Indeed. There is no format letter for intptr_t, and perhaps iaddr_t is supposed to be opaque anyway. > And you need to add #include to stand.h in order to get > uintmax_t. Here's a proper patch for amd64.. This would add namespace pollution. stand.h doesn't use anything in . It depends on normal namespace pollution in an XXX section in for the declaration of uintptr_t. It and other headers should use __uintptr_t instead. Strangely, declares uintptr_t but not uintmax_t. Bruce --0-2089999118-1308212207=:1005--