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.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 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 15841C49EA7 for ; Thu, 24 Jun 2021 14:05:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id F3BDC613EC for ; Thu, 24 Jun 2021 14:05:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231618AbhFXOIB (ORCPT ); Thu, 24 Jun 2021 10:08:01 -0400 Received: from www62.your-server.de ([213.133.104.62]:57574 "EHLO www62.your-server.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229878AbhFXOH7 (ORCPT ); Thu, 24 Jun 2021 10:07:59 -0400 Received: from sslproxy05.your-server.de ([78.46.172.2]) by www62.your-server.de with esmtpsa (TLSv1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.92.3) (envelope-from ) id 1lwPz6-0006Zz-65; Thu, 24 Jun 2021 16:05:36 +0200 Received: from [85.7.101.30] (helo=linux-3.home) by sslproxy05.your-server.de with esmtpsa (TLSv1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lwPz5-000JT6-UK; Thu, 24 Jun 2021 16:05:35 +0200 Subject: Re: [PATCH bpf-next v2 4/4] bpf: more lenient bpf_skb_net_shrink() with BPF_F_ADJ_ROOM_FIXED_GSO To: =?UTF-8?Q?Maciej_=c5=bbenczykowski?= , =?UTF-8?Q?Maciej_=c5=bbenczykowski?= , Alexei Starovoitov Cc: Linux Network Development Mailing List , Linux Kernel Mailing List , BPF Mailing List , "David S . Miller" , Willem de Bruijn References: <20210617000953.2787453-1-zenczykowski@gmail.com> <20210617000953.2787453-4-zenczykowski@gmail.com> From: Daniel Borkmann Message-ID: <919e8f26-4b82-9d4c-8973-b2ab2b4bc5bf@iogearbox.net> Date: Thu, 24 Jun 2021 16:05:35 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <20210617000953.2787453-4-zenczykowski@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Authenticated-Sender: daniel@iogearbox.net X-Virus-Scanned: Clear (ClamAV 0.103.2/26211/Thu Jun 24 13:04:24 2021) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/17/21 2:09 AM, Maciej Żenczykowski wrote: > From: Maciej Żenczykowski > > This is to more closely match behaviour of bpf_skb_change_proto() > which now does not adjust gso_size, and thus thoretically supports > all gso types, and does not need to set SKB_GSO_DODGY nor reset > gso_segs to zero. > > Something similar should probably be done with bpf_skb_net_grow(), > but that code scares me. Took in all except this one, would be good to have a complete solution for both bpf_skb_net_{shrink,grow}(). If you don't have the cycles, I'll look into it. Thanks, Daniel