netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
To: intel-wired-lan@lists.osuosl.org
Cc: netdev@vger.kernel.org, jacob.e.keller@intel.com,
	michal.kubiak@intel.com, maciej.fijalkowski@intel.com,
	sridhar.samudrala@intel.com, przemyslaw.kitszel@intel.com,
	wojciech.drewek@intel.com, pio.raczynski@gmail.com,
	jiri@nvidia.com, mateusz.polchlopek@intel.com, shayd@nvidia.com
Subject: [iwl-next v1 04/14] ice: treat subfunction VSI the same as PF VSI
Date: Tue,  7 May 2024 13:45:05 +0200	[thread overview]
Message-ID: <20240507114516.9765-5-michal.swiatkowski@linux.intel.com> (raw)
In-Reply-To: <20240507114516.9765-1-michal.swiatkowski@linux.intel.com>

When subfunction VSI is open the same code as for PF VSI should be
executed. Also when up is complete. Reflect that in code by adding
subfunction VSI to consideration.

In case of stopping, PF doesn't have additional tasks, so the same
is with subfunction VSI.

Signed-off-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
---
 drivers/net/ethernet/intel/ice/ice_main.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
index 7033981666a7..fdfdb27476e5 100644
--- a/drivers/net/ethernet/intel/ice/ice_main.c
+++ b/drivers/net/ethernet/intel/ice/ice_main.c
@@ -6684,7 +6684,8 @@ static int ice_up_complete(struct ice_vsi *vsi)
 
 	if (vsi->port_info &&
 	    (vsi->port_info->phy.link_info.link_info & ICE_AQ_LINK_UP) &&
-	    ((vsi->netdev && vsi->type == ICE_VSI_PF))) {
+	    ((vsi->netdev && vsi->type == ICE_VSI_PF) ||
+	     (vsi->netdev && vsi->type == ICE_VSI_SF))) {
 		ice_print_link_msg(vsi, true);
 		netif_tx_start_all_queues(vsi->netdev);
 		netif_carrier_on(vsi->netdev);
@@ -7382,7 +7383,7 @@ int ice_vsi_open(struct ice_vsi *vsi)
 
 	ice_vsi_cfg_netdev_tc(vsi, vsi->tc_cfg.ena_tc);
 
-	if (vsi->type == ICE_VSI_PF) {
+	if (vsi->type == ICE_VSI_PF || vsi->type == ICE_VSI_SF) {
 		/* Notify the stack of the actual queue counts. */
 		err = netif_set_real_num_tx_queues(vsi->netdev, vsi->num_txq);
 		if (err)
-- 
2.42.0


  parent reply	other threads:[~2024-05-07 11:40 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-07 11:45 [iwl-next v1 00/14] ice: support devlink subfunction Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 01/14] ice: add new VSI type for subfunctions Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 02/14] ice: export ice ndo_ops functions Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 03/14] ice: add basic devlink subfunctions support Michal Swiatkowski
2024-05-09 11:06   ` Jiri Pirko
2024-05-10  7:13     ` Michal Swiatkowski
2024-05-10 11:05       ` Jiri Pirko
2024-05-10 12:25         ` Michal Swiatkowski
2024-05-07 11:45 ` Michal Swiatkowski [this message]
2024-05-07 11:45 ` [iwl-next v1 05/14] ice: allocate devlink for subfunction Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 06/14] ice: base subfunction aux driver Michal Swiatkowski
2024-05-09 11:13   ` Jiri Pirko
2024-05-10  7:20     ` Michal Swiatkowski
2024-05-10 11:06       ` Jiri Pirko
2024-05-07 11:45 ` [iwl-next v1 07/14] ice: implement netdev for subfunction Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 08/14] ice: create port representor for SF Michal Swiatkowski
2024-05-09 11:16   ` Jiri Pirko
2024-05-10  7:31     ` Michal Swiatkowski
2024-05-10 11:07       ` Jiri Pirko
2024-05-10 12:25         ` [Intel-wired-lan] " Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 09/14] ice: don't set target VSI for subfunction Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 10/14] ice: check if SF is ready in ethtool ops Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 11/14] ice: netdevice ops for SF representor Michal Swiatkowski
2024-05-09 11:17   ` Jiri Pirko
2024-05-10  7:25     ` Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 12/14] ice: support subfunction devlink Tx topology Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 13/14] ice: basic support for VLAN in subfunctions Michal Swiatkowski
2024-05-07 11:45 ` [iwl-next v1 14/14] ice: allow to activate and deactivate subfunction Michal Swiatkowski
2024-05-09 11:36   ` Jiri Pirko
2024-05-10  7:33     ` Michal Swiatkowski
2024-05-10 11:08       ` Jiri Pirko
2024-05-09 11:18 ` [iwl-next v1 00/14] ice: support devlink subfunction Jiri Pirko
2024-05-10  7:24   ` Michal Swiatkowski
2024-05-10 11:09     ` Jiri Pirko
2024-05-10 12:26       ` [Intel-wired-lan] " Michal Swiatkowski

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=20240507114516.9765-5-michal.swiatkowski@linux.intel.com \
    --to=michal.swiatkowski@linux.intel.com \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=jacob.e.keller@intel.com \
    --cc=jiri@nvidia.com \
    --cc=maciej.fijalkowski@intel.com \
    --cc=mateusz.polchlopek@intel.com \
    --cc=michal.kubiak@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=pio.raczynski@gmail.com \
    --cc=przemyslaw.kitszel@intel.com \
    --cc=shayd@nvidia.com \
    --cc=sridhar.samudrala@intel.com \
    --cc=wojciech.drewek@intel.com \
    /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;
as well as URLs for NNTP newsgroup(s).