From: Jiri Pirko <jiri@resnulli.us>
To: Scott Feldman <sfeldma@cumulusnetworks.com>
Cc: Veaceslav Falico <vfalico@redhat.com>,
Jay Vosburgh <fubar@us.ibm.com>,
Andy Gospodarek <andy@greyhouse.net>,
Netdev <netdev@vger.kernel.org>,
Roopa Prabhu <roopa@cumulusnetworks.com>,
Shrijeet Mukherjee <shm@cumulusnetworks.com>,
Ding Tianhong <dingtianhong@huawei.com>
Subject: Re: [PATCH net-next v2 2/2] bonding: add netlink attributes to slave link dev
Date: Wed, 22 Jan 2014 09:22:15 +0100 [thread overview]
Message-ID: <20140122082215.GA2814@minipsycho.orion> (raw)
In-Reply-To: <C5AA1F6D-4FC7-42F6-A59F-A0114E1B2E8B@cumulusnetworks.com>
Tue, Jan 21, 2014 at 11:42:58PM CET, sfeldma@cumulusnetworks.com wrote:
>
>On Jan 21, 2014, at 2:00 PM, Jiri Pirko <jiri@resnulli.us> wrote:
>
>> Tue, Jan 21, 2014 at 10:36:58PM CET, sfeldma@cumulusnetworks.com wrote:
>>>
>>> On Jan 21, 2014, at 5:34 AM, Jiri Pirko <jiri@resnulli.us> wrote:
>>>
>>>>> + if (rtnl_bond_slave_fill(skb, dev))
>>>>> + goto nla_put_failure;
>>>>> +
>>>>
>>>> I must say I do not like this at all. This should be done in a generic
>>>> way. By a callback registered by bonding and possibly other master-slave
>>>> device types.
>>>
>>> The bond was registered with the ndo_get_slave op. ndo_get_slave could be used for other master-slave device types. I’ll agree that rtnl_bond_slave_fill() could have been written more generically. Is that the objection?
>>
>> I think is should be done rather in rtnl_link_ops. It's the natural point
>> for this ops. I have patchset prepared. Will send it very soon.
>
>Ok, cool.
>
>Also, right now I have IFLA_SLAVE as a nest for IFLA_SLAVE_xxx attrs. Do you think we should have a two-layer nest so we can capture other master-slave devices rather than just bond slaves? I.e.:
>
> IFLA_SLAVE
> IFLA_BOND_SLAVE
> IFLA_BOND_SLAVE_xxx
> IFLA_BOND_SLAVE_yyy
> IFLA_BOND_SLAVE_zzz
> IFLA_FOO_SLAVE // FOO is some other non-bond master
> IFLA_FOO_SLAVE_xxx
> IFLA_FOO_SLAVE_yyy
> IFLA_FOO_SLAVE_zzz
>
>(Of course, slave wouldn’t be bond and foo slave at same time).
I would rather do this in LINKINFO nest the same way IFLA_BOND_* are
done. Please see following patch:
http://patchwork.ozlabs.org/patch/313156/
>
>-scott
prev parent reply other threads:[~2014-01-22 8:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-17 6:57 [PATCH net-next v2 2/2] bonding: add netlink attributes to slave link dev Scott Feldman
2014-01-21 13:34 ` Jiri Pirko
2014-01-21 21:36 ` Scott Feldman
2014-01-21 22:00 ` Jiri Pirko
2014-01-21 22:42 ` Scott Feldman
2014-01-22 8:22 ` Jiri Pirko [this message]
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=20140122082215.GA2814@minipsycho.orion \
--to=jiri@resnulli.us \
--cc=andy@greyhouse.net \
--cc=dingtianhong@huawei.com \
--cc=fubar@us.ibm.com \
--cc=netdev@vger.kernel.org \
--cc=roopa@cumulusnetworks.com \
--cc=sfeldma@cumulusnetworks.com \
--cc=shm@cumulusnetworks.com \
--cc=vfalico@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).