netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH iwl-next] ixgbe: Enable XDP support when SRIOV is enabled
@ 2024-11-22 12:13 Martyna Szapar-Mudlaw
  2024-11-22 15:56 ` Fijalkowski, Maciej
  0 siblings, 1 reply; 3+ messages in thread
From: Martyna Szapar-Mudlaw @ 2024-11-22 12:13 UTC (permalink / raw)
  To: intel-wired-lan; +Cc: netdev, Martyna Szapar-Mudlaw, Przemek Kitszel

Remove the check that prevents XDP support when SRIOV is enabled.
There is no reason to completely forbid the user from using XDP
with SRIOV.

Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Signed-off-by: Martyna Szapar-Mudlaw <martyna.szapar-mudlaw@linux.intel.com>

---

Added CC netdev

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 459a539cf8db..a07e28107a42 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -10637,9 +10637,6 @@ static int ixgbe_xdp_setup(struct net_device *dev, struct bpf_prog *prog)
 	bool need_reset;
 	int num_queues;
 
-	if (adapter->flags & IXGBE_FLAG_SRIOV_ENABLED)
-		return -EINVAL;
-
 	if (adapter->flags & IXGBE_FLAG_DCB_ENABLED)
 		return -EINVAL;
 
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [PATCH iwl-next] ixgbe: Enable XDP support when SRIOV is enabled
  2024-11-22 12:13 [PATCH iwl-next] ixgbe: Enable XDP support when SRIOV is enabled Martyna Szapar-Mudlaw
@ 2024-11-22 15:56 ` Fijalkowski, Maciej
  2024-11-25 20:19   ` Szapar-Mudlaw, Martyna
  0 siblings, 1 reply; 3+ messages in thread
From: Fijalkowski, Maciej @ 2024-11-22 15:56 UTC (permalink / raw)
  To: Martyna Szapar-Mudlaw, intel-wired-lan@lists.osuosl.org
  Cc: netdev@vger.kernel.org, Kitszel, Przemyslaw

> 
> Remove the check that prevents XDP support when SRIOV is enabled.
> There is no reason to completely forbid the user from using XDP
> with SRIOV.

I think we need some more context here in commit message.
ixgbe HW was really short on HW queues that's why probably this restriction
was introduced in the first place.

Now I believe that driver has an ability to share XDP Tx resources with locking
being involved and that's why you can relax the previous limitation.

Correct?

> 
> Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
> Signed-off-by: Martyna Szapar-Mudlaw <martyna.szapar-
> mudlaw@linux.intel.com>
> 
> ---
> 
> Added CC netdev
> 
> ---
>  drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> index 459a539cf8db..a07e28107a42 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> @@ -10637,9 +10637,6 @@ static int ixgbe_xdp_setup(struct net_device
> *dev, struct bpf_prog *prog)
>  	bool need_reset;
>  	int num_queues;
> 
> -	if (adapter->flags & IXGBE_FLAG_SRIOV_ENABLED)
> -		return -EINVAL;
> -
>  	if (adapter->flags & IXGBE_FLAG_DCB_ENABLED)
>  		return -EINVAL;
> 
> --
> 2.36.1
> 


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH iwl-next] ixgbe: Enable XDP support when SRIOV is enabled
  2024-11-22 15:56 ` Fijalkowski, Maciej
@ 2024-11-25 20:19   ` Szapar-Mudlaw, Martyna
  0 siblings, 0 replies; 3+ messages in thread
From: Szapar-Mudlaw, Martyna @ 2024-11-25 20:19 UTC (permalink / raw)
  To: Fijalkowski, Maciej, intel-wired-lan@lists.osuosl.org
  Cc: netdev@vger.kernel.org, Kitszel, Przemyslaw


On 11/22/2024 4:56 PM, Fijalkowski, Maciej wrote:
>> Remove the check that prevents XDP support when SRIOV is enabled.
>> There is no reason to completely forbid the user from using XDP
>> with SRIOV.
> I think we need some more context here in commit message.
> ixgbe HW was really short on HW queues that's why probably this restriction
> was introduced in the first place.
>
> Now I believe that driver has an ability to share XDP Tx resources with locking
> being involved and that's why you can relax the previous limitation.
>
> Correct?

Right, ixgbe hardware has a limited number of hw queues. There is 
locking in place now. The reasoning behind this change is to give users 
the flexibility to use XDP with SRIOV, there may be use cases for such 
constrained scenarios, where this tradeoff is acceptable...

I'll update commit msg.

>
>> Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
>> Signed-off-by: Martyna Szapar-Mudlaw <martyna.szapar-
>> mudlaw@linux.intel.com>
>>
>> ---
>>
>> Added CC netdev
>>
>> ---
>>   drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 3 ---
>>   1 file changed, 3 deletions(-)
>>
>> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
>> b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
>> index 459a539cf8db..a07e28107a42 100644
>> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
>> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
>> @@ -10637,9 +10637,6 @@ static int ixgbe_xdp_setup(struct net_device
>> *dev, struct bpf_prog *prog)
>>   	bool need_reset;
>>   	int num_queues;
>>
>> -	if (adapter->flags & IXGBE_FLAG_SRIOV_ENABLED)
>> -		return -EINVAL;
>> -
>>   	if (adapter->flags & IXGBE_FLAG_DCB_ENABLED)
>>   		return -EINVAL;
>>
>> --
>> 2.36.1
>>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-11-25 20:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-22 12:13 [PATCH iwl-next] ixgbe: Enable XDP support when SRIOV is enabled Martyna Szapar-Mudlaw
2024-11-22 15:56 ` Fijalkowski, Maciej
2024-11-25 20:19   ` Szapar-Mudlaw, Martyna

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).