ovs: fix dp check in ovs_dp_reset_user_features
Subsystems (3)
PATCH 1/1 ovs: fix dp check in ovs_dp_reset_user_features
This fixes crash when userspace does "ovs-dpctl add-dp dev" where dev is existing non-dp netdevice.
Introduced by:
commit 44da5ae5fbea4686f667dc854e5ea16814e44c59
"openvswitch: Drop user features if old user space attempted to create datapath"
Signed-off-by Jiri Pirko <[email protected]>
--- net/openvswitch/datapath.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/openvswitch/datapath.c +1 -1
@@ -1174,7 +1174,7 @@ static void ovs_dp_reset_user_features(struct sk_buff *skb, struct genl_info *instruct datapath *dp; dp =lookup_datapath (sock_net (skb->sk), info->userhdr, info->attrs); -if (!dp) +if (IS_ERR (dp))return ;WARN (dp->user_features,"Dropping previously announced user features\n" );
Signature · 1 line
1.8.5.3
A message that is not in the archive (sent off-list or not yet received): 1392374556-8375-1-git-send-email-jiri-rHqAuBHg3fBzbRFIqnYvSA@public.gmane.org
Jesse Gross
AppliedQuoted 8 lines · Jiri Pirko
This fixes crash when userspace does "ovs-dpctl add-dp dev" where dev is existing non-dp netdevice.
Introduced by:
commit44da5ae5fbea4686f667dc854e5ea16814e44c59
"openvswitch: Drop user features if old user space attempted to create datapath"Signed-off-by Jiri Pirko <[email protected]>
Applied, thanks.