netdev: New function netdev_reopen().
authorBen Pfaff <blp@nicira.com>
Thu, 8 Apr 2010 18:18:07 +0000 (11:18 -0700)
committerBen Pfaff <blp@nicira.com>
Thu, 8 Apr 2010 19:31:47 +0000 (12:31 -0700)
commit1510d7c3ce678e9e0c7dc22f819a95b570a3d191
tree4cad7e4a6ee5b414d6ca04e210f123628e5ebcab
parentca9bbddb1b17cb5d7fb901f78ab268971c18855e
netdev: New function netdev_reopen().

In the new wdp layer it is convenient to pass around copies of struct
wdp_port, which contains a struct netdev *.  To make this efficient
it makes sense to maintain a reference count in struct netdev itself, so
that copying and freeing copies of a netdev become just incrementing and
decrementing the reference count.  This commit adds that ability.
lib/netdev-provider.h
lib/netdev.c
lib/netdev.h