From nobody Thu Jun 27 03:50:57 2024 X-Original-To: dev-commits-src-main@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 4W8l3P2tG3z5Nhyq; Thu, 27 Jun 2024 03:50:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4W8l3P2QYpz42Vv; Thu, 27 Jun 2024 03:50:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719460257; 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; bh=ZO2/KefHBrcKMW8QToBYeA27TP8fdIbL4LC2RHNFGi0=; b=NQwnrk8N6d+KXUrQ+9YQl0VawYU/c7SpOTWcy/7UhLRGxFxxupW99luUGAQWesdVWt3jAN fUpbC0VBXFWef+ZS2yHG+Kxieqy5MCv+kQHlUmq1WD+cGewRTMOtQDxP2UyKvGQ+37KbmZ 9u/6iOjhSGomJMtAKiOH52Jg6SCfGmQTXyCFnbRT4zEOHupKb7DQvaajMQP0W63F877D3Z WAJVy95LbdEQ/WEuswNIg8IxuFKbHkgULkA5DKwDOlZIYi7IdnR96myM8BVbQhU1nEALtx eNDAkth4QXfuyIV9hUM1PAc9+e1oJZjHEd+rBrdGuGk+0Wj7C0uHS/WQaaQ9Iw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1719460257; a=rsa-sha256; cv=none; b=xnpMLj5JP0ogcnaRPXq7bLLYc0oHL9ba2SLfbdLx2XuJoDxaxSn37rF6hsVgE7E2FLnkZl j5hqVpWLopPG+B5MY6cqmGZJGGvwgEtVi2MpHcelUYfCeqeEFYyJXTz912TZPEcNaOuY5K nwRe+L0uFo5SUYfga9jDij5fRDEV3Lx+CHjn1BSONEygunFu+rxjs36lI9/DF8XDYBzebD aB1ETJ7wlq3tReje+/eizF+0Xsv6YDopfagqkrgaed+V0x8FTvPvmplX7Dt7SibPYenHPQ okiORnfDS1J9PG36VC5EhgYVOBWhzSXqfQBZBUJgCbiTxwXMSw7eNhgabeKFDQ== 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=1719460257; 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; bh=ZO2/KefHBrcKMW8QToBYeA27TP8fdIbL4LC2RHNFGi0=; b=Et3ZqmIXr1FCtPQL3ApIeR0hkrjgJj2hf7tD+Z8mKQxlvAqf+B5lhPFflMbLfDmDd6NpLE vRHzIdiGOOF/mUkm/ZBUyLaC/bpWamcxASAWy1JrxQzTtgpl+gWb9KhYcUA4v5uLc7a+yb Y6ZY4hIuJdV38MnQ+s36UDuKdzftZmw8kh9GzV2jXwiXd1vM5xR9mt2lGMTEocfeF7ZxBB pu61sbxR9l4STkKXxD4fcLx23s6OKgSVISOOsmeL2yLwJkfrr0VQHgnLfyJIbWfxEzSovL LybNvS6jWeb+WPMwZNAczYyiSZIOVM9xluAzfiNwXOLjfAzzhqYtXVRsimwwMg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4W8l3P1wDgz1BZj; Thu, 27 Jun 2024 03:50:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 45R3ovio097790; Thu, 27 Jun 2024 03:50:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45R3ovVH097787; Thu, 27 Jun 2024 03:50:57 GMT (envelope-from git) Date: Thu, 27 Jun 2024 03:50:57 GMT Message-Id: <202406270350.45R3ovVH097787@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ryan Libby Subject: git: b195d7498b91 - main - nvme: avoid gcc -Werror=int-to-pointer-cast on 32-bit arch List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rlibby X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b195d7498b91c4a507723f71b3b383dfeef39d86 Auto-Submitted: auto-generated The branch main has been updated by rlibby: URL: https://cgit.FreeBSD.org/src/commit/?id=b195d7498b91c4a507723f71b3b383dfeef39d86 commit b195d7498b91c4a507723f71b3b383dfeef39d86 Author: Ryan Libby AuthorDate: 2024-06-27 03:50:04 +0000 Commit: Ryan Libby CommitDate: 2024-06-27 03:50:04 +0000 nvme: avoid gcc -Werror=int-to-pointer-cast on 32-bit arch Reviewed by: chuck (previous version), imp Differential Revision: https://reviews.freebsd.org/D45750 --- sys/dev/nvme/nvme_ctrlr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/nvme/nvme_ctrlr.c b/sys/dev/nvme/nvme_ctrlr.c index f058a4e33b9f..e07ac737ffc8 100644 --- a/sys/dev/nvme/nvme_ctrlr.c +++ b/sys/dev/nvme/nvme_ctrlr.c @@ -1363,14 +1363,16 @@ nvme_ctrlr_linux_passthru_cmd(struct nvme_controller *ctrlr, PHOLD(curproc); buf = uma_zalloc(pbuf_zone, M_WAITOK); buf->b_iocmd = npc->opcode & 1 ? BIO_WRITE : BIO_READ; - if (vmapbuf(buf, (void *)npc->addr, npc->data_len, 1) < 0) { + if (vmapbuf(buf, (void *)(uintptr_t)npc->addr, + npc->data_len, 1) < 0) { ret = EFAULT; goto err; } req = nvme_allocate_request_vaddr(buf->b_data, npc->data_len, nvme_npc_done, npc); } else - req = nvme_allocate_request_vaddr((void *)npc->addr, npc->data_len, + req = nvme_allocate_request_vaddr( + (void *)(uintptr_t)npc->addr, npc->data_len, nvme_npc_done, npc); } else req = nvme_allocate_request_null(nvme_npc_done, npc);