From nobody Fri May 17 16:16:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VgsY15QRRz5LPdH; Fri, 17 May 2024 16:16:53 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VgsY14tbxz4Rqf; Fri, 17 May 2024 16:16:53 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1715962613; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=HKfO1VTao9ABCMlo0uLfqWhaQJmSeqbsDzIulgQ43W8=; b=spaxghVt2oLx7lpowDiluuXYis0yU/yTkxMhryhB0mlLr9Q/00LwRsrGBdhTY/xQYHoa/I R2ML25gWUPqcV7hQr0twmxbgtaLnhepFaZDo60+QJRicgXrNFfwz4cfY9SZDg48peoXjqC VGORN3yrlhynf0lhddKAWuyWO30NqUtxRirfUP21ctL1dZcvJwVQNFPU2D46cfX9aZzD6q gUoCbE7zRwxfUAOsr27qjZvjwX6XiAE5qd7i7J/4wfUQTAkaVllW1W0a+WmkXnCofbrQOl AVLo3xbavdcaij7g4ZdCtO7BJykSDZTU0DfO1LNkg4sLoa5+qzCpKvUdMxULlw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1715962613; a=rsa-sha256; cv=none; b=gA3KQk5phHueIjhMXSVFlXXVgNMivmcMOIVU43KoOy/hUQIoys6HNHSevo4fKpvxFVSE7V p0jgO5v28qX4VFnbIgLwyOJUya1VDuP/QYkqE/Xnm7tbSbMUO2QZ1llNA+PLsEqclUfVin 4LOmxj13MajP0MSFsN+0c2y33R3HFpwvZYgrfa+OQZQIDnElwEvZmaP7035nC1r5xbgFNz 5/nBlCxuA1oGtag8lQQLgjtbR0a+RzEvDxTxSnGrZlO4nI9wUNqdzuvRWQpIB3nFeJFafC E1SoeTQGpuxvMmHTW6FpSDt3C7n2GWPHWGatqjcd1+c/UY6GptQ/qZuP/Gn5Yw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1715962613; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=HKfO1VTao9ABCMlo0uLfqWhaQJmSeqbsDzIulgQ43W8=; b=R6SLFh/ruWWOj9J1FJuZfKHa4EM8/zpraFEfP0r3Bc3F8QtW9lMjNrtVRNWENbmM1hYPtQ 9rw0Ti5pwK/v9vhXB/mbJgXPKWlLOT9f6A9cdRlicxOSl1tQhs8e9oGsqVYzb9f3pR2RXk b/23mWhYidvLtVEKRVrBFHci+Rd02NSQQ6R1qOo/f3FsG+BV+eDe1AnqKzDnbjmPkLSB8N mjp+J5NCJx0PkfsjDaUBuU0zNBiPJ00AfCqgrtTSj6TSkyQMeuWbUnNLUqQq6H40avGSj1 E+jcZ6QZss2isXWjiLJ7qC3Bjy69i19aPg/cakpvEm3Uafrav3HH1ImyywQB5Q== Received: from [IPV6:2601:644:937f:4c50:c0c0:cf11:cc26:3c0e] (unknown [IPv6:2601:644:937f:4c50:c0c0:cf11:cc26:3c0e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4VgsY11DwwzGKn; Fri, 17 May 2024 16:16:53 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <1fd6acc5-290c-447c-b35c-89b002d71526@FreeBSD.org> Date: Fri, 17 May 2024 09:16:52 -0700 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: d316de24faa7 - main - zfs: Avoid a gcc -Wint-to-pointer-cast warning Content-Language: en-US To: Brooks Davis , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202405171601.44HG1TTZ047312@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <202405171601.44HG1TTZ047312@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 5/17/24 9:01 AM, Brooks Davis wrote: > The branch main has been updated by brooks: > > URL: https://cgit.FreeBSD.org/src/commit/?id=d316de24faa7453118a90fb0e9839e8026e36a4e > > commit d316de24faa7453118a90fb0e9839e8026e36a4e > Author: Brooks Davis > AuthorDate: 2024-05-17 15:59:06 +0000 > Commit: Brooks Davis > CommitDate: 2024-05-17 16:01:19 +0000 > > zfs: Avoid a gcc -Wint-to-pointer-cast warning > > On 32-bit platforms long long is generally 64-bits. Sufficiently modern > versions of gcc (13 in my testing) complains when casting a pointer to > an integer of a different width so cast to uintptr_t first to avoid the > warning. > > Fix i386 gcc builds while we wait for this to be merged to OpenZFS. > > Sponsored by: DARPA, AFRL > Pull Request: https://github.com/openzfs/zfs/pull/16203 > --- > sys/contrib/openzfs/module/zfs/spa.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/sys/contrib/openzfs/module/zfs/spa.c b/sys/contrib/openzfs/module/zfs/spa.c > index ec2b674fb7ee..c3800e018c73 100644 > --- a/sys/contrib/openzfs/module/zfs/spa.c > +++ b/sys/contrib/openzfs/module/zfs/spa.c > @@ -6832,7 +6832,7 @@ spa_tryimport(nvlist_t *tryconfig) > */ > char *name = kmem_alloc(MAXPATHLEN, KM_SLEEP); > (void) snprintf(name, MAXPATHLEN, "%s-%llx-%s", > - TRYIMPORT_NAME, (u_longlong_t)curthread, poolname); > + TRYIMPORT_NAME, (u_longlong_t)(uintptr_t)curthread, poolname); > > mutex_enter(&spa_namespace_lock); > spa = spa_add(name, tryconfig, NULL); Huh, this shouldn't be broken anymore. The kernel module has an unconditional CFLAGS to disable -Wint-to-pointer-cast, and I just added it to the userspace build back in 766c4ad385ccf96f8cf10129363a6bfa58b3e92f. OTOH, it might be nice to re-enable the warning if it is clean for both kernel and userland. -- John Baldwin