Skip to content

Commit

Permalink
ionic: ignore eexist on rx filter add
Browse files Browse the repository at this point in the history
Don't worry if the rx filter add firmware request fails on
EEXIST, at least we know the filter is there.  Same for
the delete request, at least we know it isn't there.

Fixes: 2a65454 ("ionic: Add Rx filter and rx_mode ndo support")
Signed-off-by: Shannon Nelson <snelson@pensando.io>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Shannon Nelson authored and David S. Miller committed Mar 22, 2020
1 parent 0e1825f commit 53faea3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ethernet/pensando/ionic/ionic_lif.c
Original file line number Diff line number Diff line change
Expand Up @@ -832,7 +832,7 @@ static int ionic_lif_addr_add(struct ionic_lif *lif, const u8 *addr)

memcpy(ctx.cmd.rx_filter_add.mac.addr, addr, ETH_ALEN);
err = ionic_adminq_post_wait(lif, &ctx);
if (err)
if (err && err != -EEXIST)
return err;

return ionic_rx_filter_save(lif, 0, IONIC_RXQ_INDEX_ANY, 0, &ctx);
Expand Down Expand Up @@ -862,7 +862,7 @@ static int ionic_lif_addr_del(struct ionic_lif *lif, const u8 *addr)
spin_unlock_bh(&lif->rx_filters.lock);

err = ionic_adminq_post_wait(lif, &ctx);
if (err)
if (err && err != -EEXIST)
return err;

netdev_dbg(lif->netdev, "rx_filter del ADDR %pM (id %d)\n", addr,
Expand Down

0 comments on commit 53faea3

Please sign in to comment.