projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4335d60
)
bonding: remove no longer needed lock for bond_xxx_info_query()
author
dingtianhong
<
[email protected]
>
Fri, 21 Feb 2014 08:08:54 +0000
(16:08 +0800)
committer
David S. Miller
<
[email protected]
>
Mon, 24 Feb 2014 23:28:23 +0000
(18:28 -0500)
The bond_xxx_info_query() was already in RTNL, so no need to use
bond lock to protect the bond slave list, so remove it.
Cc: Jay Vosburgh <
[email protected]
>
Cc: Veaceslav Falico <
[email protected]
>
Cc: Andy Gospodarek <
[email protected]
>
Signed-off-by: Ding Tianhong <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
drivers/net/bonding/bond_main.c
patch
|
blob
|
history
diff --git
a/drivers/net/bonding/bond_main.c
b/drivers/net/bonding/bond_main.c
index 942eeb1c7794128b3aa0af238f329e9114b5edf3..12948b33451a37f2db51c53e12ff1effb31b4f80 100644
(file)
--- a/
drivers/net/bonding/bond_main.c
+++ b/
drivers/net/bonding/bond_main.c
@@
-1816,9
+1816,7
@@
static int bond_info_query(struct net_device *bond_dev, struct ifbond *info)
info->bond_mode = bond->params.mode;
info->miimon = bond->params.miimon;
- read_lock(&bond->lock);
info->num_slaves = bond->slave_cnt;
- read_unlock(&bond->lock);
return 0;
}
@@
-1830,7
+1828,6
@@
static int bond_slave_info_query(struct net_device *bond_dev, struct ifslave *in
int i = 0, res = -ENODEV;
struct slave *slave;
- read_lock(&bond->lock);
bond_for_each_slave(bond, slave, iter) {
if (i++ == (int)info->slave_id) {
res = 0;
@@
-1841,7
+1838,6
@@
static int bond_slave_info_query(struct net_device *bond_dev, struct ifslave *in
break;
}
}
- read_unlock(&bond->lock);
return res;
}