Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp5227345pxb; Wed, 26 Jan 2022 07:28:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJyTewIB8kqKamYLfsK8yQ1M7tKbc7rHHSDoS2iIwdZYt4m+W1f0uImc/RPMlIcn7HE7ilbG X-Received: by 2002:a17:907:9801:: with SMTP id ji1mr5738052ejc.209.1643210911145; Wed, 26 Jan 2022 07:28:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643210911; cv=none; d=google.com; s=arc-20160816; b=hqAI/pR2gFygOxzE4gxhdq13fSICiAVGqorfRoa9vJcViUGuAv7/iqh/z2c5Paf8Rx kNKNPfBr2o1IdkjR1rvaheKMIu6tfQtcc02BCOH0X7QsqxqCZLetlqnXtQ2fSGU/Kxs7 nUyQLwuu8iFwhvnAsl9VpOEKWMdMIO8i+YlghMNxawzDmom7TEqZmhA+9NgIkkkmpOjd Lb2mIVoVt+ufpQE6TaTY/STpdYyEmDUr0QZvm3Iy9iNqx4P1CZPqH9+V0ZpDDEXO92tQ d9L6X/Sor404/0nH+xTVW3KFIIYVFNPMG7hVr299cNwNSNkfSlmxLfdZ49Xc4jyZ2jOx GRQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=ETAmtGjVjXzQlXzPSOU5L8ahySqQBrjE9OJtM2gVQSg=; b=0bZhb0xFzeuHPsLwRQMKUQ3MtS0w22jOgP9MVkrt7UOce96hY9JxJQEfgEOMZQEOEM r9FSiD6ebZkpT71zfiDFfUsvxFDMSbMYlhzm2PfztCKUWR3MgyaunDff/hpD6EDxk3LM pwejdRiA2ws9m1NcSDE6Bgz6DnApMUMAQricsgY9s+8QzF8ncidCxx2FYGsm4ueCzlqB +4Ac2y6CvBAOdwpzz5aPjj4FW4XxwbGmkNoylQFMoQw3i4qYbQ238kZ+HFXCBixhD51J Q8XndorIWXfyLtIS5CuXKGphVU9Ew9KzgEZgswaHZ/vVxpCFQqbImDyrrIjoz/w6bFyf T9wA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=faFyR8Oa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o13si12504059edi.520.2022.01.26.07.28.04; Wed, 26 Jan 2022 07:28:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=faFyR8Oa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236296AbiAZCZN (ORCPT + 99 others); Tue, 25 Jan 2022 21:25:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60958 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236268AbiAZCZM (ORCPT ); Tue, 25 Jan 2022 21:25:12 -0500 Received: from mail-io1-xd2b.google.com (mail-io1-xd2b.google.com [IPv6:2607:f8b0:4864:20::d2b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 50DF1C06161C; Tue, 25 Jan 2022 18:25:12 -0800 (PST) Received: by mail-io1-xd2b.google.com with SMTP id h7so8093621iof.3; Tue, 25 Jan 2022 18:25:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=ETAmtGjVjXzQlXzPSOU5L8ahySqQBrjE9OJtM2gVQSg=; b=faFyR8OaOnIiyD+3xPNd4uJV2yqG7xlUnr5oC4qtJyX0DBq1G0OSA0kaQHMexbRqUk +ri2oaQN6AdgfJX9Qh6bLlDBvDE6TXkWkA8cgSspSKeT60JpJt+2Vgt+qDIb86yRBa3x ZvOhf1JrnItYR0xxZRsfSetENB1EWBJNgTuCmb499aBUdfl5qAPL5M9tfFZbQPWNEauF FEKfJ8BZ2smtUcVGxyH9QkgRdeYwjk/VHMaMRpzUZ2P9PlhGeslAuZG7Hh4mLAAq25sk TsJlHcIhKBLJNpE/6mgjTHhcNzFSpFYNekF8jc3y6/oTSLNmWsuMr2CVeB9xKoDtUZp5 Y3DA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=ETAmtGjVjXzQlXzPSOU5L8ahySqQBrjE9OJtM2gVQSg=; b=TxRiD/9uTHM0kY4CCVYSG6K5dk8JqmXmU/zmaRLOVDqa8Y03El3foBDmGs1EUp5baT u+oEgCYMPyQANi3NOXraG6GAvnViyrhrNM9KeyKKLB4EaxjQBlWQsevwbqeZ5GDkjpF7 EUpq6aazQIqc0fqgdD0kitbz6zsRjcjdh/yPUK3vrokRQxMlEAQOhCBBTyd5xt9sJuKK +l2Ip2eC/UIyIZ4zfPlI57ofbnjuDHvtmop11Z//9OxERvwvRmgQlJSqBi8VpY+2Q9Nd /EzuixbPtwPLuhzXSDyQTDeOpCNsiL/2R6iPZhlyoN6AxakgO+h4kyKTaspftApFphVC ODag== X-Gm-Message-State: AOAM532OrKp62LjzdwHmb/ptLdof5aj42rp4BLZ6ndGHc0tEIHFTZEqX d0qGizxaszYKMra8Dlcsd3u5U7x+a4o= X-Received: by 2002:a5d:97c3:: with SMTP id k3mr12465595ios.191.1643163911636; Tue, 25 Jan 2022 18:25:11 -0800 (PST) Received: from ?IPV6:2601:282:800:dc80:1502:2fac:6dee:881? ([2601:282:800:dc80:1502:2fac:6dee:881]) by smtp.googlemail.com with ESMTPSA id l12sm9626174ios.32.2022.01.25.18.25.10 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 25 Jan 2022 18:25:11 -0800 (PST) Message-ID: <308b88bf-7874-4b04-47f7-51203fef4128@gmail.com> Date: Tue, 25 Jan 2022 19:25:10 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: [PATCH net-next 5/6] net: udp: use kfree_skb_reason() in udp_queue_rcv_one_skb() Content-Language: en-US To: menglong8.dong@gmail.com, kuba@kernel.org Cc: rostedt@goodmis.org, mingo@redhat.com, davem@davemloft.net, yoshfuji@linux-ipv6.org, dsahern@kernel.org, pablo@netfilter.org, kadlec@netfilter.org, fw@strlen.de, imagedong@tencent.com, edumazet@google.com, alobakin@pm.me, paulb@nvidia.com, pabeni@redhat.com, talalahmad@google.com, haokexin@gmail.com, keescook@chromium.org, memxor@gmail.com, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, netfilter-devel@vger.kernel.org, coreteam@netfilter.org, cong.wang@bytedance.com References: <20220124131538.1453657-1-imagedong@tencent.com> <20220124131538.1453657-6-imagedong@tencent.com> From: David Ahern In-Reply-To: <20220124131538.1453657-6-imagedong@tencent.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/24/22 6:15 AM, menglong8.dong@gmail.com wrote: > diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h > index 603f77ef2170..dd64a4f2ff1d 100644 > --- a/include/linux/skbuff.h > +++ b/include/linux/skbuff.h > @@ -330,6 +330,7 @@ enum skb_drop_reason { > SKB_DROP_REASON_UNICAST_IN_L2_MULTICAST, > SKB_DROP_REASON_XFRM_POLICY, > SKB_DROP_REASON_IP_NOPROTO, > + SKB_DROP_REASON_UDP_FILTER, Is there really a need for a UDP and TCP version? why not just: /* dropped due to bpf filter on socket */ SKB_DROP_REASON_SOCKET_FILTER > SKB_DROP_REASON_MAX, > }; >