From nobody Wed Apr 17 13:55:08 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 4VKMqJ4Szfz5GxKG; Wed, 17 Apr 2024 13:55:08 +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 4VKMqJ3wg6z4rYw; Wed, 17 Apr 2024 13:55:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713362108; 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=R+fLcXHhANxmUveNp76eyTW3lLljerfjTAyWdRCunbc=; b=AnMU8WIA8rOOAbWuJ0p2j08VV1DSYS1Bav6TpaG0+zyQEVH+khxUGYPVSQPqzAjiejX9ED etCCxCBAbhcVu7dVudl6SYaIVMCJuLyIcGH8TVTxfwHnc4QswpdxAPm7M0EBWhbRXs2Kwt e9xdbCYZDdlpQBi9SGUhVmolo33e5ZpTEtMwTzkWF41FSjAgSL8NrH3eXFzcp5DCwlQgWc 15SAeqhT2xS5cyjP4ltKWiT0K4GQ8CL0ePiKxgZGWxji0WK5RJVmMRMZeO86EQ08b64eCy /BOsbU7Xr3XuK0ggWGHpD/M2jIE3iLRZa7KM5GtlcTyD/9/OPcA7gVN6nntxFA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713362108; a=rsa-sha256; cv=none; b=EwLdIOe8Zoa4tL6CrfzlPC8lcepjx+qSXNfpoYRcs5Qi3MvJ58LnFhG2AiE0Yg+wJeZQu0 OGVHPlpGR2BywAeylY+Dn1ZgnCyYiluGDdq9AeKG8QGLw8LNsM15VAduRkZBYMGGDkk5D4 kC62pxkcgMkfd2qTIEFvVxfoSnOz6khgm/1oSwq97ljub2Im4bG42B1Ey4Gpq5zaLKVly5 8/QDi74bpq4RzPDX319NvoAcTkf2spo/C359Hpq/X2ZA4nXWrDYotRVVLponlaEFe4yL1z ZuFY/wlJjvCF31hQ0vfGKSgeoCivWJ0XPUMAaHNBi3HBvutxrYskGfc1DHue2g== 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=1713362108; 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=R+fLcXHhANxmUveNp76eyTW3lLljerfjTAyWdRCunbc=; b=ylP2idF7rNQSZJm6aCUfGuBgIQzsoJulYWDMrlpweEMUwoWBCTeybwTj9XackS2fGTomz4 dsdpft2yOrY1gviDHDOWzuAzEB6ZRdxWX2LrAriCaKiFQNlNLwTJJEug2h248NRn6I3Kg3 VZb5L0kDF6dSa9zcBMlqJbJpBF1ydW8x0s+OtQzPEdn0VtECzZhLRI+Qy32Z/XBZSjRbAV CPafEhDkw2x7hdzc7qiOK8fo/9meVj+4o6icc09wiTemdULLezeH9xhiXI/mOfq4Q3VHh0 J/Oh/MSDFoCkRmz2nO3NRLRJH052NpU2LlFNmBJDhkJoQ910VqSj0AXzZFfb/g== 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 4VKMqJ3XSdzTrL; Wed, 17 Apr 2024 13:55:08 +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 43HDt8nD037387; Wed, 17 Apr 2024 13:55:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43HDt81j037384; Wed, 17 Apr 2024 13:55:08 GMT (envelope-from git) Date: Wed, 17 Apr 2024 13:55:08 GMT Message-Id: <202404171355.43HDt81j037384@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Michael Tuexen Subject: git: 60898a7cef0b - stable/14 - tcp hpts: initialize variable 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 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 60898a7cef0b47efe4b2b81460fccfc2002b819a Auto-Submitted: auto-generated The branch stable/14 has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=60898a7cef0b47efe4b2b81460fccfc2002b819a commit 60898a7cef0b47efe4b2b81460fccfc2002b819a Author: Michael Tuexen AuthorDate: 2024-04-05 15:30:31 +0000 Commit: Michael Tuexen CommitDate: 2024-04-17 13:54:52 +0000 tcp hpts: initialize variable Ensure that tv.tv_sec is zero in all code paths. Reported by: Coverity Scan CID: 1527724 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44584 (cherry picked from commit aaaa01c0c858fd703194c6cbd515dd514574381f) --- sys/netinet/tcp_hpts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/tcp_hpts.c b/sys/netinet/tcp_hpts.c index 89b9611e643f..af7b2691ff2e 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -1650,6 +1650,7 @@ tcp_hpts_thread(void *ctx) * enough activity in the system that we don't need to * run as often (if we were not directly woken). */ + tv.tv_sec = 0; if (hpts->p_direct_wake == 0) { counter_u64_add(hpts_back_tosleep, 1); if (hpts->p_on_queue_cnt >= conn_cnt_thresh) { @@ -1674,7 +1675,6 @@ tcp_hpts_thread(void *ctx) * Directly woken most likely to reset the * callout time. */ - tv.tv_sec = 0; tv.tv_usec = hpts->p_mysleep.tv_usec; } goto back_to_sleep;