Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 74717
b: refs/heads/master
c: 8e4b932
h: refs/heads/master
i:
  74715: cf77f5f
v: v3
  • Loading branch information
Wagner Ferenc authored and Jeff Garzik committed Dec 7, 2007
1 parent c3d3589 commit 12e5b33
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 19 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: 1dcdcd69549c8e439fbe97a94ff0332ed8a55558
refs/heads/master: 8e4b9329080b7c37e3dcf4a7c435657d4d0f4816
21 changes: 3 additions & 18 deletions trunk/drivers/net/bonding/bond_sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -456,17 +456,11 @@ static ssize_t bonding_show_xmit_hash(struct device *d,
struct device_attribute *attr,
char *buf)
{
int count = 0;
struct bonding *bond = to_bond(d);

if ((bond->params.mode == BOND_MODE_XOR) ||
(bond->params.mode == BOND_MODE_8023AD)) {
count = sprintf(buf, "%s %d\n",
xmit_hashtype_tbl[bond->params.xmit_policy].modename,
bond->params.xmit_policy);
}

return count;
return sprintf(buf, "%s %d\n",
xmit_hashtype_tbl[bond->params.xmit_policy].modename,
bond->params.xmit_policy);
}

static ssize_t bonding_store_xmit_hash(struct device *d,
Expand All @@ -484,15 +478,6 @@ static ssize_t bonding_store_xmit_hash(struct device *d,
goto out;
}

if ((bond->params.mode != BOND_MODE_XOR) &&
(bond->params.mode != BOND_MODE_8023AD)) {
printk(KERN_ERR DRV_NAME
"%s: Transmit hash policy is irrelevant in this mode.\n",
bond->dev->name);
ret = -EPERM;
goto out;
}

new_value = bond_parse_parm((char *)buf, xmit_hashtype_tbl);
if (new_value < 0) {
printk(KERN_ERR DRV_NAME
Expand Down

0 comments on commit 12e5b33

Please sign in to comment.