Skip to content

Commit 4de8b41

Browse files
Rosen, Ramidavem330
Rosen, Rami
authored andcommitted
bridge: remove oflags from setlink/dellink.
Commit 02dba43 ("bridge: fix setlink/dellink notifications") removed usage of oflags in both rtnl_bridge_setlink() and rtnl_bridge_dellink() methods. This patch removes this variable as it is no longer needed. Signed-off-by: Rami Rosen <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 7b46a64 commit 4de8b41

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

net/core/rtnetlink.c

+2-6
Original file line numberDiff line numberDiff line change
@@ -2918,7 +2918,7 @@ static int rtnl_bridge_setlink(struct sk_buff *skb, struct nlmsghdr *nlh)
29182918
struct net_device *dev;
29192919
struct nlattr *br_spec, *attr = NULL;
29202920
int rem, err = -EOPNOTSUPP;
2921-
u16 oflags, flags = 0;
2921+
u16 flags = 0;
29222922
bool have_flags = false;
29232923

29242924
if (nlmsg_len(nlh) < sizeof(*ifm))
@@ -2948,8 +2948,6 @@ static int rtnl_bridge_setlink(struct sk_buff *skb, struct nlmsghdr *nlh)
29482948
}
29492949
}
29502950

2951-
oflags = flags;
2952-
29532951
if (!flags || (flags & BRIDGE_FLAGS_MASTER)) {
29542952
struct net_device *br_dev = netdev_master_upper_dev_get(dev);
29552953

@@ -2993,7 +2991,7 @@ static int rtnl_bridge_dellink(struct sk_buff *skb, struct nlmsghdr *nlh)
29932991
struct net_device *dev;
29942992
struct nlattr *br_spec, *attr = NULL;
29952993
int rem, err = -EOPNOTSUPP;
2996-
u16 oflags, flags = 0;
2994+
u16 flags = 0;
29972995
bool have_flags = false;
29982996

29992997
if (nlmsg_len(nlh) < sizeof(*ifm))
@@ -3023,8 +3021,6 @@ static int rtnl_bridge_dellink(struct sk_buff *skb, struct nlmsghdr *nlh)
30233021
}
30243022
}
30253023

3026-
oflags = flags;
3027-
30283024
if (!flags || (flags & BRIDGE_FLAGS_MASTER)) {
30293025
struct net_device *br_dev = netdev_master_upper_dev_get(dev);
30303026

0 commit comments

Comments
 (0)