Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 46948
b: refs/heads/master
c: 243cb4e
h: refs/heads/master
v: v3
  • Loading branch information
Joe Jin authored and David S. Miller committed Feb 8, 2007
1 parent 3fccb1f commit 5561ca8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6b31a515e3401685cdab2eeb6692f1a0f53f72ca
refs/heads/master: 243cb4e56061c3f4cb76312c5527840344d57c3b
4 changes: 1 addition & 3 deletions trunk/drivers/net/bonding/bond_alb.c
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ static int tlb_initialize(struct bonding *bond)

spin_lock_init(&(bond_info->tx_hashtbl_lock));

new_hashtbl = kmalloc(size, GFP_KERNEL);
new_hashtbl = kzalloc(size, GFP_KERNEL);
if (!new_hashtbl) {
printk(KERN_ERR DRV_NAME
": %s: Error: Failed to allocate TLB hash table\n",
Expand All @@ -195,8 +195,6 @@ static int tlb_initialize(struct bonding *bond)

bond_info->tx_hashtbl = new_hashtbl;

memset(bond_info->tx_hashtbl, 0, size);

for (i = 0; i < TLB_HASH_TABLE_SIZE; i++) {
tlb_init_table_entry(&bond_info->tx_hashtbl[i], 1);
}
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/net/bonding/bond_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1343,14 +1343,12 @@ int bond_enslave(struct net_device *bond_dev, struct net_device *slave_dev)
"inaccurate.\n", bond_dev->name, slave_dev->name);
}

new_slave = kmalloc(sizeof(struct slave), GFP_KERNEL);
new_slave = kzalloc(sizeof(struct slave), GFP_KERNEL);
if (!new_slave) {
res = -ENOMEM;
goto err_undo_flags;
}

memset(new_slave, 0, sizeof(struct slave));

/* save slave's original flags before calling
* netdev_set_master and dev_open
*/
Expand Down

0 comments on commit 5561ca8

Please sign in to comment.