Skip to content

Commit

Permalink
net: aquantia: add an error handling in aq_nic_set_multicast_list
Browse files Browse the repository at this point in the history
add an error handling in aq_nic_set_multicast_list, it may not
work when hw_multicast_list_set error; and at the same time
it will remove gcc Wunused-but-set-variable warning.

Signed-off-by: Chenwandun <[email protected]>
Reviewed-by: Igor Russkikh <[email protected]>
Reviewed-by: Andrew Lunn <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
Chenwandun authored and davem330 committed Oct 19, 2019
1 parent 7087383 commit 3d00cf2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/ethernet/aquantia/atlantic/aq_nic.c
Original file line number Diff line number Diff line change
Expand Up @@ -664,6 +664,8 @@ int aq_nic_set_multicast_list(struct aq_nic_s *self, struct net_device *ndev)
err = hw_ops->hw_multicast_list_set(self->aq_hw,
self->mc_list.ar,
self->mc_list.count);
if (err < 0)
return err;
}
return aq_nic_set_packet_filter(self, packet_filter);
}
Expand Down

0 comments on commit 3d00cf2

Please sign in to comment.