Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp175896pxj; Fri, 14 May 2021 00:35:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy0I2VzYClz5gRpDRMgVrh+p6fefU1btNTbrATJNg6n0OcwNZkjPH6XDv0mBbl4qHYJkewH X-Received: by 2002:a05:6402:110b:: with SMTP id u11mr56368635edv.356.1620977716303; Fri, 14 May 2021 00:35:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620977716; cv=none; d=google.com; s=arc-20160816; b=HBvHH3W+bs26EFki421qzJfDAuJzaOh4GkJXxh+wYRB+I95LM5tXLoPVb9jdssNFg9 85HmTycP6pPq0v3kZrkiHV0ODnzggHdAGJvT/fkR/JzudAcrxkXAWxqTi4TdapUcOGE5 xEClKlWgePr/a/PjaYJkA4aohIbTKnE9VJBm9380R9UNxVht+PJjywodIxS3s0YMLzhX GaHN+MupaZfOql3uHLqJnVM7kD9I960LF6a/u/gSIIw08lXC5XqYkSEl8K4HONM6LETh tGJzfdDtdKzuve6JL4vxma5JBdRbfvDDp4Kvw9foUG/+iScpJvMkyP0M1YI+/Jt3tI5O HBFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=4OSP4b7wpVi2J0VIXLzXQpYaouwViNp+zix3X51TtRM=; b=CD7fN+fY9IG8Ajm2z9aZM/HaYFGT0Cv0B+tjSVWM4SsrUYcWxGHlFn5U6dqm5g9rZZ /FJW0ldZDYjfQ78/kdTC/A0H4QnxKPNTBi/FTmrMEkHk0tr3kPssmKolHDxEY68yiEHl yKjuoSIl6F9t9rjgGNa18MiznSzHyEEarQbiYm36Y8D0dDSdHv57Mc6oIvb2FLxm1529 vPOsv95aZ3AW8artp26ZchhXhoz9R3Cryb/HB2L1QOn7fv/GVJ2Rab7LV0wqH8YcjkHX 7THEGEKob981EGMMpQhxEsXbiAwS6JP/MoF+Yc4jNmRm0Xj5gBqZnHtgN9f15WMRwTJa rqCQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=jULfFAQd; 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 w7si5549084edc.498.2021.05.14.00.34.53; Fri, 14 May 2021 00:35:16 -0700 (PDT) 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=20161025 header.b=jULfFAQd; 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 S233074AbhEMUgv (ORCPT + 99 others); Thu, 13 May 2021 16:36:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40668 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233056AbhEMUgu (ORCPT ); Thu, 13 May 2021 16:36:50 -0400 Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1B83AC061574 for ; Thu, 13 May 2021 13:35:40 -0700 (PDT) Received: by mail-ej1-x633.google.com with SMTP id l4so41666859ejc.10 for ; Thu, 13 May 2021 13:35:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=4OSP4b7wpVi2J0VIXLzXQpYaouwViNp+zix3X51TtRM=; b=jULfFAQdup+JfQHyGNJe5gViVXOpfKZCPJbE4aABtwAQlIyYMLruaAymHorBENW7LV 6pvAO2R4lC6uUDYEOkb2xu40DTKaKml5fQajfG2EmM0hS3O2NAa5kfec62L5iXXKfqk8 mqweY9rc4duXqwNVSuQ00GtNYGEYr+fgr50a0i+d39Y7eXE6EO6UN/Kj22auNPrFs0wM srFbcdTcD2IwBZ/hLxi0+ZbitC9kx2/VlUk8HznczXbBSgHNbdP+GYBk/XrDDqgDpbS6 F8hKcswHBIqwzalmTMSBhA24UZj/r8952Si6xy8qs1KARhQWn9VNADNoH33CF1+R40hc eWSw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=4OSP4b7wpVi2J0VIXLzXQpYaouwViNp+zix3X51TtRM=; b=UitiXl+WOyl7GA7xrJg2TQFYWS7AoJiucBxPUFY5XXAlpsP72MPLO/g2Gb7IjLGZEY WL1Vq72u+eR9uwH+EVq8KUdxHfRjz3IDg1fQHDXMCi0ycc+WCZ2rWHD3ixtLHLYWl2yy kprwnUOB1+J7Qix5ExbROTpX5QLFUxHYl0mzsjWjPCTNOaokCc4bBaCRRimC8kh52mw/ GBqjFuvCHz/WFaI/+01JEAEnLvVMiXpbjEtvYEYig24ofA8DsB/tin1USrov6GRlpZxf AqRNtEzK76cTwhFD4eaMSxE3/8cwGFJGJiEslO7kBMgeYPas6N+Rmw0pS0UH3eziVrzr zBqQ== X-Gm-Message-State: AOAM532KmWdOQjS+zOwnVsLSb3LtDkLUB5NpQxb0bizcwzFcyMnRoKWS Om5cEmwllMkRUbCxgtJ3jE1McV6kT6SYLQ== X-Received: by 2002:a17:906:14c1:: with SMTP id y1mr46567490ejc.481.1620938138493; Thu, 13 May 2021 13:35:38 -0700 (PDT) Received: from mail-wm1-f51.google.com (mail-wm1-f51.google.com. [209.85.128.51]) by smtp.gmail.com with ESMTPSA id hz15sm2376001ejc.57.2021.05.13.13.35.35 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 May 2021 13:35:36 -0700 (PDT) Received: by mail-wm1-f51.google.com with SMTP id y124-20020a1c32820000b029010c93864955so401255wmy.5 for ; Thu, 13 May 2021 13:35:35 -0700 (PDT) X-Received: by 2002:a7b:c94b:: with SMTP id i11mr34607045wml.120.1620938135207; Thu, 13 May 2021 13:35:35 -0700 (PDT) MIME-Version: 1.0 References: <20210511044253.469034-1-yuri.benditovich@daynix.com> <20210511044253.469034-5-yuri.benditovich@daynix.com> <89759261-3a72-df6c-7a81-b7a48abfad44@redhat.com> In-Reply-To: From: Willem de Bruijn Date: Thu, 13 May 2021 16:34:57 -0400 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 4/4] tun: indicate support for USO feature To: Jason Wang Cc: Yuri Benditovich , Yan Vugenfirer , davem , Jakub Kicinski , mst , netdev , linux-kernel , virtualization , Willem de Bruijn Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > > But surprisingly when TUN receives TUN_F_UFO it does not propagate it > > anywhere, there is no corresponding NETIF flag. > > (It looks like I drop the community and other ccs accidentally, adding > them back and sorry) > > Actually, there is one, NETIF_F_GSO_UDP. > > Kernel used to have NETIF_F_UFO, but it was removed due to bugs and > the lack of real hardware support. Then we found it breaks uABI, so > Willem tries to make it appear for userspace again, and then it was > renamed to NETIF_F_GSO_UDP. > > But I think it's a bug that we don't proporate TUN_F_UFO to NETIF > flag, this is a must for the driver that doesn't support > VIRTIO_NET_F_GUEST_UFO. I just try to disable all offloads and > mrg_rxbuf, then netperf UDP_STREAM from host to guest gives me bad > length packet in the guest. > > Willem, I think we probably need to fix this. We had to add back support for the kernel to accept UFO packets from userspace over tuntap. The kernel does not generate such packets, so a guest should never be concerned of receiving UFO packets. Perhaps i'm misunderstanding the problem here.