Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp468154pxb; Thu, 26 Aug 2021 07:15:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/CfgK0nXhmtDiTyImTdBSrH3fbFX66rcmxkNC1RyNefeTLkyPVf7d3H6aTJHqQZJqqRkc X-Received: by 2002:a6b:b883:: with SMTP id i125mr3154468iof.144.1629987314245; Thu, 26 Aug 2021 07:15:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629987314; cv=none; d=google.com; s=arc-20160816; b=ImKzN4tD5j1Pw1D9nQTH4Gn9Jy5zPkaBTzrfW0eRkOarMNj1eJlZUViTwyVB/eURix b0dIv5iPAlHVQAyVfZf0KrbyFbWcQpK71GCWE2JRBMfvH42KRYTjTC+Ru5SkOOMHEHtZ VYcQU/j8Nv5AtcA6IkrAJI7RCg8lvw04z3aCZf5Kj9jmbPOy+JvU8c+utHjFDd+LGOyX pkcivCT/+boSdbwHJ3LU4xVeVWWr27iNdsqE9nEf9MeNgOKclMkdgJusOnCA8OBmSQtI tSeZHFAeqeY0uGPGRojHQ5hk8P0mUago9D2fnggD925dzwym0v6JN4KKRgv+/4xzTYyH aP6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=caYyU5A2AvEDiDoSCaNuh/yyConc6WLj0h0u8wdjUAY=; b=fSp5N0WDOzazOjpQlXaC+OyQcQJwDqW30ulIB7Owgg9kMxOqUXoYSZJQzKPSrf+WJg PfESdAe0I9Wm7KrnDAaWqhCJmplddz+MQCLSfKoe+zuhiWUDsEIonB5oRYpFjycpmx+N tBLQOzN+ydiq8/LoZmnPz9kzLvx4c7tqn9VaC5KsPxRIXO6IwPhUgLMsi46kW/oGfTwN hKc6ExcpnY+WVnqCVYInNBLWr0v8xmRZB1zkftm3P8PwloadytTiJe9ZuB0U9OFIT8qE 1opLFrtS/hR9M5/SAAMCLTA7pelIPfS19C7FQhKDWRWVMCVcKVUbkpM9/Cc/dscTJC0o aGZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=sfdfnRDF; 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 a10si2904629ios.4.2021.08.26.07.14.58; Thu, 26 Aug 2021 07:15:14 -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=sfdfnRDF; 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 S232876AbhHZOOT (ORCPT + 99 others); Thu, 26 Aug 2021 10:14:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56568 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234875AbhHZOOS (ORCPT ); Thu, 26 Aug 2021 10:14:18 -0400 Received: from mail-wr1-x42a.google.com (mail-wr1-x42a.google.com [IPv6:2a00:1450:4864:20::42a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1D4E2C061757; Thu, 26 Aug 2021 07:13:31 -0700 (PDT) Received: by mail-wr1-x42a.google.com with SMTP id i6so5356676wrv.2; Thu, 26 Aug 2021 07:13:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=caYyU5A2AvEDiDoSCaNuh/yyConc6WLj0h0u8wdjUAY=; b=sfdfnRDFmn99FvOvSeIqiZu3TIpbOjIpjTkWDSMeJtlSprqfChCgqmNX+yuucnUgV9 i6zK/gAr7uA4GITCV3DLh9/WVEtp6wrDCq6oQG+jyckvjT3+ADGUV0qEW6rSZr2LH7ph FGlaDC5Org74CkvgU6zGV0GrKV5pU0kKKE4Nk35WC/1I1vkXvJa+KHP/mkCE5tdnjk8p nWogC+riLx3d2o+ePUibWB3xTtU3gnmw5SmwcoSx6tKsS8kovnIp9gIwqtKUDxJvyBn6 eIRGhiqWGZW3pfFeGyBnFHX+oGbYmorV+PEvPfhsTHJMSpKVOntuKb41J5jkxTBfA42B jktw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=caYyU5A2AvEDiDoSCaNuh/yyConc6WLj0h0u8wdjUAY=; b=Xg48BEWCi2txNa1W9ZeF1jUI+xD5Gv7Is60gM87vunzpEAaVJl0GL/HnSA5FdfK4Of ECAL2Ze9Q2+rRQbEfHNh/D1bxp3+jq3Mg8uHJ79g7AQj/s4B9PO+yquTICSym5cYD4Yd 37UgAOROR37WzcqDFXsjhtBnz7JGWAE9M+JsJDDCYNaF8W851FBY5SC0mDaMSo7lvp4H 7c5Cx1TKbdYnDtBVGHOXFuPE0baSELlFiCVKO2FPccXj7AeKilfsiWYidHmOtiS6Lr0I 7LzzlbpCpsA1vvteFK+7MFHWG5ppj3ajfwDMjUoLN/UM8gUQlQ3/WE6HHnwzfUrwLbLy twFA== X-Gm-Message-State: AOAM530UcKfQtTScTTCbPsY6IaEvQzuQJz4Kjy8CCKQnSR1+rGFSS/u4 KZ37v1xu2Osv/rYjoJ9rYgU= X-Received: by 2002:adf:9084:: with SMTP id i4mr4333320wri.23.1629987209616; Thu, 26 Aug 2021 07:13:29 -0700 (PDT) Received: from skbuf ([82.78.148.104]) by smtp.gmail.com with ESMTPSA id b24sm4369821wmj.43.2021.08.26.07.13.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Aug 2021 07:13:28 -0700 (PDT) Date: Thu, 26 Aug 2021 17:13:26 +0300 From: Vladimir Oltean To: DENG Qingfang Cc: Sean Wang , Landen Chao , Andrew Lunn , Vivien Didelot , Florian Fainelli , "David S. Miller" , Jakub Kicinski , Matthias Brugger , netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [RFC net-next 2/2] net: dsa: tag_mtk: handle VLAN tag insertion on TX Message-ID: <20210826141326.xa52776uh3r3jpg4@skbuf> References: <20210825083832.2425886-1-dqfext@gmail.com> <20210825083832.2425886-3-dqfext@gmail.com> <20210826000349.q3s5gjuworxtbcna@skbuf> <20210826052956.3101243-1-dqfext@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210826052956.3101243-1-dqfext@gmail.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 26, 2021 at 01:29:56PM +0800, DENG Qingfang wrote: > On Thu, Aug 26, 2021 at 03:03:49AM +0300, Vladimir Oltean wrote: > > > > You cannot just remove the old code. Only things like 8021q uppers will > > send packets with the VLAN in the hwaccel area. > > > > If you have an application that puts the VLAN in the actual AF_PACKET > > payload, like: > > > > https://github.com/vladimiroltean/tsn-scripts/blob/master/isochron/send.c > > > > then you need to handle the VLAN being in the skb payload. > > I've actually tested this (only apply patch 2 without .features) and it > still worked. > > The comment says the VLAN tag need to be combined with the special tag in > order to perform VLAN table lookup, It does say this. > so we can set its destination port vector to all zeroes and the switch > will forward it like a data frame (TX forward offload), And it does not say this. So this is supported after all with mt7530? Are you looking to add support for that? > but as we allow multiple bridges which are either VLAN-unaware or > VLAN-aware with the same VID, there is no way to determine the > destination bridge unless we maintain some VLAN translation mapping. What does "VLAN translation mapping" mean, practically? Other drivers which cannot remap VIDs to internal VLANs just restrict a single VLAN-aware bridge, and potentially multiple VLAN-unaware ones.