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 X-Spam-Level: X-Spam-Status: No, score=-5.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_2 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 72376C433EF for ; Mon, 20 Sep 2021 18:25:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5CBEE613A2 for ; Mon, 20 Sep 2021 18:25:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1378792AbhITS00 (ORCPT ); Mon, 20 Sep 2021 14:26:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:44380 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1378261AbhITSYT (ORCPT ); Mon, 20 Sep 2021 14:24:19 -0400 Received: from oasis.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 65FE861A85; Mon, 20 Sep 2021 17:24:42 +0000 (UTC) Date: Mon, 20 Sep 2021 13:24:40 -0400 From: Steven Rostedt To: Cong Wang Cc: Zhongya Yan , Eric Dumazet , Brendan Gregg , Linux Kernel Network Developers , LKML , Jakub Kicinski , Ingo Molnar , David Miller , Hideaki YOSHIFUJI , David Ahern , Yonghong Song , Zhongya Yan <2228598786@qq.com> Subject: Re: [PATCH] tcp: tcp_drop adds `SNMP` and `reason` parameter for tracing Message-ID: <20210920132440.7a2febce@oasis.local.home> In-Reply-To: References: <20210914143515.106394-1-yan2228598786@gmail.com> <20210920131550.658eda95@oasis.local.home> X-Mailer: Claws Mail 3.18.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Mon, 20 Sep 2021 10:20:33 -0700 Cong Wang wrote: > > The strings were requested by the networking maintainers. > > > > https://lore.kernel.org/all/CANn89iJO8jzjFWvJ610TPmKDE8WKi8ojTr_HWXLz5g=4pdQHEA@mail.gmail.com/ > > I think you misunderstand my point. Eric's point is hex address > vs. string, which I never disagree. With SNMP enum, user-space > can easily interpret it to string too, so at the end you still get strings > but not from kernel. This would at least save a handful of strings > from vmlinux, especially if we expand it beyond TCP. If an enum is saved in the ring buffer, it is also trivial to have it show a string in the buffer, as there's a way to map enums to strings on output as well. Which I discussed in that same thread. -- Steve