diff options
author | Pavel Emelyanov <xemul@openvz.org> | 2008-05-18 00:10:09 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2008-05-22 06:34:21 -0400 |
commit | 0dd646fe0549251e79d6fb03e6773bcc6ccea61f (patch) | |
tree | f767ff2d0df29a8917b309819123e7873a5c7271 /drivers | |
parent | 4b8a9239ee708958ed72722a0e5e0cf34243ad26 (diff) |
bonding: Remove redundant argument from bond_create.
While we're fixing the bond_create, I hope it's OK to polish it
a bit after the fixes.
The third argument is NULL at the first caller and is ignored by
the second one, so remove it.
Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Acked-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/bonding/bond_main.c | 7 | ||||
-rw-r--r-- | drivers/net/bonding/bond_sysfs.c | 2 | ||||
-rw-r--r-- | drivers/net/bonding/bonding.h | 2 |
3 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index e3da1e53b9ce..6b1216455bc9 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -4848,7 +4848,7 @@ static struct lock_class_key bonding_netdev_xmit_lock_key; | |||
4848 | * Caller must NOT hold rtnl_lock; we need to release it here before we | 4848 | * Caller must NOT hold rtnl_lock; we need to release it here before we |
4849 | * set up our sysfs entries. | 4849 | * set up our sysfs entries. |
4850 | */ | 4850 | */ |
4851 | int bond_create(char *name, struct bond_params *params, struct bonding **newbond) | 4851 | int bond_create(char *name, struct bond_params *params) |
4852 | { | 4852 | { |
4853 | struct net_device *bond_dev; | 4853 | struct net_device *bond_dev; |
4854 | struct bonding *bond, *nxt; | 4854 | struct bonding *bond, *nxt; |
@@ -4902,9 +4902,6 @@ int bond_create(char *name, struct bond_params *params, struct bonding **newbond | |||
4902 | 4902 | ||
4903 | lockdep_set_class(&bond_dev->_xmit_lock, &bonding_netdev_xmit_lock_key); | 4903 | lockdep_set_class(&bond_dev->_xmit_lock, &bonding_netdev_xmit_lock_key); |
4904 | 4904 | ||
4905 | if (newbond) | ||
4906 | *newbond = bond_dev->priv; | ||
4907 | |||
4908 | netif_carrier_off(bond_dev); | 4905 | netif_carrier_off(bond_dev); |
4909 | 4906 | ||
4910 | up_write(&bonding_rwsem); | 4907 | up_write(&bonding_rwsem); |
@@ -4950,7 +4947,7 @@ static int __init bonding_init(void) | |||
4950 | init_rwsem(&bonding_rwsem); | 4947 | init_rwsem(&bonding_rwsem); |
4951 | 4948 | ||
4952 | for (i = 0; i < max_bonds; i++) { | 4949 | for (i = 0; i < max_bonds; i++) { |
4953 | res = bond_create(NULL, &bonding_defaults, NULL); | 4950 | res = bond_create(NULL, &bonding_defaults); |
4954 | if (res) | 4951 | if (res) |
4955 | goto err; | 4952 | goto err; |
4956 | } | 4953 | } |
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c index 08f3d396bcd6..452a789bf2eb 100644 --- a/drivers/net/bonding/bond_sysfs.c +++ b/drivers/net/bonding/bond_sysfs.c | |||
@@ -122,7 +122,7 @@ static ssize_t bonding_store_bonds(struct class *cls, const char *buffer, size_t | |||
122 | if (command[0] == '+') { | 122 | if (command[0] == '+') { |
123 | printk(KERN_INFO DRV_NAME | 123 | printk(KERN_INFO DRV_NAME |
124 | ": %s is being created...\n", ifname); | 124 | ": %s is being created...\n", ifname); |
125 | rv = bond_create(ifname, &bonding_defaults, &bond); | 125 | rv = bond_create(ifname, &bonding_defaults); |
126 | if (rv) { | 126 | if (rv) { |
127 | printk(KERN_INFO DRV_NAME ": Bond creation failed.\n"); | 127 | printk(KERN_INFO DRV_NAME ": Bond creation failed.\n"); |
128 | res = rv; | 128 | res = rv; |
diff --git a/drivers/net/bonding/bonding.h b/drivers/net/bonding/bonding.h index a3c74e20aa53..0ce7f4ae920f 100644 --- a/drivers/net/bonding/bonding.h +++ b/drivers/net/bonding/bonding.h | |||
@@ -301,7 +301,7 @@ static inline void bond_unset_master_alb_flags(struct bonding *bond) | |||
301 | 301 | ||
302 | struct vlan_entry *bond_next_vlan(struct bonding *bond, struct vlan_entry *curr); | 302 | struct vlan_entry *bond_next_vlan(struct bonding *bond, struct vlan_entry *curr); |
303 | int bond_dev_queue_xmit(struct bonding *bond, struct sk_buff *skb, struct net_device *slave_dev); | 303 | int bond_dev_queue_xmit(struct bonding *bond, struct sk_buff *skb, struct net_device *slave_dev); |
304 | int bond_create(char *name, struct bond_params *params, struct bonding **newbond); | 304 | int bond_create(char *name, struct bond_params *params); |
305 | void bond_destroy(struct bonding *bond); | 305 | void bond_destroy(struct bonding *bond); |
306 | int bond_release_and_destroy(struct net_device *bond_dev, struct net_device *slave_dev); | 306 | int bond_release_and_destroy(struct net_device *bond_dev, struct net_device *slave_dev); |
307 | int bond_create_sysfs(void); | 307 | int bond_create_sysfs(void); |