All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tony Nguyen <anthony.l.nguyen@intel.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] [PATCH net-next 12/15] iavf: Log info when VF is entering and leaving Allmulti mode
Date: Fri,  4 Jun 2021 09:53:32 -0700	[thread overview]
Message-ID: <20210604165335.33329-12-anthony.l.nguyen@intel.com> (raw)
In-Reply-To: <20210604165335.33329-1-anthony.l.nguyen@intel.com>

From: Grzegorz Szczurek <grzegorzx.szczurek@intel.com>

Add log when VF is entering and leaving Allmulti mode.
The change of VF state is visible in dmesg now.
Without this commit, entering and leaving Allmulti mode
is not logged in dmesg.

Signed-off-by: Grzegorz Szczurek <grzegorzx.szczurek@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
---
 .../net/ethernet/intel/iavf/iavf_virtchnl.c   | 20 +++++++++++++------
 1 file changed, 14 insertions(+), 6 deletions(-)

diff --git a/drivers/net/ethernet/intel/iavf/iavf_virtchnl.c b/drivers/net/ethernet/intel/iavf/iavf_virtchnl.c
index 3c3fd604218e..d78206e168bc 100644
--- a/drivers/net/ethernet/intel/iavf/iavf_virtchnl.c
+++ b/drivers/net/ethernet/intel/iavf/iavf_virtchnl.c
@@ -711,15 +711,23 @@ void iavf_set_promiscuous(struct iavf_adapter *adapter, int flags)
 	if (flags & FLAG_VF_MULTICAST_PROMISC) {
 		adapter->flags |= IAVF_FLAG_ALLMULTI_ON;
 		adapter->aq_required &= ~IAVF_FLAG_AQ_REQUEST_ALLMULTI;
-		dev_info(&adapter->pdev->dev, "Entering multicast promiscuous mode\n");
+		dev_info(&adapter->pdev->dev, "%s is entering multicast promiscuous mode\n",
+			 adapter->netdev->name);
 	}
 
 	if (!flags) {
-		adapter->flags &= ~(IAVF_FLAG_PROMISC_ON |
-				    IAVF_FLAG_ALLMULTI_ON);
-		adapter->aq_required &= ~(IAVF_FLAG_AQ_RELEASE_PROMISC |
-					  IAVF_FLAG_AQ_RELEASE_ALLMULTI);
-		dev_info(&adapter->pdev->dev, "Leaving promiscuous mode\n");
+		if (adapter->flags & IAVF_FLAG_PROMISC_ON) {
+			adapter->flags &= ~IAVF_FLAG_PROMISC_ON;
+			adapter->aq_required &= ~IAVF_FLAG_AQ_RELEASE_PROMISC;
+			dev_info(&adapter->pdev->dev, "Leaving promiscuous mode\n");
+		}
+
+		if (adapter->flags & IAVF_FLAG_ALLMULTI_ON) {
+			adapter->flags &= ~IAVF_FLAG_ALLMULTI_ON;
+			adapter->aq_required &= ~IAVF_FLAG_AQ_RELEASE_ALLMULTI;
+			dev_info(&adapter->pdev->dev, "%s is leaving multicast promiscuous mode\n",
+				 adapter->netdev->name);
+		}
 	}
 
 	adapter->current_op = VIRTCHNL_OP_CONFIG_PROMISCUOUS_MODE;
-- 
2.20.1


  parent reply	other threads:[~2021-06-04 16:53 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-04 16:53 [Intel-wired-lan] [PATCH net-next 01/15] iavf: correctly track whether the interface is running during resets Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 02/15] iavf: obtain the crit_section lock in iavf_open() immediately Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 03/15] iavf: obtain crit_section lock in iavf_close() immediately Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 04/15] iavf: wrap driver state change in crit_section lock Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 05/15] iavf: untangle any pending iavf_open() operations from iavf_close() Tony Nguyen
2021-06-10  6:14   ` Stefan Assmann
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 06/15] iavf: disable interrupts before disabling napi Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 07/15] iavf: Restore non MAC filters after link down Tony Nguyen
2021-11-02 16:36   ` Kuruvinakunnel, George
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 08/15] iavf: restore MSI state on reset Tony Nguyen
2021-11-03 19:41   ` Kuruvinakunnel, George
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 09/15] iavf: Fix carrier on state Tony Nguyen
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 10/15] iavf: Add change MTU message Tony Nguyen
2021-11-02  0:34   ` Kuruvinakunnel, George
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 11/15] iavf: Prevent changing static ITR values if adaptive moderation is on Tony Nguyen
2021-11-02  0:21   ` Kuruvinakunnel, George
2021-06-04 16:53 ` Tony Nguyen [this message]
2021-11-02  0:47   ` [Intel-wired-lan] [PATCH net-next 12/15] iavf: Log info when VF is entering and leaving Allmulti mode Kuruvinakunnel, George
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 13/15] iavf: Set RSS LUT and key in reset handle path Tony Nguyen
2021-08-06  7:26   ` Jankowski, Konrad0
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 14/15] iavf: return errno code instead of status code Tony Nguyen
2021-11-17 10:27   ` Jankowski, Konrad0
2021-06-04 16:53 ` [Intel-wired-lan] [PATCH net-next 15/15] iavf: don't be so alarming Tony Nguyen
2021-11-03 19:45   ` Kuruvinakunnel, George

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=20210604165335.33329-12-anthony.l.nguyen@intel.com \
    --to=anthony.l.nguyen@intel.com \
    --cc=intel-wired-lan@osuosl.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.