Intel-Wired-Lan Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Wojciech Drewek <wojciech.drewek@intel.com>
To: Ivan Vecera <ivecera@redhat.com>, <netdev@vger.kernel.org>
Cc: intel-wired-lan@lists.osuosl.org,
	Jesse Brandeburg <jesse.brandeburg@intel.com>,
	linux-kernel@vger.kernel.org, Eric Dumazet <edumazet@google.com>,
	Tony Nguyen <anthony.l.nguyen@intel.com>,
	Simon Horman <horms@kernel.org>,
	Jacob Keller <jacob.e.keller@intel.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	"David S. Miller" <davem@davemloft.net>
Subject: Re: [Intel-wired-lan] [PATCH iwl-next 1/5] i40e: Use existing helper to find flow director VSI
Date: Mon, 13 Nov 2023 14:09:26 +0100	[thread overview]
Message-ID: <2e6ecdf9-1608-4e51-a17c-8c136e14a9ba@intel.com> (raw)
In-Reply-To: <20231113125856.346047-2-ivecera@redhat.com>



On 13.11.2023 13:58, Ivan Vecera wrote:
> Use existing i40e_find_vsi_by_type() to find a VSI
> associated with flow director.
> 
> Signed-off-by: Ivan Vecera <ivecera@redhat.com>
> ---

Thanks Ivan, nice cleanup
Reviewed-by: Wojciech Drewek <wojciech.drewek@intel.com>

>  drivers/net/ethernet/intel/i40e/i40e_main.c | 11 ++++-------
>  1 file changed, 4 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
> index 51ee870ffa36..90966878333c 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_main.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
> @@ -15645,6 +15645,7 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
>  #ifdef CONFIG_I40E_DCB
>  	enum i40e_get_fw_lldp_status_resp lldp_status;
>  #endif /* CONFIG_I40E_DCB */
> +	struct i40e_vsi *vsi;
>  	struct i40e_pf *pf;
>  	struct i40e_hw *hw;
>  	u16 wol_nvm_bits;
> @@ -15655,7 +15656,6 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
>  #endif /* CONFIG_I40E_DCB */
>  	int err;
>  	u32 val;
> -	u32 i;
>  
>  	err = pci_enable_device_mem(pdev);
>  	if (err)
> @@ -16005,12 +16005,9 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
>  	INIT_LIST_HEAD(&pf->vsi[pf->lan_vsi]->ch_list);
>  
>  	/* if FDIR VSI was set up, start it now */
> -	for (i = 0; i < pf->num_alloc_vsi; i++) {
> -		if (pf->vsi[i] && pf->vsi[i]->type == I40E_VSI_FDIR) {
> -			i40e_vsi_open(pf->vsi[i]);
> -			break;
> -		}
> -	}
> +	vsi = i40e_find_vsi_by_type(pf, I40E_VSI_FDIR);
> +	if (vsi)
> +		i40e_vsi_open(vsi);
>  
>  	/* The driver only wants link up/down and module qualification
>  	 * reports from firmware.  Note the negative logic.
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan

  reply	other threads:[~2023-11-13 13:09 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-13 12:58 [Intel-wired-lan] [PATCH iwl-next 0/5] i40e: Simplify VSI and VEB handling Ivan Vecera
2023-11-13 12:58 ` [Intel-wired-lan] [PATCH iwl-next 1/5] i40e: Use existing helper to find flow director VSI Ivan Vecera
2023-11-13 13:09   ` Wojciech Drewek [this message]
2023-11-13 12:58 ` [Intel-wired-lan] [PATCH iwl-next 2/5] i40e: Introduce and use macros for iterating VSIs and VEBs Ivan Vecera
2023-11-13 13:21   ` Wojciech Drewek
2023-11-13 12:58 ` [Intel-wired-lan] [PATCH iwl-next 3/5] i40e: Add helpers to find VSI and VEB by SEID and use them Ivan Vecera
2023-11-13 13:27   ` Wojciech Drewek
2023-11-15 17:01     ` Ivan Vecera
2023-11-16 12:37       ` Wojciech Drewek
2023-11-16 13:59         ` Ivan Vecera
2023-11-16 14:21           ` Wojciech Drewek
2023-11-16 14:46             ` Ivan Vecera
2023-11-13 12:58 ` [Intel-wired-lan] [PATCH iwl-next 4/5] i40e: Fix broken support for floating VEBs Ivan Vecera
2023-11-14 13:21   ` Wojciech Drewek
2023-11-13 12:58 ` [Intel-wired-lan] [PATCH iwl-next 5/5] i40e: Remove VEB recursion Ivan Vecera
2023-11-16 14:20   ` Wojciech Drewek

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=2e6ecdf9-1608-4e51-a17c-8c136e14a9ba@intel.com \
    --to=wojciech.drewek@intel.com \
    --cc=anthony.l.nguyen@intel.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=ivecera@redhat.com \
    --cc=jacob.e.keller@intel.com \
    --cc=jesse.brandeburg@intel.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.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