Intel-Wired-Lan Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Mikailenko <benjamin.mikailenko@intel.com>
To: intel-wired-lan@lists.osuosl.org
Cc: Benjamin Mikailenko <benjamin.mikailenko@intel.com>
Subject: [Intel-wired-lan] [PATCH net v4] ice: Fix VSI configuration for non-PF network devices
Date: Tue, 12 Jul 2022 11:14:22 -0400	[thread overview]
Message-ID: <20220712151422.50489-1-benjamin.mikailenko@intel.com> (raw)

This fixes an issue for a failing loopback test
"ethtool -t offline ethx". Do not set Rx mode
and VSI VLAN for non-PF network devices.

Fixes: c7f2c42b80ed ("ice: Fix a few null pointer dereference issues")
Signed-off-by: Benjamin Mikailenko <benjamin.mikailenko@intel.com>
---
 drivers/net/ethernet/intel/ice/ice_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
index 752bd8a10495..e4ae67da5b77 100644
--- a/drivers/net/ethernet/intel/ice/ice_main.c
+++ b/drivers/net/ethernet/intel/ice/ice_main.c
@@ -6010,7 +6010,7 @@ int ice_vsi_cfg(struct ice_vsi *vsi)
 {
 	int err;
 
-	if (vsi->netdev) {
+	if (vsi->netdev && vsi->type == ICE_VSI_PF) {
 		ice_set_rx_mode(vsi->netdev);
 
 		err = ice_vsi_vlan_setup(vsi);
-- 
2.34.3

_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan

             reply	other threads:[~2022-07-12 17:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-12 15:14 Benjamin Mikailenko [this message]
2022-07-14 20:50 ` [Intel-wired-lan] [PATCH net v4] ice: Fix VSI configuration for non-PF network devices Tony Nguyen
2022-07-14 21:11   ` Benjamin Mikailenko
2022-07-14 21:15     ` Tony Nguyen

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=20220712151422.50489-1-benjamin.mikailenko@intel.com \
    --to=benjamin.mikailenko@intel.com \
    --cc=intel-wired-lan@lists.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox