2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-28 12:58:00 +00:00

11 Commits

Author SHA1 Message Date
Jesse Gross
149f577a25 netdev: Fully handle netdev lifecycle through refcounting.
This builds on earlier work that implemented netdev object refcounting.
However, rather than requiring explicit create and destroy calls,
these operations are now performed automatically based on the referenece
count.  This is important because in certain situations it is not
possible to know whether a netdev has already been created.  A
workaround existed (which looked fairly similar to this paradigm) but
introduced it's own issues.  This simplifies and unifies the API.
2010-01-15 11:34:34 -05:00
Ben Pfaff
58fda1dab1 Merge "master" branch into "db". 2009-12-02 11:49:53 -08:00
Justin Pettit
6c88d577e8 netdev: Allow explicit creation of netdev objects
This change adds netdev_create() and netdev_destroy() functions to allow
the creation of network devices through the netdev library.  Previously,
network devices had to already exist or be created on demand through
netdev_open().  This caused problems such as not being able to specify
TAP devices as ports in ovs-vswitchd, which this patch fixes.

This also lays the groundwork for adding GRE and VDE support.
2009-12-01 19:01:01 -08:00
Jesse Gross
fde05aded2 udatapath: Implement ZERO_TCP_FLAGS option.
An option to zero the TCP flags when querying flow stats was added
to the kernel datapath to support NetFlow active timeouts.  This
adds that same support to the user datapath.
2009-11-06 14:35:59 -08:00
Ben Pfaff
ec6fde61c8 Add new function xzalloc(n) as a shorthand for xcalloc(1, n). 2009-11-04 14:52:32 -08:00
Justin Pettit
3c71830aef dpif: Address portability issues in dpif-netdev
There were a number of Linux assumptions in dpif-netdev that were not
necessary.  This commit cleans those up to aid portability.
2009-08-25 14:12:01 -07:00
Justin Pettit
be2c418b73 Cleanup isdigit() warnings.
NetBSD's gcc complains if isdigit()'s argument is an unadorned char.  This
provides an appropriate cast.
2009-08-25 14:11:44 -07:00
Ben Pfaff
e33e4d356d netdev: Get rid of netdev_open_tap().
netdev_open() can always be used in place of netdev_open_tap().  The
former is going to be generalized to support pluggable network device
types, so it makes sense to use it everywhere.
2009-07-30 16:07:13 -07:00
Ben Pfaff
3d222126b4 netdev: Change netdev_get_mtu() to return an error code.
To make the netdev code more portable, it needs to support returning error
codes from functions that don't have them.  This commit changes
netdev_get_mtu() to return an error code and updates its caller.

(Currently netdev_get_mtu() won't ever return an error, but other future
implementations might.)
2009-07-30 16:07:13 -07:00
Ben Pfaff
d3d22744a7 vswitch: Avoid knowledge of details specific to Linux datapaths.
At startup, the vswitch needs to delete datapaths that are not configured
by the administrator.  Until now this was done by knowing the possible
names of Linux datapaths.  This commit cleans up by allowing each
datapath class to enumerate its existing datapaths and their names.
2009-07-06 11:06:36 -07:00
Ben Pfaff
72865317a4 New implementation of userspace datapath, based on the netdev library. 2009-07-06 09:55:06 -07:00