Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp8061650imu; Tue, 4 Dec 2018 02:11:38 -0800 (PST) X-Google-Smtp-Source: AFSGD/VbjWd79EArfbHA0ayH2k1ZhSbEhUtCRWh4eBrrmejnjoEC8fkaNfm4KIAw/pbZY3bsmfFv X-Received: by 2002:a17:902:bd0a:: with SMTP id p10mr18852898pls.322.1543918298414; Tue, 04 Dec 2018 02:11:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543918298; cv=none; d=google.com; s=arc-20160816; b=hR0psSXwwXgnYVXDIBpfMZgsVyuOM/jUvrEmr9XQyjg5DSO4/JGApMlfZz2zLc0qDV athpQLLePXI1QItfgPdkalS8gxEJWjwt8fA7yTihWB8uzNvHvQvRiKmPRlpSSVChXpwZ QX8rDmaeXqb1A0Pc2/d1Io4IebjOHh5F97Kw1V2wUHtBMm7s5G3Eo/jaClmmEsMgpkdF 03fWZMa2wgczEi8xAVr+d20XaVNkrZZ1KQtp1Ej95fiQRwAU+BpPNJouzq+FhJqTzUE+ jal4eqMsW6hbMzkeUWQlAEtTEvmdgLM+IBm5HLaIbcIIJ0yVCcO0W1wJEwhu92gqvown GXhg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from; bh=sTnwmp6Yw5vbLTIJ93B7Yu3C6KPOtGI50CcfH+L4vMc=; b=R+sJqtJAAAEsPjepDwcPrnV30IYNCYSBg1qR5x+DxDrt2vyitIHKxq4dMAG1c81k1y 6iZS0WU4Ya8gbqX/0fP69lkchmxTq+fO/lMbMAeVsjhnsBKOc3fxv4kIxBfyeTJ7suQj RTgWNL+GNj6SYw2Szg7ueOnLeyBzYumX4wc6vqmpfSqHzakvAkYOjA2BuR0VFxtGyM3j feboLwkVz1gySYNTAtLqBSHdHKuwZcvjaaihIMpIE17RLFeDwO74HJ7mOu99t+SUAMM/ jrtfMxtjrKv+wYvElSgZ35FPsWMlA7kjxZb2we/Uwv2L6rXKdb51ohEzzBDQPfEeWTQr LxgA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e125si17715948pfe.14.2018.12.04.02.11.23; Tue, 04 Dec 2018 02:11:38 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726081AbeLDKKo convert rfc822-to-8bit (ORCPT + 99 others); Tue, 4 Dec 2018 05:10:44 -0500 Received: from lhrrgout.huawei.com ([185.176.76.210]:32798 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725764AbeLDKKo (ORCPT ); Tue, 4 Dec 2018 05:10:44 -0500 Received: from lhreml702-cah.china.huawei.com (unknown [172.18.7.107]) by Forcepoint Email with ESMTP id 6D3AD5BDFCD35; Tue, 4 Dec 2018 10:10:40 +0000 (GMT) Received: from FRAEML701-CAH.china.huawei.com (10.206.14.32) by lhreml702-cah.china.huawei.com (10.201.108.43) with Microsoft SMTP Server (TLS) id 14.3.408.0; Tue, 4 Dec 2018 10:10:41 +0000 Received: from FRAEML521-MBX.china.huawei.com ([169.254.1.167]) by FRAEML701-CAH.china.huawei.com ([10.206.14.32]) with mapi id 14.03.0415.000; Tue, 4 Dec 2018 11:10:33 +0100 From: Salil Mehta To: David Miller , "jakub.kicinski@netronome.com" CC: "Zhuangyuzeng (Yisen)" , "lipeng (Y)" , "mehta.salil@opnsrc.net" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Linuxarm , Liuzhongzhu , "jiri@resnulli.us" , "f.fainelli@gmail.com" Subject: RE: [RFC net-next 3/9] net: hns3: Add "port vlan table" information query function Thread-Topic: [RFC net-next 3/9] net: hns3: Add "port vlan table" information query function Thread-Index: AQHUipRWcc4RvlD+b0Kh0MVNnjjtYqVtlV4AgAAAJYCAALCJsA== Date: Tue, 4 Dec 2018 10:10:32 +0000 Message-ID: References: <20181202230933.15560-1-salil.mehta@huawei.com> <20181202230933.15560-4-salil.mehta@huawei.com> <20181203151222.6e56efcd@cakuba.netronome.com> <20181203.151253.1348214769326219632.davem@davemloft.net> In-Reply-To: <20181203.151253.1348214769326219632.davem@davemloft.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.202.226.54] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > From: David Miller [mailto:davem@davemloft.net] > Sent: Monday, December 3, 2018 11:13 PM > To: jakub.kicinski@netronome.com > Cc: Salil Mehta ; Zhuangyuzeng (Yisen) > ; lipeng (Y) ; > mehta.salil@opnsrc.net; netdev@vger.kernel.org; linux- > kernel@vger.kernel.org; Linuxarm ; Liuzhongzhu > ; jiri@resnulli.us; f.fainelli@gmail.com > Subject: Re: [RFC net-next 3/9] net: hns3: Add "port vlan table" > information query function > > From: Jakub Kicinski > Date: Mon, 3 Dec 2018 15:12:22 -0800 > > > On Sun, 2 Dec 2018 23:09:27 +0000, Salil Mehta wrote: > >> From: liuzhongzhu > >> > >> This patch prints port vlan table information. > >> > >> debugfs command: > >> echo dump port vlan tbl > cmd > >> > >> Sample Command: > >> root@(none)# echo dump port vlan tbl > cmd > >> vlan | port filter bitMap: > >> 0000 | 00000000:00000000:00000000:00000000:00000000:00000001 > >> root@(none)# > >> > >> Signed-off-by: liuzhongzhu > >> Signed-off-by: Salil Mehta > > > > Adding debugfs files for basic switch concepts like MAC and VLAN tables > > seems like a bit of a stretch to me. I wonder what others think. > > Agreed. I was wondering how other vendors are solving this? One way I could understand is to use "Switchdev" framework which in turn will expose entries to the kernel using the switch driver. In our NIC we don't have a proper switch and it cannot learn/age entries. Also, on-SoC NIC contains other tables which might not have any standard user-space interface at all. What are your suggestions regarding that? Thanks Salil