summaryrefslogtreecommitdiffstats
path: root/net/openvswitch
diff options
context:
space:
mode:
authorAnsis Atteka <aatteka@nicira.com>2012-04-09 12:12:12 -0700
committerJesse Gross <jesse@nicira.com>2012-04-09 12:18:08 -0700
commit03fbf8b38792448370343f240131d9fde19d0387 (patch)
tree941d651fc1b5beeff618dfe68e141c0b5bdee19b /net/openvswitch
parentc55177e3e1e8a89d9d810d95ac18cb104865322c (diff)
downloadop-kernel-dev-03fbf8b38792448370343f240131d9fde19d0387.zip
op-kernel-dev-03fbf8b38792448370343f240131d9fde19d0387.tar.gz
openvswitch: Do not send notification if ovs_vport_set_options() failed
There is no need to send a notification if ovs_vport_set_options() failed and ovs_vport_cmd_set() did not change anything. Signed-off-by: Ansis Atteka <aatteka@nicira.com> Signed-off-by: Jesse Gross <jesse@nicira.com>
Diffstat (limited to 'net/openvswitch')
-rw-r--r--net/openvswitch/datapath.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c
index e44e631..4813d95 100644
--- a/net/openvswitch/datapath.c
+++ b/net/openvswitch/datapath.c
@@ -1635,7 +1635,9 @@ static int ovs_vport_cmd_set(struct sk_buff *skb, struct genl_info *info)
if (!err && a[OVS_VPORT_ATTR_OPTIONS])
err = ovs_vport_set_options(vport, a[OVS_VPORT_ATTR_OPTIONS]);
- if (!err && a[OVS_VPORT_ATTR_UPCALL_PID])
+ if (err)
+ goto exit_unlock;
+ if (a[OVS_VPORT_ATTR_UPCALL_PID])
vport->upcall_pid = nla_get_u32(a[OVS_VPORT_ATTR_UPCALL_PID]);
reply = ovs_vport_cmd_build_info(vport, info->snd_pid, info->snd_seq,
OpenPOWER on IntegriCloud