netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris Wright <chrisw@redhat.com>
To: Anirban Chakraborty <anirban.chakraborty@qlogic.com>
Cc: Chris Wright <chrisw@redhat.com>,
	Scott Feldman <scofeldm@cisco.com>,
	David Miller <davem@davemloft.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	Arnd Bergmann <arnd@arndb.de>,
	Ameen Rahman <ameen.rahman@qlogic.com>,
	Amit Salecha <amit.salecha@qlogic.com>,
	Rajesh Borundia <rajesh.borundia@qlogic.com>,
	shemminger@vyatta.com
Subject: Re: eSwitch management
Date: Fri, 23 Apr 2010 12:44:55 -0700	[thread overview]
Message-ID: <20100423194455.GA3843@x200.localdomain> (raw)
In-Reply-To: <8A4C54B1-B5E5-461D-9699-38526B9CEBF4@qlogic.com>

* Anirban Chakraborty (anirban.chakraborty@qlogic.com) wrote:
> On Apr 23, 2010, at 9:23 AM, Chris Wright wrote:
> > * Anirban Chakraborty (anirban.chakraborty@qlogic.com) wrote:
> >> It looks like ifla_vf_info does contain most of the data set. But if I use it, what NETLINK protocol family should I use in my driver to receive netlink messages? Do I need to create a private protocol family?
> > 
> > No, you don't need to use netlink in your driver.  You just need to fill
> > in the relevant net_device_ops in your driver init.  Specifically:
> > 
> > *      SR-IOV management functions.
> > * int (*ndo_set_vf_mac)(struct net_device *dev, int vf, u8* mac);
> > * int (*ndo_set_vf_vlan)(struct net_device *dev, int vf, u16 vlan, u8 qos);
> > * int (*ndo_set_vf_tx_rate)(struct net_device *dev, int vf, int rate);
> > * int (*ndo_get_vf_config)(struct net_device *dev,
> > *                          int vf, struct ifla_vf_info *ivf);
> > 
> > These are all operating on a VF indexed internally w/in the driver, so it's
> > a little cumbersome to use from userspace.
> 
> These are all intended for VFs and are configureable from PF.

Yes, and while the set of callbacks can change, they are always tied to
some net_device (typically the PF) that knows how to make hardware
settings on behalf of a VF.

> However, in our case, there are multiple physical NIC function on a
> port which are configureable by the eswitch.

Is there a PCI function that represents the switch?  Or a special PCI
NIC function that has VEB mgmt plane access?  And do you have examples
of configuration that you'll do here?

> So, what we are setting
> is essentially switch ports, rather than configuring any setting on the
> physical functions. If netlink doesn't fly, is sysfs going to work?

Before we go to implementation specifics (i.e. netlink vs. sysfs, and my
guess is sysfs isn't going to be the right fit), let's step back and
look at what needs setting.

> If
> we allocate a buffer and fill it up with user space tools that the driver
> grabs it and does the configuration itself?

One idea that has been discussed in the past is to create essentially
a pluggable set of bridge_ops.  The first step would be purely internal
shuffling, to make the existing sw bridge code go through the bridge_ops.
The second step would be making your driver for whichever PCI function
you have that supports managing the bridge create a net_device which is
a bridge during driver init.  And now normal brctl can call into your
VEB via the bridge_ops callbacks. </handwave>

But this too starts w/ looking at what the management requirements are
for your bridge.  Can you enumerate those?

thanks,
-chris

  reply	other threads:[~2010-04-23 19:45 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-19 19:18 [net-next PATCH 0/2] iovnl netlink ops + enic dynamic vnics Scott Feldman
2010-04-19 19:18 ` [net-next PATCH 1/2] add iovnl netlink support Scott Feldman
2010-04-20 13:48   ` [net-next,1/2] " Arnd Bergmann
2010-04-20 14:34     ` Chris Wright
2010-04-20 14:57       ` Arnd Bergmann
2010-04-20 15:22         ` Chris Wright
2010-04-20 16:19           ` Arnd Bergmann
2010-04-20 20:26             ` Scott Feldman
2010-04-21 13:17               ` Arnd Bergmann
2010-04-21 16:28                 ` Scott Feldman
2010-04-21 18:04                   ` Arnd Bergmann
2010-04-20 19:56     ` Scott Feldman
2010-04-21 11:26       ` Arnd Bergmann
2010-04-21 11:42         ` Selective MD5 Checksum Failuers Bijay Singh
2010-04-21 16:18         ` [net-next,1/2] add iovnl netlink support Chris Wright
2010-04-21 17:52           ` Arnd Bergmann
2010-04-21 18:10             ` Chris Wright
2010-04-21 19:39               ` Arnd Bergmann
2010-04-21 20:25                 ` Scott Feldman
2010-04-21 21:13                   ` Arnd Bergmann
2010-04-21 22:48                     ` Chris Wright
2010-04-22  6:51                       ` Arnd Bergmann
2010-04-22 17:47                         ` Chris Wright
2010-04-22 18:48                           ` Arnd Bergmann
2010-04-22 19:02                             ` Chris Wright
2010-04-22 19:36                               ` Arnd Bergmann
2010-04-22 21:03                                 ` Chris Wright
2010-04-21 23:54                     ` Scott Feldman
2010-04-22 12:49                       ` Arnd Bergmann
2010-04-22  7:09                     ` David Miller
2010-04-21 22:18                 ` Chris Wright
2010-04-22  0:01                   ` Scott Feldman
2010-04-21 21:22     ` Arnd Bergmann
2010-04-22  6:48   ` [net-next PATCH 1/2] " David Miller
2010-04-22 21:23     ` Scott Feldman
2010-04-22 23:04       ` David Miller
2010-04-22 23:16       ` eSwitch management Anirban Chakraborty
2010-04-23  0:47         ` Scott Feldman
2010-04-23  1:29           ` Scott Feldman
2010-04-23  5:57             ` Anirban Chakraborty
2010-04-23 12:42               ` Arnd Bergmann
2010-04-23 16:23               ` Chris Wright
2010-04-23 19:00                 ` Anirban Chakraborty
2010-04-23 19:44                   ` Chris Wright [this message]
2010-04-23 21:08                     ` Anirban Chakraborty
2010-04-23 23:04                       ` Chris Wright
2010-04-24  6:21                         ` Anirban Chakraborty
2010-04-22  6:52   ` [net-next PATCH 1/2] add iovnl netlink support David Miller
2010-04-22 10:53     ` Arnd Bergmann
2010-04-22 10:56       ` David Miller
2010-04-22 11:12         ` Arnd Bergmann
2010-04-19 19:18 ` [net-next PATCH 2/2] add enic iovnl ops for dynamic vnics Scott Feldman
2010-04-19 21:35 ` [net-next PATCH 0/2] iovnl netlink ops + enic " Chris Wright

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=20100423194455.GA3843@x200.localdomain \
    --to=chrisw@redhat.com \
    --cc=ameen.rahman@qlogic.com \
    --cc=amit.salecha@qlogic.com \
    --cc=anirban.chakraborty@qlogic.com \
    --cc=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=rajesh.borundia@qlogic.com \
    --cc=scofeldm@cisco.com \
    --cc=shemminger@vyatta.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).