netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 net-next 0/2] rtnetlink: Updates to rtnetlink_event()
@ 2017-04-21 17:31 Vladislav Yasevich
  2017-04-21 17:31 ` [PATCH net-next 1/2] rtnetlink: Disable notification for NETDEV_NAMECHANGE event Vladislav Yasevich
  2017-04-21 17:31 ` [PATCH net-next V3 2/2] rtnl: Add support for netdev event attribute to link messages Vladislav Yasevich
  0 siblings, 2 replies; 14+ messages in thread
From: Vladislav Yasevich @ 2017-04-21 17:31 UTC (permalink / raw)
  To: netdev; +Cc: dsa, Vladislav Yasevich

This is a version 3 series came out of the conversation that started
as a result my first attempt to add netdevice event info to netlink messages.

First, let's clean-up the duplicate notifications for NETDEV_CHANGNAME
event.  We get a message from the event handler as well as a result of
do_setlink().  The two messages are identical, so remove the event.

Second, update the original patch to add IFLA_EVENT attribute
to the link message to only support currently white-listed events.
Like before, this is just an attribute that gets added to the rtnetlink
message only when the messaged was generated as a result of a netdev event.
In my case, this is necessary since I want to trap NETDEV_NOTIFY_PEERS
event (also possibly NETDEV_RESEND_IGMP event) and perform certain actions
in user space.  This is not possible since the messages generated as
a result of netdev events do not usually contain any changed data.  They
are just notifications.  This patch exposes this notification type to
userspace.

I will also update my patch to iproute that will show this data
through 'ip monitor'. 


V3: Rebased.  Cleaned-up duplicate event.

V2: Added missed events (from David Ahern)

Vladislav Yasevich (2):
  rtnetlink: Convert rtnetlink_event to white list
  rtnl: Add support for netdev event to link messages

 include/linux/rtnetlink.h    |   3 +-
 include/uapi/linux/if_link.h |  21 ++++++++
 net/core/dev.c               |   2 +-
 net/core/rtnetlink.c         | 121 +++++++++++++++++++++++++++++++++++--------
 4 files changed, 123 insertions(+), 24 deletions(-)

-- 
2.7.4


Vladislav Yasevich (2):
  rtnetlink: Disable notification for NETDEV_NAMECHANGE event
  rtnl: Add support for netdev event to link messages

 include/linux/rtnetlink.h    |  3 ++-
 include/uapi/linux/if_link.h | 11 ++++++++
 net/core/dev.c               |  2 +-
 net/core/rtnetlink.c         | 63 +++++++++++++++++++++++++++++++++++++-------
 4 files changed, 67 insertions(+), 12 deletions(-)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2017-05-02 21:57 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-21 17:31 [PATCH v3 net-next 0/2] rtnetlink: Updates to rtnetlink_event() Vladislav Yasevich
2017-04-21 17:31 ` [PATCH net-next 1/2] rtnetlink: Disable notification for NETDEV_NAMECHANGE event Vladislav Yasevich
2017-04-21 18:08   ` David Ahern
2017-04-27 19:26     ` Vlad Yasevich
2017-04-21 17:31 ` [PATCH net-next V3 2/2] rtnl: Add support for netdev event attribute to link messages Vladislav Yasevich
2017-04-24  1:07   ` David Ahern
2017-04-24 15:14     ` Roopa Prabhu
2017-04-27 19:51       ` Vlad Yasevich
2017-04-28  0:11         ` Roopa Prabhu
2017-04-27 19:43     ` Vlad Yasevich
2017-04-27 19:59       ` David Ahern
2017-04-28 16:38         ` Jiri Pirko
2017-05-01 13:35           ` Vlad Yasevich
2017-05-02 21:57             ` David Ahern

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).