[ovs-dev] [netlink v4 00/52] use Netlink for kernel datapath interface

Justin Pettit jpettit at nicira.com
Wed Jan 12 06:23:41 UTC 2011


This is obviously something Ben whipped together to try and take away some of the glory surrounding my .gitignore commit from earlier this evening.  It's really kind of sad, and I'm not sure I even want to dignify it with a review.

--Justin


On Jan 11, 2011, at 10:08 PM, Martin Casado wrote:

> Hey Justin,
> 
> It's been at least 15min.  What is the holdup on the review for this patch series?
> 
>> The change to use Netlink for the kernel datapath interface is now ready
>> for full review.  I am reposting the full series of changes, including
>> those that have already been reviewed, for completeness.  I have taken
>> most of the comments already provided into account, with the exception
>> of Justin's comments that he sent today.  Jesse, I've also not changed
>> the "dump" function for vports to use copy semantics; I'm still thinking
>> about that (see the thread "netlink v3 16/16").
>> 
>> This has been compile-tested on i386 2.6.36 and amd64 2.6.33.  I lightly
>> tested it on the former.  I've been using sparse like mad, so there
>> shouldn't be much to offend there.
>> 
>> All of the patches that have already been reviewed should be marked with
>> Acked-by or with "Reviewed by" if no formal ack was provided.
>> 
>> I'm working on a followup to attach large action sets to sk_buffs as
>> frags, and on another one to drop "dp_idx" in favor of the ifindex
>> of a datapath's local port.
>> 
>> I'll be awfully happy when this is finally put to bed.
>> 
>> Comments welcome!
>> 
>> Ben Pfaff (52):
>>   ofpbuf: New function ofpbuf_use_stack().
>>   ofpbuf: Enable ofpbuf_push() to expand headroom.
>>   ofpbuf: New function ofpbuf_clone_data_with_headroom().
>>   hmap: New function hmap_at_position().
>>   netlink: New functions for finding a specific attribute.
>>   netlink: Log duplicate attributes in nl_policy_parse().
>>   netlink-socket: Add functions for joining and leaving multicast
>>     groups.
>>   netlink-socket: New function for draining the receive buffer.
>>   netlink-socket: Slightly improve logging of Generic Netlink messages.
>>   netlink-socket: Make dumping and doing transactions on same nl_sock
>>     safe.
>>   netlink-socket: Consistently log sequence numbers in hexadecimal.
>>   netlink-socket: Log Generic Netlink family names.
>>   odp-util: Improve formatting of bogus empty action attributes.
>>   shash: New "smap" functions for working with string-to-string maps.
>>   netdev: Use shash and smap functions instead of inlined substitutes.
>>   datapath: Change listing flows to use an iterator concept.
>>   datapath: Convert odp_flow_key to use Netlink attributes instead.
>>   datapath: Report kernel's flow key when passing packets up to
>>     userspace.
>>   datapath: Change listing ports to use an iterator concept.
>>   datapath: Make it possible to query vports by name regardless of
>>     datapath.
>>   datapath: Drop datapath index and port number from Ethtool output.
>>   netdev: Make netdev arguments fetchable, and implement for
>>     netdev-vport.
>>   ovs-dpctl: Use netdev_get_config() to print vport configurations.
>>   dpif: Eliminate "struct odp_port" from client-visible interface.
>>   datapath: Change vport type from string to integer enumeration.
>>   datapath: Make VERIFY_NUL_STRING return a negative error code.
>>   datapath: Change userspace vport interface to use Netlink attributes.
>>   datapath: Drop flow information from odp_stats.
>>   datapath: Drop queue information from odp_stats.
>>   datapath: Drop port information from odp_stats.
>>   datapath: Change ODP_FLOW_GET to retrieve only a single flow at a
>>     time.
>>   ovs-dpctl: Use datapath enumeration functions instead of guessing
>>     names.
>>   dpif: Eliminate "struct odp_flow" from client-visible interface.
>>   dpif: Eliminate "struct odp_flow_stats" from client-visible
>>     interface.
>>   dpif: Eliminate ODPPF_* constants from client-visible interface.
>>   ofproto: Fix test for installability change when revalidating.
>>   ofproto: Generalize facet_put__() so that it is more useful.
>>   ofproto: Avoid using ODPFF_ZERO_TCP_FLAGS.
>>   datapath: Eliminate 'flags' member from odp_flow.
>>   datapath: Convert ODP_FLOW_* and ODP_EXECUTE to put dp_idx into
>>     message.
>>   datapath: Convert datapath operations to use Netlink framing.
>>   datapath: Convert flows to use Netlink framing.
>>   datapath: Convert ODP_EXECUTE to use Netlink framing.
>>   datapath: Get rid of ODPP_NONE.
>>   Eliminate ODPL_* from userspace-facing interface.
>>   datapath: Extend compatibility code for genl_register_mc_group().
>>   datapath: Adopt Generic Netlink-compatible locking.
>>   datapath: Convert upcalls and ODP_EXECUTE to use AF_NETLINK socket
>>     layer.
>>   datapath: Convert ODP_DP_* commands to use AF_NETLINK socket layer.
>>   datapath: Convert ODP_VPORT_* to use AF_NETLINK socket layer.
>>   datapath: Convert ODP_FLOW_* commands to use AF_NETLINK socket layer.
>>   dpif-linux: Replace 'minor' by 'dp_idx'.
>> 
>>  datapath/Modules.mk                                |    1 -
>>  datapath/actions.c                                 |   82 +-
>>  datapath/actions.h                                 |    4 +-
>>  datapath/datapath.c                                | 2425 ++++++++++----------
>>  datapath/datapath.h                                |   34 +-
>>  datapath/dp_notify.c                               |    8 +-
>>  datapath/flow.c                                    |  293 +++-
>>  datapath/flow.h                                    |   33 +-
>>  datapath/linux-2.6/Modules.mk                      |    3 +-
>>  datapath/linux-2.6/compat-2.6/genetlink-brcompat.c |   16 +-
>>  .../linux-2.6/compat-2.6/genetlink-openvswitch.c   |   24 +-
>>  datapath/linux-2.6/compat-2.6/genetlink.inc        |   19 +
>>  .../linux-2.6/compat-2.6/include/linux/kernel.h    |    6 +
>>  .../linux-2.6/compat-2.6/include/net/genetlink.h   |    6 -
>>  .../linux-2.6/compat-2.6/include/net/netlink.h     |   49 +-
>>  datapath/odp-compat.h                              |   58 -
>>  datapath/table.c                                   |   47 +
>>  datapath/table.h                                   |    1 +
>>  datapath/tunnel.c                                  |   44 +-
>>  datapath/tunnel.h                                  |    8 +-
>>  datapath/vport-capwap.c                            |    8 +-
>>  datapath/vport-gre.c                               |    8 +-
>>  datapath/vport-internal_dev.c                      |    5 +-
>>  datapath/vport-netdev.c                            |    2 +-
>>  datapath/vport-patch.c                             |   88 +-
>>  datapath/vport.c                                   |  371 +---
>>  datapath/vport.h                                   |   39 +-
>>  include/openvswitch/datapath-protocol.h            |  394 ++--
>>  include/openvswitch/tunnel.h                       |   11 +-
>>  lib/automake.mk                                    |    1 +
>>  lib/dpif-linux.c                                   | 1614 ++++++++++----
>>  lib/dpif-linux.h                                   |   56 +
>>  lib/dpif-netdev.c                                  |  443 +++--
>>  lib/dpif-provider.h                                |  207 ++-
>>  lib/dpif.c                                         |  673 +++---
>>  lib/dpif.h                                         |  126 +-
>>  lib/flow.c                                         |   14 +-
>>  lib/flow.h                                         |    9 +-
>>  lib/hmap.c                                         |   43 +
>>  lib/hmap.h                                         |    3 +
>>  lib/netdev-dummy.c                                 |    4 +-
>>  lib/netdev-linux.c                                 |   29 +-
>>  lib/netdev-provider.h                              |   13 +-
>>  lib/netdev-vport.c                                 |  527 +++--
>>  lib/netdev-vport.h                                 |   10 +-
>>  lib/netdev.c                                       |  107 +-
>>  lib/netdev.h                                       |    5 +-
>>  lib/netlink-protocol.h                             |   13 +-
>>  lib/netlink-socket.c                               |  364 +++-
>>  lib/netlink-socket.h                               |   12 +-
>>  lib/netlink.c                                      |   37 +-
>>  lib/netlink.h                                      |    6 +-
>>  lib/nx-match.c                                     |    7 +-
>>  lib/odp-util.c                                     |  483 ++++-
>>  lib/odp-util.h                                     |   35 +-
>>  lib/ofp-util.c                                     |   25 +-
>>  lib/ofp-util.h                                     |    4 +
>>  lib/ofpbuf.c                                       |  180 ++-
>>  lib/ofpbuf.h                                       |   18 +-
>>  lib/packets.h                                      |    4 +
>>  lib/rtnetlink.c                                    |   13 +-
>>  lib/shash.c                                        |   54 +
>>  lib/shash.h                                        |    6 +
>>  ofproto/ofproto-sflow.c                            |   47 +-
>>  ofproto/ofproto-sflow.h                            |    6 +-
>>  ofproto/ofproto.c                                  |  525 ++---
>>  utilities/nlmon.c                                  |    9 +-
>>  utilities/ovs-dpctl.c                              |  153 +-
>>  utilities/ovs-vsctl.c                              |    6 +-
>>  vswitchd/bridge.c                                  |   70 +-
>>  vswitchd/ovs-brcompatd.c                           |   25 +-
>>  vswitchd/proc-net-compat.c                         |    4 +-
>>  72 files changed, 6015 insertions(+), 4062 deletions(-)
>>  create mode 100644 datapath/linux-2.6/compat-2.6/genetlink.inc
>>  delete mode 100644 datapath/odp-compat.h
>>  create mode 100644 lib/dpif-linux.h
>> 
>> 
>> _______________________________________________
>> dev mailing list
>> dev at openvswitch.org
>> http://openvswitch.org/mailman/listinfo/dev_openvswitch.org
> 
> 
> -- 
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Martin Casado
> Nicira Networks, Inc.
> www.nicira.com | www.openvswitch.org
> cell: 650-776-1457
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> 
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev_openvswitch.org





More information about the dev mailing list