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=-4.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS autolearn=ham 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 A2463C43381 for ; Thu, 7 Mar 2019 10:06:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6A1BE20835 for ; Thu, 7 Mar 2019 10:06:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726285AbfCGKGw (ORCPT ); Thu, 7 Mar 2019 05:06:52 -0500 Received: from www62.your-server.de ([213.133.104.62]:44616 "EHLO www62.your-server.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726015AbfCGKGw (ORCPT ); Thu, 7 Mar 2019 05:06:52 -0500 Received: from [78.46.172.3] (helo=sslproxy06.your-server.de) by www62.your-server.de with esmtpsa (TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89_1) (envelope-from ) id 1h1pvN-0000iy-0K; Thu, 07 Mar 2019 11:06:50 +0100 Received: from [178.197.249.29] (helo=linux.home) by sslproxy06.your-server.de with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) (envelope-from ) id 1h1pvM-000GH3-On; Thu, 07 Mar 2019 11:06:48 +0100 Subject: Re: [PATCH bpf] bpf: only test gso type on gso packets To: Willem de Bruijn , netdev@vger.kernel.org Cc: ast@kernel.org, Willem de Bruijn References: <20190306193515.125072-1-willemdebruijn.kernel@gmail.com> From: Daniel Borkmann Message-ID: Date: Thu, 7 Mar 2019 11:06:48 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <20190306193515.125072-1-willemdebruijn.kernel@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Authenticated-Sender: daniel@iogearbox.net X-Virus-Scanned: Clear (ClamAV 0.100.2/25380/Wed Mar 6 10:23:41 2019) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On 03/06/2019 08:35 PM, Willem de Bruijn wrote: > From: Willem de Bruijn > > BPF can adjust gso only for tcp bytestreams. Fail on other gso types. > > But only on gso packets. It does not touch this field if !gso_size. > > Fixes: b90efd225874 ("bpf: only adjust gso_size on bytestream protocols") > Signed-off-by: Willem de Bruijn Good catch, applied, thanks! > Stupid bug on my part. Found only when adding tests for the feature. > Will try to upstream those once bpf-next opens. > > On a related note, also working on a flag BPF_F_ADJ_ROOM_FIXED_GSO > that will allow reenabling this field for UDP (and possibly avoiding > the expensive skb_cow for the TCP common case). Nice, looking forward!