From: Flavio Leitner <fbl@redhat.com>
To: Jiri Pirko <jpirko@redhat.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
eric.dumazet@gmail.com, bhutchings@solarflare.com,
shemminger@vyatta.com, fubar@us.ibm.com, andy@greyhouse.net,
tgraf@infradead.org, ebiederm@xmission.com, mirqus@gmail.com,
kaber@trash.net, greearb@candelatech.com, jesse@nicira.com,
benjamin.poirier@gmail.com, jzupka@redhat.com,
ivecera@redhat.com
Subject: Re: [patch net-next V7] net: introduce ethernet teaming device
Date: Fri, 11 Nov 2011 16:04:41 -0200 [thread overview]
Message-ID: <20111111160441.5ab366cc@asterix.rh> (raw)
In-Reply-To: <1320939698-1062-1-git-send-email-jpirko@redhat.com>
On Thu, 10 Nov 2011 16:41:38 +0100
Jiri Pirko <jpirko@redhat.com> wrote:
> This patch introduces new network device called team. It supposes to be
> very fast, simple, userspace-driven alternative to existing bonding
> driver.
>
> Userspace library called libteam with couple of demo apps is available
> here:
> https://github.com/jpirko/libteam
> Note it's still in its dipers atm.
>
> team<->libteam use generic netlink for communication. That and rtnl
> suppose to be the only way to configure team device, no sysfs etc.
>
> Python binding of libteam was recently introduced.
> Daemon providing arpmon/miimon active-backup functionality will be
> introduced shortly. All what's necessary is already implemented in
> kernel team driver.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
>
> v6->v7:
> - transmit and receive functions are not checked in hot paths.
> That also resolves memory leak on transmit when no port is
> present
>
You're right. No need to patch those function names if we use libnl
from git.
[...]
> +static void team_vlan_rx_add_vid(struct net_device *dev, uint16_t vid)
> +{
> + struct team *team = netdev_priv(dev);
> + struct team_port *port;
> +
> + rcu_read_lock();
> + list_for_each_entry_rcu(port, &team->port_list, list) {
> + const struct net_device_ops *ops = port->dev->netdev_ops;
> +
> + ops->ndo_vlan_rx_add_vid(port->dev, vid);
This causes a oops when enslaving a tg3 device because there is
no ndo_vlan_rx_add_vid().
> + }
> + rcu_read_unlock();
> +}
> +
> +static void team_vlan_rx_kill_vid(struct net_device *dev, uint16_t vid)
> +{
> + struct team *team = netdev_priv(dev);
> + struct team_port *port;
> +
> + rcu_read_lock();
> + list_for_each_entry_rcu(port, &team->port_list, list) {
> + const struct net_device_ops *ops = port->dev->netdev_ops;
> +
> + ops->ndo_vlan_rx_kill_vid(port->dev, vid);
Well, probably here too, though you can't reach this point without
crashing at team_vlan_rx_add_vid() first.
fbl
next prev parent reply other threads:[~2011-11-11 18:54 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-10 15:41 [patch net-next V7] net: introduce ethernet teaming device Jiri Pirko
2011-11-10 16:02 ` Eric Dumazet
2011-11-10 16:59 ` Jiri Pirko
2011-11-11 18:04 ` Flavio Leitner [this message]
2011-11-11 19:05 ` Flavio Leitner
2011-11-11 19:58 ` Flavio Leitner
2011-11-12 0:15 ` Jiri Pirko
2011-11-12 5:45 ` David Miller
2011-11-12 8:18 ` Jiri Pirko
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=20111111160441.5ab366cc@asterix.rh \
--to=fbl@redhat.com \
--cc=andy@greyhouse.net \
--cc=benjamin.poirier@gmail.com \
--cc=bhutchings@solarflare.com \
--cc=davem@davemloft.net \
--cc=ebiederm@xmission.com \
--cc=eric.dumazet@gmail.com \
--cc=fubar@us.ibm.com \
--cc=greearb@candelatech.com \
--cc=ivecera@redhat.com \
--cc=jesse@nicira.com \
--cc=jpirko@redhat.com \
--cc=jzupka@redhat.com \
--cc=kaber@trash.net \
--cc=mirqus@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=shemminger@vyatta.com \
--cc=tgraf@infradead.org \
/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).