From: Shannon Nelson <snelson@pensando.io>
To: davem@davemloft.net, netdev@vger.kernel.org, kuba@kernel.org
Cc: drivers@pensando.io, jtoppins@redhat.com,
Shannon Nelson <snelson@pensando.io>
Subject: [PATCH net-next 9/9] ionic: tame the filter no space message
Date: Sat, 9 Oct 2021 11:45:23 -0700 [thread overview]
Message-ID: <20211009184523.73154-10-snelson@pensando.io> (raw)
In-Reply-To: <20211009184523.73154-1-snelson@pensando.io>
Override the automatic AdminQ error message in order to
capture the potential No Space message when we hit the
max vlan limit, and add additional messaging to detail
what filter failed.
Signed-off-by: Shannon Nelson <snelson@pensando.io>
---
.../net/ethernet/pensando/ionic/ionic_rx_filter.c | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/pensando/ionic/ionic_rx_filter.c b/drivers/net/ethernet/pensando/ionic/ionic_rx_filter.c
index 366f15794866..f6e785f949f9 100644
--- a/drivers/net/ethernet/pensando/ionic/ionic_rx_filter.c
+++ b/drivers/net/ethernet/pensando/ionic/ionic_rx_filter.c
@@ -357,7 +357,7 @@ static int ionic_lif_filter_add(struct ionic_lif *lif,
}
if (err != -ENOSPC)
- err = ionic_adminq_post_wait(lif, &ctx);
+ err = ionic_adminq_post_wait_nomsg(lif, &ctx);
spin_lock_bh(&lif->rx_filters.lock);
@@ -382,6 +382,19 @@ static int ionic_lif_filter_add(struct ionic_lif *lif,
return 0;
}
+ ionic_adminq_netdev_err_print(lif, ctx.cmd.cmd.opcode,
+ ctx.comp.comp.status, err);
+ switch (le16_to_cpu(ctx.cmd.rx_filter_add.match)) {
+ case IONIC_RX_FILTER_MATCH_VLAN:
+ netdev_info(lif->netdev, "rx_filter add failed: VLAN %d\n",
+ ctx.cmd.rx_filter_add.vlan.vlan);
+ break;
+ case IONIC_RX_FILTER_MATCH_MAC:
+ netdev_info(lif->netdev, "rx_filter add failed: ADDR %pM\n",
+ ctx.cmd.rx_filter_add.mac.addr);
+ break;
+ }
+
return err;
}
--
2.17.1
next prev parent reply other threads:[~2021-10-09 18:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-09 18:45 [PATCH net-next 0/9] ionic: add vlanid overflow management Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 1/9] ionic: add filterlist to debugfs Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 2/9] ionic: move lif mac address functions Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 3/9] ionic: remove mac overflow flags Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 4/9] ionic: add generic filter search Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 5/9] ionic: generic filter add Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 6/9] ionic: generic filter delete Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 7/9] ionic: handle vlan id overflow Shannon Nelson
2021-10-09 18:45 ` [PATCH net-next 8/9] ionic: allow adminq requests to override default error message Shannon Nelson
2021-10-09 18:45 ` Shannon Nelson [this message]
2021-10-10 9:50 ` [PATCH net-next 0/9] ionic: add vlanid overflow management patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211009184523.73154-10-snelson@pensando.io \
--to=snelson@pensando.io \
--cc=davem@davemloft.net \
--cc=drivers@pensando.io \
--cc=jtoppins@redhat.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.