From: Jiri Pirko <jiri@resnulli.us>
To: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net, yotamg@mellanox.com,
idosch@mellanox.com, mlxsw@mellanox.com, andrew@lunn.ch
Subject: Re: [patch net-next v2 03/12] ipmr: Add FIB notification access functions
Date: Mon, 25 Sep 2017 11:47:13 +0200 [thread overview]
Message-ID: <20170925094713.GD1899@nanopsycho> (raw)
In-Reply-To: <bcf097e3-9c6c-b4bd-ac1e-8675ae87510e@cumulusnetworks.com>
Mon, Sep 25, 2017 at 11:40:16AM CEST, nikolay@cumulusnetworks.com wrote:
>On 25/09/17 12:35, Nikolay Aleksandrov wrote:
>> On 24/09/17 20:22, Jiri Pirko wrote:
>>> From: Yotam Gigi <yotamg@mellanox.com>
>>>
>>> Make the ipmr module register as a FIB notifier. To do that, implement both
>>> the ipmr_seq_read and ipmr_dump ops.
>>>
>>> The ipmr_seq_read op returns a sequence counter that is incremented on
>>> every notification related operation done by the ipmr. To implement that,
>>> add a sequence counter in the netns_ipv4 struct and increment it whenever a
>>> new MFC route or VIF are added or deleted. The sequence operations are
>>> protected by the RTNL lock.
>>>
>>> The ipmr_dump iterates the list of MFC routes and the list of VIF entries
>>> and sends notifications about them. The entries dump is done under RCU
>>> where the VIF dump uses the mrt_lock too, as the vif->dev field can change
>>> under RCU.
>>>
>>> Signed-off-by: Yotam Gigi <yotamg@mellanox.com>
>>> Reviewed-by: Ido Schimmel <idosch@mellanox.com>
>>> Signed-off-by: Jiri Pirko <jiri@mellanox.com>
>>> ---
>>> v1->v2:
>>> - Take the mrt_lock when dumping VIF entries.
>>> ---
>>> include/linux/mroute.h | 15 ++++++
>>> include/net/netns/ipv4.h | 3 ++
>>> net/ipv4/ipmr.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++-
>>> 3 files changed, 153 insertions(+), 2 deletions(-)
>>>
>>
>> LGTM,
>>
>> Reviewed-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
>>
>>
>
>One note here if you're going to spin another version of the set, you can
>consider renaming the call_* functions to either mroute_* or ipmr_* (e.g.
>ipmr_call_...). I personally prefer the ipmr prefix.
The naming scheme in this patch is aligned with the rest of the code.
Please see "call_netdevice_notifiers" for example.
Please feel free to send a patch to chanche them all.
next prev parent reply other threads:[~2017-09-25 9:47 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-24 17:22 [patch net-next v2 00/12] mlxsw: Add support for offloading IPv4 multicast routes Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 01/12] fib: notifier: Add VIF add and delete event types Jiri Pirko
2017-09-25 9:20 ` Nikolay Aleksandrov
2017-09-24 17:22 ` [patch net-next v2 02/12] ipmr: Add reference count to MFC entries Jiri Pirko
2017-09-25 9:27 ` Nikolay Aleksandrov
2017-09-24 17:22 ` [patch net-next v2 03/12] ipmr: Add FIB notification access functions Jiri Pirko
2017-09-25 1:19 ` Yunsheng Lin
2017-09-25 5:38 ` Yotam Gigi
2017-09-25 6:32 ` Yunsheng Lin
2017-09-25 9:35 ` Nikolay Aleksandrov
2017-09-25 9:40 ` Nikolay Aleksandrov
2017-09-25 9:47 ` Jiri Pirko [this message]
2017-09-25 9:59 ` Nikolay Aleksandrov
2017-09-24 17:22 ` [patch net-next v2 04/12] ipmr: Send FIB notifications on MFC and VIF entries Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 05/12] net: ipmr: Add MFC offload indication Jiri Pirko
2017-09-25 9:36 ` Nikolay Aleksandrov
2017-09-25 11:21 ` Yotam Gigi
2017-09-24 17:22 ` [patch net-next v2 06/12] net: mroute: Check if rule is a default rule Jiri Pirko
2017-09-25 1:28 ` Yunsheng Lin
2017-09-25 5:39 ` Yotam Gigi
2017-09-25 9:45 ` Jiri Pirko
2017-09-25 10:02 ` Nikolay Aleksandrov
2017-09-25 13:37 ` Yotam Gigi
2017-09-25 9:38 ` Nikolay Aleksandrov
2017-09-24 17:22 ` [patch net-next v2 07/12] mlxsw: spectrum: Add the multicast routing offloading logic Jiri Pirko
2017-09-25 1:48 ` Yunsheng Lin
2017-09-25 5:55 ` Yotam Gigi
2017-09-25 10:40 ` Nikolay Aleksandrov
2017-09-25 10:53 ` Yotam Gigi
2017-09-24 17:22 ` [patch net-next v2 08/12] mlxsw: spectrum: Add the multicast routing hardware logic Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 09/12] mlxsw: spectrum: router: Squash the default route table to main Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 10/12] mlxsw: spectrum_router: Add multicast routes notification handling functionality Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 11/12] mlxsw: spectrum: Notify multicast router on RIF MTU changes Jiri Pirko
2017-09-24 17:22 ` [patch net-next v2 12/12] mlxsw: spectrum: router: Don't ignore IPMR notifications 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=20170925094713.GD1899@nanopsycho \
--to=jiri@resnulli.us \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=idosch@mellanox.com \
--cc=mlxsw@mellanox.com \
--cc=netdev@vger.kernel.org \
--cc=nikolay@cumulusnetworks.com \
--cc=yotamg@mellanox.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