From nobody Fri Nov 22 22:41:10 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=linux.microsoft.com ARC-Seal: i=1; a=rsa-sha256; t=1731705808; cv=none; d=zohomail.com; s=zohoarc; b=BUf5s17nSU41nOUuLGCELxOJuvNMzoR0+mO9ixo6MnVAQ1RkphO/V4zGOV8vE0TgrFjCFjz7saYC2eBkQz+cUuPsNOsTuvGzNniYok1r8WWpy+N2lu0Sow+hebU62Mqdwo1f1VdDFGgk+shVaNHQKVQ2jHbdd2OtLCInl5uYpEU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1731705808; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Q64Lap8gGilYnZS8wBYuXVtg6CkDWFgIDR5hpRb/qKY=; b=GXAoFsTdS5oyj8XjyW9DKUELVgpSfjUFTBNlpS1EI5vQQIafgGZl0hCnu3GBqXkmGKr/GL9zRtiBIrnxJBaq1YKXcpAh9apaRret5dh7hsx+e1ikznJ7R5VYQ8xEPHGVWotoyyOH/vTwmCc1zb9P2An6TukkiFlzkbQRgeuUrrM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1731705808221914.7301551310579; Fri, 15 Nov 2024 13:23:28 -0800 (PST) Received: from list by lists.xenproject.org with outflank-mailman.838011.1253945 (Exim 4.92) (envelope-from ) id 1tC3mD-0007G6-FX; Fri, 15 Nov 2024 21:22:49 +0000 Received: by outflank-mailman (output) from mailman id 838011.1253945; Fri, 15 Nov 2024 21:22:49 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1tC3mD-0007Fe-9Y; Fri, 15 Nov 2024 21:22:49 +0000 Received: by outflank-mailman (input) for mailman id 838011; Fri, 15 Nov 2024 21:22:48 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1tC3mB-0007DI-Uc for xen-devel@lists.xenproject.org; Fri, 15 Nov 2024 21:22:47 +0000 Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by se1-gles-sth1.inumbo.com (Halon) with ESMTP id c0564bf1-a397-11ef-a0c7-8be0dac302b0; Fri, 15 Nov 2024 22:22:43 +0100 (CET) Received: from eahariha-devbox.internal.cloudapp.net (unknown [40.91.112.99]) by linux.microsoft.com (Postfix) with ESMTPSA id 1682D206BCE4; Fri, 15 Nov 2024 13:22:42 -0800 (PST) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: c0564bf1-a397-11ef-a0c7-8be0dac302b0 X-Custom-Connection: eyJyZW1vdGVpcCI6IjEzLjc3LjE1NC4xODIiLCJoZWxvIjoibGludXgubWljcm9zb2Z0LmNvbSJ9 X-Custom-Transaction: eyJpZCI6ImMwNTY0YmYxLWEzOTctMTFlZi1hMGM3LThiZTBkYWMzMDJiMCIsInRzIjoxNzMxNzA1NzY0LjIwNzQwOSwic2VuZGVyIjoiZWFoYXJpaGFAbGludXgubWljcm9zb2Z0LmNvbSIsInJlY2lwaWVudCI6Inhlbi1kZXZlbEBsaXN0cy54ZW5wcm9qZWN0Lm9yZyJ9 DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 1682D206BCE4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1731705762; bh=Q64Lap8gGilYnZS8wBYuXVtg6CkDWFgIDR5hpRb/qKY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=TpPSBC6Q0pyCMIPKcOfsvZX/wWIHu4+ejmKY8xw+0GecDvIAUfgwshz01AoOkZ0WD k4gHIei/egZSo7W0NlMAlHYHatQ5bzRsbZtX1NOQvIcE9aFKMDcUHtqmglM484AIGB /3Fdhfw7EN1qT/zCvUp8095p9P9VmicZ+TZgDM0I= From: Easwar Hariharan Date: Fri, 15 Nov 2024 21:22:31 +0000 Subject: [PATCH 01/22] netfilter: conntrack: Cleanup timeout definitions MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241115-converge-secs-to-jiffies-v1-1-19aadc34941b@linux.microsoft.com> References: <20241115-converge-secs-to-jiffies-v1-0-19aadc34941b@linux.microsoft.com> In-Reply-To: <20241115-converge-secs-to-jiffies-v1-0-19aadc34941b@linux.microsoft.com> To: Pablo Neira Ayuso , Jozsef Kadlecsik , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman , Julia Lawall , Nicolas Palix , Daniel Mack , Haojian Zhuang , Robert Jarzmik , Russell King , Heiko Carstens , Vasily Gorbik , Alexander Gordeev , Christian Borntraeger , Sven Schnelle , Ofir Bitton , Oded Gabbay , Lucas De Marchi , =?utf-8?q?Thomas_Hellstr=C3=B6m?= , Rodrigo Vivi , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Jeroen de Borst , Praveen Kaligineedi , Shailend Chand , Andrew Lunn , James Smart , Dick Kennedy , "James E.J. Bottomley" , "Martin K. Petersen" , =?utf-8?q?Roger_Pau_Monn=C3=A9?= , Jens Axboe , Kalle Valo , Jeff Johnson , Catalin Marinas , Andrew Morton , Jack Wang , Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Greg Kroah-Hartman , Florian Fainelli , Ray Jui , Scott Branden , Broadcom internal kernel review list , Xiubo Li , Ilya Dryomov , Josh Poimboeuf , Jiri Kosina , Miroslav Benes , Petr Mladek , Joe Lawrence , Jaroslav Kysela , Takashi Iwai , Lucas Stach , Russell King , Christian Gmeiner , Louis Peens , Michael Ellerman , Nicholas Piggin , Christophe Leroy , Naveen N Rao , Madhavan Srinivasan Cc: netfilter-devel@vger.kernel.org, coreteam@netfilter.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, cocci@inria.fr, linux-arm-kernel@lists.infradead.org, linux-s390@vger.kernel.org, dri-devel@lists.freedesktop.org, intel-xe@lists.freedesktop.org, linux-scsi@vger.kernel.org, xen-devel@lists.xenproject.org, linux-block@vger.kernel.org, linux-wireless@vger.kernel.org, ath11k@lists.infradead.org, linux-mm@kvack.org, linux-bluetooth@vger.kernel.org, linux-staging@lists.linux.dev, linux-rpi-kernel@lists.infradead.org, ceph-devel@vger.kernel.org, live-patching@vger.kernel.org, linux-sound@vger.kernel.org, etnaviv@lists.freedesktop.org, oss-drivers@corigine.com, linuxppc-dev@lists.ozlabs.org, Anna-Maria Behnsen , Easwar Hariharan X-Mailer: b4 0.14.2 X-ZohoMail-DKIM: pass (identity @linux.microsoft.com) X-ZM-MESSAGEID: 1731705809913116600 None of the higher order definitions are used anymore, so remove definitions for minutes, hours, and days timeouts. Convert the seconds denominated timeouts to secs_to_jiffies() Signed-off-by: Easwar Hariharan --- net/netfilter/nf_conntrack_proto_sctp.c | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/net/netfilter/nf_conntrack_proto_sctp.c b/net/netfilter/nf_con= ntrack_proto_sctp.c index 4cc97f971264ed779434ab4597dd0162586b3736..6c95ac96fa42a39acafb5b88a7c= f8898010e911c 100644 --- a/net/netfilter/nf_conntrack_proto_sctp.c +++ b/net/netfilter/nf_conntrack_proto_sctp.c @@ -39,20 +39,15 @@ static const char *const sctp_conntrack_names[] =3D { [SCTP_CONNTRACK_HEARTBEAT_SENT] =3D "HEARTBEAT_SENT", }; =20 -#define SECS * HZ -#define MINS * 60 SECS -#define HOURS * 60 MINS -#define DAYS * 24 HOURS - static const unsigned int sctp_timeouts[SCTP_CONNTRACK_MAX] =3D { - [SCTP_CONNTRACK_CLOSED] =3D 10 SECS, - [SCTP_CONNTRACK_COOKIE_WAIT] =3D 3 SECS, - [SCTP_CONNTRACK_COOKIE_ECHOED] =3D 3 SECS, - [SCTP_CONNTRACK_ESTABLISHED] =3D 210 SECS, - [SCTP_CONNTRACK_SHUTDOWN_SENT] =3D 3 SECS, - [SCTP_CONNTRACK_SHUTDOWN_RECD] =3D 3 SECS, - [SCTP_CONNTRACK_SHUTDOWN_ACK_SENT] =3D 3 SECS, - [SCTP_CONNTRACK_HEARTBEAT_SENT] =3D 30 SECS, + [SCTP_CONNTRACK_CLOSED] =3D secs_to_jiffies(10), + [SCTP_CONNTRACK_COOKIE_WAIT] =3D secs_to_jiffies(3), + [SCTP_CONNTRACK_COOKIE_ECHOED] =3D secs_to_jiffies(3), + [SCTP_CONNTRACK_ESTABLISHED] =3D secs_to_jiffies(210), + [SCTP_CONNTRACK_SHUTDOWN_SENT] =3D secs_to_jiffies(3), + [SCTP_CONNTRACK_SHUTDOWN_RECD] =3D secs_to_jiffies(3), + [SCTP_CONNTRACK_SHUTDOWN_ACK_SENT] =3D secs_to_jiffies(3), + [SCTP_CONNTRACK_HEARTBEAT_SENT] =3D secs_to_jiffies(3), }; =20 #define SCTP_FLAG_HEARTBEAT_VTAG_FAILED 1 --=20 2.34.1