netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] netdevsim: add ipsec hw_features
@ 2025-10-15  8:36 Hangbin Liu
  2025-10-16 13:53 ` Sabrina Dubroca
  2025-10-16 22:50 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Hangbin Liu @ 2025-10-15  8:36 UTC (permalink / raw)
  To: netdev
  Cc: Jakub Kicinski, Andrew Lunn, David S. Miller, Eric Dumazet,
	Paolo Abeni, Hangbin Liu, Sabrina Dubroca

Currently, netdevsim only sets dev->features, which makes the ESP features
fixed. For example:

  # ethtool -k eni0np1 | grep esp
  tx-esp-segmentation: on [fixed]
  esp-hw-offload: on [fixed]
  esp-tx-csum-hw-offload: on [fixed]

This patch adds the ESP features to hw_features, allowing them to be
changed manually. For example:

  # ethtool -k eni0np1 | grep esp
  tx-esp-segmentation: on
  esp-hw-offload: on
  esp-tx-csum-hw-offload: on

Suggested-by: Sabrina Dubroca <sd@queasysnail.net>
Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
---
 drivers/net/netdevsim/ipsec.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/netdevsim/ipsec.c b/drivers/net/netdevsim/ipsec.c
index 47cdee5577d4..36a1be4923d6 100644
--- a/drivers/net/netdevsim/ipsec.c
+++ b/drivers/net/netdevsim/ipsec.c
@@ -277,6 +277,7 @@ void nsim_ipsec_init(struct netdevsim *ns)
 				 NETIF_F_GSO_ESP)
 
 	ns->netdev->features |= NSIM_ESP_FEATURES;
+	ns->netdev->hw_features |= NSIM_ESP_FEATURES;
 	ns->netdev->hw_enc_features |= NSIM_ESP_FEATURES;
 
 	ns->ipsec.pfile = debugfs_create_file("ipsec", 0400,
-- 
2.50.1


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

* Re: [PATCH net-next] netdevsim: add ipsec hw_features
  2025-10-15  8:36 [PATCH net-next] netdevsim: add ipsec hw_features Hangbin Liu
@ 2025-10-16 13:53 ` Sabrina Dubroca
  2025-10-16 22:50 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Sabrina Dubroca @ 2025-10-16 13:53 UTC (permalink / raw)
  To: Hangbin Liu
  Cc: netdev, Jakub Kicinski, Andrew Lunn, David S. Miller,
	Eric Dumazet, Paolo Abeni

2025-10-15, 08:36:49 +0000, Hangbin Liu wrote:
> Currently, netdevsim only sets dev->features, which makes the ESP features
> fixed. For example:
> 
>   # ethtool -k eni0np1 | grep esp
>   tx-esp-segmentation: on [fixed]
>   esp-hw-offload: on [fixed]
>   esp-tx-csum-hw-offload: on [fixed]
> 
> This patch adds the ESP features to hw_features, allowing them to be
> changed manually. For example:
> 
>   # ethtool -k eni0np1 | grep esp
>   tx-esp-segmentation: on
>   esp-hw-offload: on
>   esp-tx-csum-hw-offload: on
> 
> Suggested-by: Sabrina Dubroca <sd@queasysnail.net>
> Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>

Reviewed-by: Sabrina Dubroca <sd@queasysnail.net>

Thanks Hangbin.

-- 
Sabrina

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

* Re: [PATCH net-next] netdevsim: add ipsec hw_features
  2025-10-15  8:36 [PATCH net-next] netdevsim: add ipsec hw_features Hangbin Liu
  2025-10-16 13:53 ` Sabrina Dubroca
@ 2025-10-16 22:50 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-10-16 22:50 UTC (permalink / raw)
  To: Hangbin Liu; +Cc: netdev, kuba, andrew+netdev, davem, edumazet, pabeni, sd

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Wed, 15 Oct 2025 08:36:49 +0000 you wrote:
> Currently, netdevsim only sets dev->features, which makes the ESP features
> fixed. For example:
> 
>   # ethtool -k eni0np1 | grep esp
>   tx-esp-segmentation: on [fixed]
>   esp-hw-offload: on [fixed]
>   esp-tx-csum-hw-offload: on [fixed]
> 
> [...]

Here is the summary with links:
  - [net-next] netdevsim: add ipsec hw_features
    https://git.kernel.org/netdev/net-next/c/38c31c2620de

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2025-10-16 22:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-15  8:36 [PATCH net-next] netdevsim: add ipsec hw_features Hangbin Liu
2025-10-16 13:53 ` Sabrina Dubroca
2025-10-16 22:50 ` patchwork-bot+netdevbpf

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