[ovs-git] [openvswitch/ovs] 77ee67: netlink-notifier: Support multiple groups.

GitHub noreply at github.com
Mon Jun 13 21:22:49 UTC 2016


  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: 77ee67e42dd730be7a1e3502d4f54a3f1ad17e73
      https://github.com/openvswitch/ovs/commit/77ee67e42dd730be7a1e3502d4f54a3f1ad17e73
  Author: Jarno Rajahalme <jarno at ovn.org>
  Date:   2016-06-13 (Mon, 13 Jun 2016)

  Changed paths:
    M lib/netlink-notifier.c
    M lib/netlink-notifier.h
    M lib/route-table.c
    M lib/rtnetlink.c
    M tests/test-netlink-conntrack.c

  Log Message:
  -----------
  netlink-notifier: Support multiple groups.

A netlink notifier ('nln') already supports multiple notifiers.  This
patch allows each of these notifiers to subscribe to a different
multicast group.  Sharing a single socket for multiple event types
(each on their own multicast group) provides serialization of events
when reordering of different event types could be problematic.  For
example, if a 'create' event and 'delete' event are on different
netlink multicast group, we may want to process those events in the
order in which kernel issued them, rather than in the order we happen
to check for them.

Moving the multicast group argument from nln_create() to
nln_notifier_create() allows each notifier to specify a different
multicast group.  The parse callback needs to identify the group the
message belonged to by returning the corresponding group number, or 0
when an parse error occurs.

Signed-off-by: Jarno Rajahalme <jarno at ovn.org>
Acked-by: Thadeu Lima de Souza Cascardo <cascardo at redhat.com>




More information about the git mailing list