From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6A05CC001DB for ; Mon, 7 Aug 2023 13:42:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234302AbjHGNmZ (ORCPT ); Mon, 7 Aug 2023 09:42:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233961AbjHGNmJ (ORCPT ); Mon, 7 Aug 2023 09:42:09 -0400 Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DF2A01738; Mon, 7 Aug 2023 06:41:53 -0700 (PDT) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 917EC5C00D8; Mon, 7 Aug 2023 09:41:12 -0400 (EDT) Received: from imap48 ([10.202.2.98]) by compute4.internal (MEProxy); Mon, 07 Aug 2023 09:41:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=manjusaka.me; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm3; t= 1691415672; x=1691502072; bh=+lJs9GYWBNiOAOVqXWOH5SilIPKlB6jLhY/ Q7PdyL5M=; b=c312f7jQA5+I9qUi7iYMuedJv8L70Agehy5ZgTGHu0Pz7W02Ppn 1Z0zgOZSW2+Bv0x1KO8g+qvpdX1jJY9WG7g8pnbWkBwFEqg+84zoWP6S1dnE7MOS /r5DMQ22koAnK/vCle3StbOWP1xM3F5JzzvnVMv0Jvu4iwB13wo60yRWIiRPYs8s dpF+gV36ExFSygq4CkMunTHg+MxRP+jvBJ3G9mvxbnZYKcq5kVzTIJ4PU2BftWrI rIqavDwtv+cKnHvhLqrb9Olfx19dG+6qv4BLCUYeF3gzezjfCInoecIgUXOPFgmq gKw6f8dhXk8CKVhPpBlgOGitVCq0DA2/GAw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t= 1691415672; x=1691502072; bh=+lJs9GYWBNiOAOVqXWOH5SilIPKlB6jLhY/ Q7PdyL5M=; b=NmN9ldXHdYl8oT9Ay+qbHn3v/Q5TrM9dwmeMiGBHNbuFtqFFVdZ FXsekpSzser2hjjbLWZ/LFfpy6gvCojDVo1zSsWnBWA2S9biWuK2PNGZjIUuHPaQ KSOgleN5/FltuUD9QXOf+3+vgw0/wtK8mW/Muqm5QrAo3DWsiku0TZ4RO00bodPk JO8BV/lilVlQWU+XpztM96iCKIKwwSDwherBuYJg/SNy7U/NlpU5YFmiFjBuAqOt YAu/EGAYSG+RQAIw48t/gpQcCDKqgZivS1eVophmS2qSHNE3Y7sIO1zevL+gB6Ub 7+5imLaLazgqYAv+x+upwHIMgfwCiAz68lQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrledtgdeiudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefofgggkfgjfhffhffvvefutgfgsehtqhertderreejnecuhfhrohhmpeforghn jhhushgrkhgruceomhgvsehmrghnjhhushgrkhgrrdhmvgeqnecuggftrfgrthhtvghrnh epffdvfeejleefjeegfedtieeuleelhffhuedufeevkeeltdelgeetiefgkefhvddvnecu ffhomhgrihhnpegsohhothhlihhnrdgtohhmnecuvehluhhsthgvrhfuihiivgeptdenuc frrghrrghmpehmrghilhhfrhhomhepmhgvsehmrghnjhhushgrkhgrrdhmvg X-ME-Proxy: Feedback-ID: i3ea9498d:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id 4B4B831A0065; Mon, 7 Aug 2023 09:41:12 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.9.0-alpha0-624-g7714e4406d-fm-20230801.001-g7714e440 Mime-Version: 1.0 Message-Id: <9f0abdcc-1cb2-4a4a-8348-4fcbd2be9a53@app.fastmail.com> In-Reply-To: References: <20230806075216.13378-1-me@manjusaka.me> <8d25f9e8-9653-4e9b-b88b-c5434ce8aabf@app.fastmail.com> Date: Mon, 07 Aug 2023 21:40:50 +0800 From: Manjusaka To: "Eric Dumazet" Cc: mhiramat@kernel.org, rostedt@goodmis.org, davem@davemloft.net, dsahern@kernel.org, kuba@kernel.org, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, bpf@vger.kernel.org Subject: Re: [PATCH] [RFC PATCH] tcp event: add new tcp:tcp_cwnd_restart event Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Got you means! LGTM I will make a patch later and make a try On Mon, Aug 7, 2023, at 9:25 PM, Eric Dumazet wrote: > On Mon, Aug 7, 2023 at 2:49=E2=80=AFPM Manjusaka wro= te: > > > > > Do not include code before variable declarations. > > Sorry about that. I will update the code later. > > > > > I would rather add a trace in tcp_ca_event(), this would be more g= eneric ? > > > > https://elixir.bootlin.com/linux/latest/source/net/ipv4/tcp_cong.c#L= 41 > > > > I think maybe we already have the tcp_ca_event but named tcp_cong_st= ate_set? >=20 > I am speaking of tcp_ca_event()... >=20 > For instance, tcp_cwnd_restart() calls tcp_ca_event(sk, CA_EVENT_CWND_= RESTART); >=20 > tcp_set_ca_state() can only set icsk_ca_state to one value from enum > tcp_ca_state: > TCP_CA_Open, TCP_CA_Disorder, TCP_CA_CWR, TCP_CA_Recovery, TCP_CA_Loss >=20 > enum tcp_ca_event has instead: > CA_EVENT_TX_START, CA_EVENT_CWND_RESTART, CA_EVENT_COMPLETE_CWR, > CA_EVENT_LOSS, CA_EVENT_ECN_NO_CE, CA_EVENT_ECN_IS_CE >=20