From nobody Fri Jun 28 03:41:16 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 4W9Lnm3qJsz5P6Bf; Fri, 28 Jun 2024 03:41:16 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4W9Lnm1tdNz4G4W; Fri, 28 Jun 2024 03:41:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719546076; 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=f8U++9D3HGMnZLnhhZ0YE1CDFV+cqvGgDlQXSOaRKxs=; b=E4dPlyqj9kcn4iG4t6DDX/G3E5k+p5S/+9GxGVC10sx0OrkCxaWsFHAUSj/bzKIav85P4q DBFvvnQOU0QfrHZRkaBbpD7K3EaRKaWev0h5Lvy4u84x0GW8YXJ8wQ9BY+PoXHb90QuCJA w0vfl7PouMNjwZdK7GgmPRzW3+8Y65/UE4SnKVn84VpzYjaEsM2Vz2s1HyntYk6Ny3p16m 4hR6NYQmFMwYtW/S84e3BVtw2zfMvBT/akBFhT3DnBiq2cd9zHoplseMLIaAGLeBkHt9aG 8KDQrs70EADGIwkLAbxjBcxxPQY+oZqGiMBi+bihPrKOjSIF2+BQubO/HlzYqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1719546076; a=rsa-sha256; cv=none; b=UngwJchiQb6nsf+k5mrpPcUNHOVSM2z7PbhOMIwMJqi9IlxN8Nt9pXUkX7kMM4QhWkGUvw IKnuE9QOs1/hpdHanz7nLTgn/bPHR60A5zxKionOTXGLManU3RtrOWdOR7RMdhBjPQb9tZ kRUfYMFyw9YWSyP8xxWlc4WVITM0qunKLObn3HEgZK7yIgtB4c6WJRs0pBraxyKvgnrYIC 6+z6L5xyB0Y6rFZU0zTYFRTTuV5I7KVHYE2NYpbGzo1RLhDpoE3sA3FGDjpFT4IV4J5xZL CE6vw3ry1vpNdhT3QlPeAV1WczxNpFrqTTSJxaNUNxHNVfj3T+cokPlLIsQ88A== 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=1719546076; 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=f8U++9D3HGMnZLnhhZ0YE1CDFV+cqvGgDlQXSOaRKxs=; b=mrbwSarWuT5cxYN+2nu4kHmKWNT9DKLpBv5mL/eoLo7/zeJPekelKDbKx4h74kNTCCVMNA NEfoMf2mLzRcJPNKdrLHYtMj1bD1aqSnPW1XdghwWk9AlI0+tqaTPNe4nyoPnc60+54gdE taaMQ2aZXto1J0KlhMFYmNaggNPWvldY34STNvnLvDaiy23SW9fP7B3DoRzct0rlEP05/T pj37cMI/Xxcg4cZB7WTVD8VNclofTE3BC3zkmwT7ATHeBrfmhR3uNfx+9J8GJOWVX/TBBW 4T8qAGmKje6HVRLfGk6fxGZkCNxCVsfU6N+z/cp9zmyu2BEow8sjwz+gnNk5xQ== 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 4W9Lnm1Vl9zg9f; Fri, 28 Jun 2024 03:41:16 +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 45S3fGnH011253; Fri, 28 Jun 2024 03:41:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45S3fGuU011250; Fri, 28 Jun 2024 03:41:16 GMT (envelope-from git) Date: Fri, 28 Jun 2024 03:41:16 GMT Message-Id: <202406280341.45S3fGuU011250@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: c02a8caf50bb - main - tcp_bbr: avoid gcc -Werror=pointer-to-int-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: c02a8caf50bb68cb675fdef30ed803cc67a3bdac Auto-Submitted: auto-generated The branch main has been updated by rlibby: URL: https://cgit.FreeBSD.org/src/commit/?id=c02a8caf50bb68cb675fdef30ed803cc67a3bdac commit c02a8caf50bb68cb675fdef30ed803cc67a3bdac Author: Ryan Libby AuthorDate: 2024-06-28 03:37:26 +0000 Commit: Ryan Libby CommitDate: 2024-06-28 03:37:26 +0000 tcp_bbr: avoid gcc -Werror=pointer-to-int-cast on 32-bit arch Reviewed by: tuexen Differential Revision: https://reviews.freebsd.org/D45751 --- sys/netinet/tcp_stacks/bbr.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/netinet/tcp_stacks/bbr.c b/sys/netinet/tcp_stacks/bbr.c index cee8da71af0b..cb87932fa8db 100644 --- a/sys/netinet/tcp_stacks/bbr.c +++ b/sys/netinet/tcp_stacks/bbr.c @@ -2356,11 +2356,11 @@ bbr_log_to_event(struct tcp_bbr *bbr, uint32_t cts, int32_t to_num) log.u_bbr.flex1 = bbr->bbr_timer_src; log.u_bbr.flex2 = 0; log.u_bbr.flex3 = bbr->r_ctl.rc_hpts_flags; - ar = (uint64_t)(bbr->r_ctl.rc_resend); + ar = (uintptr_t)(bbr->r_ctl.rc_resend); ar >>= 32; ar &= 0x00000000ffffffff; log.u_bbr.flex4 = (uint32_t)ar; - ar = (uint64_t)bbr->r_ctl.rc_resend; + ar = (uintptr_t)bbr->r_ctl.rc_resend; ar &= 0x00000000ffffffff; log.u_bbr.flex5 = (uint32_t)ar; log.u_bbr.flex6 = TICKS_2_USEC(bbr->rc_tp->t_rxtcur); @@ -2718,12 +2718,13 @@ bbr_type_log_hdwr_pacing(struct tcp_bbr *bbr, const struct ifnet *ifp, { if (tcp_bblogging_on(bbr->rc_tp)) { union tcp_log_stackspecific log; + uint64_t ifp64 = (uintptr_t)ifp; bbr_fill_in_logging_data(bbr, &log.u_bbr, cts); log.u_bbr.flex1 = ((hw_rate >> 32) & 0x00000000ffffffff); log.u_bbr.flex2 = (hw_rate & 0x00000000ffffffff); - log.u_bbr.flex3 = (((uint64_t)ifp >> 32) & 0x00000000ffffffff); - log.u_bbr.flex4 = ((uint64_t)ifp & 0x00000000ffffffff); + log.u_bbr.flex3 = ((ifp64 >> 32) & 0x00000000ffffffff); + log.u_bbr.flex4 = (ifp64 & 0x00000000ffffffff); log.u_bbr.bw_inuse = rate; log.u_bbr.flex5 = line; log.u_bbr.flex6 = error;