aboutsummaryrefslogtreecommitdiff
path: root/vswitchd/ovs-brcompatd.c
diff options
context:
space:
mode:
authorJesse Gross <jesse@nicira.com>2010-01-12 16:01:43 -0500
committerJesse Gross <jesse@nicira.com>2010-01-15 11:34:34 -0500
commit149f577a25508779b756515be1f1bdcefa3710fa (patch)
treee88ab9ea3f6667839fa59c23a7b0cf381eda8f33 /vswitchd/ovs-brcompatd.c
parentb4182c7f2d25110c2edaf96d33dd081257fa253b (diff)
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.
Diffstat (limited to 'vswitchd/ovs-brcompatd.c')
-rw-r--r--vswitchd/ovs-brcompatd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vswitchd/ovs-brcompatd.c b/vswitchd/ovs-brcompatd.c
index a45bee11..70921f21 100644
--- a/vswitchd/ovs-brcompatd.c
+++ b/vswitchd/ovs-brcompatd.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2008, 2009 Nicira Networks
+/* Copyright (c) 2008, 2009, 2010 Nicira Networks
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -755,7 +755,7 @@ handle_fdb_query_cmd(const struct ovsrec_open_vswitch *ovs,
struct mac *mac = &local_macs[n_local_macs];
struct netdev *netdev;
- error = netdev_open(iface_name, NETDEV_ETH_TYPE_NONE, &netdev);
+ error = netdev_open_default(iface_name, &netdev);
if (netdev) {
if (!netdev_get_etheraddr(netdev, mac->addr)) {
n_local_macs++;