From nobody Fri Apr 05 15:34:20 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 4VB2bJ6GrVz5GgT8; Fri, 5 Apr 2024 15:34:20 +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 4VB2bJ4nWNz4PHJ; Fri, 5 Apr 2024 15:34:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1712331260; 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=Z+WRPIeDUS4BhSVvTRriVq0p8mh3dUC+2die1jJzfLQ=; b=e1iLxtnbsZYv1KZWyT0oua+v4YXIusn180kHkjqVjMXh9L0zbpgltwyvC5Rp3MEAqZOlGg re7BCLwgBwN75Nenxubh+WddS+5Pb+TnStvkZOfRZ8C6Gf6yuWOapsb1xBLYRSmviQNCCa rQZHKzRYRXb4F5AYz7yPhmwFk7rp+wjC/VwV4Wm6KzVaBa0E4QWAmNJiuBmWJpayaoSxe/ jn9+Ex/3CBtfekrV32xnWclX4fQWU83gg9KRQrneS0omcqwgCEYE88HiI5LJ052ymBSnZp KVeKhnRx6V7scLgnAKQQaMVonu/crWXLr4K9UHzvAdy9OCwwoKpYFcS1//IMjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1712331260; a=rsa-sha256; cv=none; b=KFsf+nrpCXyq9BFeh112ovYlvDkGUEvAuAVqkKHYIbj+EnkMaing9mEXVANq6InZmn/Zks tHKPZVWKPOjCXuc1um4Xus6J0CUW9rMmaRRDyZOW9rGTLCbpIWSCaZcRhEsa2TFgTvl2dj hgMaQMO8HVXpilnTPGgVi4jJOyRdyGp4EeB3p/NQMw4e1uAI5yjQkpO/QVLE8HWblSU223 Q462apIqLInRbJ57spM64bs/Spa9OP44oG+OWyYSzOAY8nRse7klzNCKIfaIbBoDbtRDKX 625CnmZDWb+uJd6NOjBIzXLkGcfE0ERvqG3XPKlSh1v4N28KMNAW4Otbwpt9mg== 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=1712331260; 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=Z+WRPIeDUS4BhSVvTRriVq0p8mh3dUC+2die1jJzfLQ=; b=BTjEhpBhhAko9dm0wX2wLfq5oJiOTdS2dOQtCwg3+SHYIPRoOfOa+ZncvsfopIOAClY2yd mdsr0yeMWeOXQ2BBU6c7MkMZgMby/B0swqItR16sNqLBita/Bs0Lp0+4VwLVc+OFOWjg6n 5QrkTI15XaN9dtT8lhqcSzAQO/xni0Ci5IQJesYcREIgP2KCawPVbIBGEcYWi9eRGYl7tY q3fGo0eb+FCbOOIozEI5jkJZA01ld1DBxhgI0+19LvqKfLJTpaoeep20h+WdzyGI7YVVze rDmnaAvehJ3Ft7qLJqW3ArXwExBNWy0mjRi3zXquDaJKBxrSHkR63PtToLQgAQ== 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 4VB2bJ4P86z15Hr; Fri, 5 Apr 2024 15:34:20 +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 435FYKWZ011472; Fri, 5 Apr 2024 15:34:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 435FYKF3011469; Fri, 5 Apr 2024 15:34:20 GMT (envelope-from git) Date: Fri, 5 Apr 2024 15:34:20 GMT Message-Id: <202404051534.435FYKF3011469@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: aaaa01c0c858 - main - tcp hpts: initialize variable 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: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@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/main X-Git-Reftype: branch X-Git-Commit: aaaa01c0c858fd703194c6cbd515dd514574381f Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=aaaa01c0c858fd703194c6cbd515dd514574381f commit aaaa01c0c858fd703194c6cbd515dd514574381f Author: Michael Tuexen AuthorDate: 2024-04-05 15:30:31 +0000 Commit: Michael Tuexen CommitDate: 2024-04-05 15:30:31 +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 MFC after: 3 days Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44584 --- 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 1e6578429acd..85341cab0750 100644 --- a/sys/netinet/tcp_hpts.c +++ b/sys/netinet/tcp_hpts.c @@ -1651,6 +1651,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) { @@ -1675,7 +1676,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;