From: John Fastabend <john.r.fastabend@intel.com>
To: Lennert Buytenhek <buytenh@wantstofly.org>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>,
Felix Fietkau <nbd@openwrt.org>,
Florian Fainelli <f.fainelli@gmail.com>,
Neil Horman <nhorman@tuxdriver.com>,
netdev <netdev@vger.kernel.org>,
David Miller <davem@davemloft.net>,
Sascha Hauer <s.hauer@pengutronix.de>,
John Crispin <blogic@openwrt.org>,
Jonas Gorski <jogo@openwrt.org>, Gary Thomas <gary@mlbassoc.com>,
Vlad Yasevich <vyasevic@redhat.com>,
Stephen Hemminger <stephen@networkplumber.org>,
Chris Healy <cphealy@gmail.com>
Subject: Re: [PATCH 1/4 net-next] net: phy: add Generic Netlink Ethernet switch configuration API
Date: Wed, 30 Oct 2013 10:56:16 -0700 [thread overview]
Message-ID: <52714840.2030809@intel.com> (raw)
In-Reply-To: <20131030173416.GA32234@wantstofly.org>
On 10/30/2013 10:34 AM, Lennert Buytenhek wrote:
> On Wed, Oct 30, 2013 at 06:27:56PM +0100, Lennert Buytenhek wrote:
>
>>>> This means that all per-port netdevs will be dummy ports which don't
>>>> include the data path.
>>
>> And I think that's fine.
>>
>> Look, even if you're not going to address data traffic to individual
>> ports on your switch chip, there's still a plethora of per-port
>> operations that you want to be able to do: administratively setting
>> the link state on ports up and down, controlling autonegotiation and
>> other PHY settings on individual ports, etc.
>>
>> You can either let the administrator do this with the standard ifconfig
>> / ip link / ethtool tools, or you can make up a parallel API and
>> corresponding set of userland tools to duplicate most of the existing
>> functionality -- I know which option I prefer.
>>
>> Presenting each switch port as an individual Linux netdevice to the OS
>> is an orthogonal decision to actually using those netdevices for data
>> traffic, and conflating the two by arguing that you need special tools
>> to do per-port operations for the sole reason that your switch chip
>> cannot address individual ports is a rather confused argument.
>
> Forgot to add: there's a patch for net/dsa that adds exactly such an
> option. We called it 'unmanaged' mode, and it doesn't enable packet
> tagging on the CPU<->switch chip interface, so that data only ever
> flows over a single network interface ("eth0"), while the other
> ("dummy") network interfaces ("port1", "port2", etc) are used for
> setting link state with ip link, setting PHY settings with ethtool,
> getting ethtool statistics, etc, with 100% unmodified userland tools.
> This patch is currently buried inside a vendor tree, but I'd be happy
> to dig it out and submit it.
>
A "dummy" network interface is something I've been thinking about
for SR-IOV as well. In the SR-IOV case we have an embedded bridge
in the hardware but the virtual functions may be direct assigned
to a guest and not visible to the host.
It would be easier to manage the ports and assign them to different
bridge/QOS objects (OVS, bridge, nftables) if the ports were visible
and manageable in the host even though there is no data path. Today
we special ndo ops that only work for VFs but this is a bit clumsy
and gets more clumsy as the nic switch becomes more like a real switch.
.John
next prev parent reply other threads:[~2013-10-30 17:56 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-22 18:23 [PATCH 0/4 net-next] net: phy: add Generic Netlink switch configuration API Florian Fainelli
2013-10-22 18:23 ` [PATCH 1/4 net-next] net: phy: add Generic Netlink Ethernet " Florian Fainelli
2013-10-22 19:22 ` Dan Williams
2013-10-22 19:32 ` Florian Fainelli
2013-10-22 19:47 ` David Miller
[not found] ` <1382477150.19269.69.camel@dcbw.foobar.com>
2013-10-22 21:22 ` David Miller
2013-10-22 19:46 ` David Miller
2013-10-22 19:53 ` John Fastabend
2013-10-22 19:59 ` Florian Fainelli
2013-10-22 20:25 ` Neil Horman
2013-10-22 22:09 ` Florian Fainelli
2013-10-23 11:34 ` Neil Horman
2013-10-23 11:47 ` Jamal Hadi Salim
2013-10-23 12:04 ` Felix Fietkau
2013-10-23 12:53 ` Jamal Hadi Salim
2013-10-23 13:31 ` Felix Fietkau
2013-10-23 14:09 ` Jamal Hadi Salim
2013-10-23 14:32 ` Felix Fietkau
2013-10-25 11:43 ` Jamal Hadi Salim
2013-10-25 13:01 ` Felix Fietkau
2013-10-27 17:19 ` Jamal Hadi Salim
2013-10-27 18:14 ` Florian Fainelli
2013-10-28 22:29 ` Jamal Hadi Salim
2013-10-27 19:51 ` Felix Fietkau
2013-10-28 22:53 ` Jamal Hadi Salim
2013-10-29 9:34 ` Felix Fietkau
2013-10-30 11:45 ` Jamal Hadi Salim
2013-10-30 12:53 ` Felix Fietkau
2013-10-30 17:27 ` Lennert Buytenhek
2013-10-30 17:34 ` Lennert Buytenhek
2013-10-30 17:56 ` John Fastabend [this message]
2013-10-30 17:56 ` John Fastabend
2013-10-30 19:47 ` Felix Fietkau
2013-12-07 1:45 ` Florian Fainelli
2013-10-29 23:12 ` Maxime Bizon
2013-10-30 11:50 ` Jamal Hadi Salim
2013-10-30 11:58 ` Felix Fietkau
2013-10-30 14:28 ` Maxime Bizon
2013-10-22 18:23 ` [PATCH 2/4 net-next] tools: add Generic Netlink switch configuration tool Florian Fainelli
2013-10-22 18:23 ` [PATCH 3/4 net-next] net: phy: add Broadcom B53 switch driver Florian Fainelli
2013-10-22 18:23 ` [PATCH 4/4 net-next] net: phy: add fake " Florian Fainelli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=52714840.2030809@intel.com \
--to=john.r.fastabend@intel.com \
--cc=blogic@openwrt.org \
--cc=buytenh@wantstofly.org \
--cc=cphealy@gmail.com \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=gary@mlbassoc.com \
--cc=jhs@mojatatu.com \
--cc=jogo@openwrt.org \
--cc=nbd@openwrt.org \
--cc=netdev@vger.kernel.org \
--cc=nhorman@tuxdriver.com \
--cc=s.hauer@pengutronix.de \
--cc=stephen@networkplumber.org \
--cc=vyasevic@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).