Skip to content

Commit

Permalink
net: handle addr_type of 0 properly
Browse files Browse the repository at this point in the history
addr_type of 0 means that the type should be adopted from from_dev and
not from __hw_addr_del_multiple(). Unfortunately it isn't so and
addr_type will always be considered. Fix this by implementing the
considered and documented behavior.

Signed-off-by: Hagen Paul Pfeifer <hagen@jauu.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Hagen Paul Pfeifer authored and David S. Miller committed Feb 25, 2011
1 parent c486da3 commit 5aca1a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/core/dev_addr_lists.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ void __hw_addr_del_multiple(struct netdev_hw_addr_list *to_list,

list_for_each_entry(ha, &from_list->list, list) {
type = addr_type ? addr_type : ha->type;
__hw_addr_del(to_list, ha->addr, addr_len, addr_type);
__hw_addr_del(to_list, ha->addr, addr_len, type);
}
}
EXPORT_SYMBOL(__hw_addr_del_multiple);
Expand Down

0 comments on commit 5aca1a9

Please sign in to comment.