Received: by 2002:a05:7412:6592:b0:d7:7d3a:4fe2 with SMTP id m18csp1816001rdg; Sat, 12 Aug 2023 19:08:20 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHCaXowVJRkebtnvVFnxwakaQrAAu9KMffYUyr/jXBzdADFbK+J/Oetjg5e7fJz9k+hO97n X-Received: by 2002:a05:6a20:2583:b0:137:514a:9835 with SMTP id k3-20020a056a20258300b00137514a9835mr6044405pzd.9.1691892499706; Sat, 12 Aug 2023 19:08:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691892499; cv=none; d=google.com; s=arc-20160816; b=wTT8eEYYUs+o217QxV2/tSa+ypCggYEzH/gxa75agjpnzlzFrmu8JZhhYWOvGukF4P ZWOVx4cD3ImkjmkekQF/k8P8ve/7ngGQboYI2ZsN3OiaqEwzkO1UszulphX+YknOvGy6 Qi2+m6k+2BIs6NsWcE8/S2/Dm4mEaaOSed1hbkvJ1BmUR00SzowWvZpRiEZkaLsyHIjb 3eKVQzjQaGdlQX8+piHi1dQeDRkDTbHoi7ohn00MbU7VWpokd9AsV2laDN/e+2Cg7nsx cQttqBBZHW5aeBoVOmbogX5qLFy+b5zXvQs06U/p+tlHPUM62TomAWs0o0sdaZc0WJx7 kQZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=8icGtGMePWfnxnA2z+eceapafeguWZ3BXP7PfvZR7Vw=; fh=WiZBcA36ET0QK1c4IpFIY6cWlf4VQLkE15ih//5PW8s=; b=I8graFb06lZpvw99w23hPcJYpnbnjVnUzugJGNsjV2K5aPNMHjt5+tR9q4w0kG9lVV Rdtg0VXVVlGo9NGeU2NiG5soBlD7lksagl0/4OU57i0Zwt6k9SaG0v0EcfmlnwtoR6uA ofI8iVpydP62g7+LKRDG+HhB4sXUdit++Vl6QTJtAoK66uVjf55LtsWgTGvYUSNzI3M8 N202fKr8iFn2LLhXf/B8Cp5EwRGQ03/nOHqmmpg3hfxcSthzF5IVTfrGnOWbvAQXxMrv SsktspTh7n82RJqZFoiKxihDwBC+z7+AOqgVfm1vJ3Gl2KOOqB/NLB5AVTe2RTvmv1Wc CTvg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id iz1-20020a170902ef8100b001b8b437b01esi5630631plb.350.2023.08.12.19.08.05; Sat, 12 Aug 2023 19:08:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229885AbjHMBEw (ORCPT + 99 others); Sat, 12 Aug 2023 21:04:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37746 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229475AbjHMBEv (ORCPT ); Sat, 12 Aug 2023 21:04:51 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B4F31706; Sat, 12 Aug 2023 18:04:54 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0392460A5F; Sun, 13 Aug 2023 01:04:54 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A5AFBC433C7; Sun, 13 Aug 2023 01:04:51 +0000 (UTC) Date: Sat, 12 Aug 2023 21:04:50 -0400 From: Steven Rostedt To: Zheao Li Cc: edumazet@google.com, bpf@vger.kernel.org, davem@davemloft.net, dsahern@kernel.org, kuba@kernel.org, linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, mhiramat@kernel.org, ncardwell@google.com, netdev@vger.kernel.org, pabeni@redhat.com, Joe Perches Subject: Re: [PATCH v3] tracepoint: add new `tcp:tcp_ca_event` trace event Message-ID: <20230812210450.53464a78@rorschach.local.home> In-Reply-To: <20230812210140.117da558@rorschach.local.home> References: <20230812201249.62237-1-me@manjusaka.me> <20230812205905.016106c0@rorschach.local.home> <20230812210140.117da558@rorschach.local.home> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 12 Aug 2023 21:01:40 -0400 Steven Rostedt wrote: > On Sat, 12 Aug 2023 20:59:05 -0400 > Steven Rostedt wrote: > > > On Sat, 12 Aug 2023 20:12:50 +0000 > > Zheao Li wrote: > > > > > +TRACE_EVENT(tcp_ca_event, > > > + > > > + TP_PROTO(struct sock *sk, const u8 ca_event), > > > + > > > + TP_ARGS(sk, ca_event), > > > + > > > + TP_STRUCT__entry( > > > + __field(const void *, skaddr) > > > + __field(__u16, sport) > > > + __field(__u16, dport) > > > + __field(__u16, family) > > > + __array(__u8, saddr, 4) > > > + __array(__u8, daddr, 4) > > > + __array(__u8, saddr_v6, 16) > > > + __array(__u8, daddr_v6, 16) > > > + __field(__u8, ca_event) > > > > Please DO NOT LISTEN TO CHECKPATCH! I forgot to say "for TRACE_EVENT() macros". This is not about what checkpatch says about other code. -- Steve > > > > The above looks horrendous! Put it back to: > > > > > + __field( const void *, skaddr ) > > > + __field( __u16, sport ) > > > + __field( __u16, dport ) > > > + __field( __u16, family ) > > > + __array( __u8, saddr, 4 ) > > > + __array( __u8, daddr, 4 ) > > > + __array( __u8, saddr_v6, 16 ) > > > + __array( __u8, daddr_v6, 16 ) > > > + __field( __u8, ca_event ) > > > > See how much better it looks I can see fields this way. > > > > The "checkpatch" way is a condensed mess. > > >