Skip to contentSkip to conversation

devlink: Fix setting max_io_eqs as the sole attribute

PATCH Applied Parav Pandit 2 participants 3 messages Jun 6, 2024 – Jun 11, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 devlink: Fix setting max_io_eqs as the sole attribute

dl_opts_put() function missed to consider IO eqs option flag. Due to this, when max_io_eqs setting is applied only when it is combined with other attributes such as roce/hw_addr. When max_io_eqs is the only attribute set, it missed to apply the attribute.

Fix it by adding the missing flag.

Fixes e8add23c59b7 ("devlink: Support setting max_io_eqs")
---
 devlink/devlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
devlink/devlink.c +1 -1
index 03d27202..3ab5a85d 100644
@@ -2637,7 +2637,7 @@ static void dl_opts_put(struct nlmsghdr *nlh, struct dl *dl)
 		mnl_attr_put_u64(nlh, DEVLINK_ATTR_TRAP_POLICER_BURST,
 				 opts->trap_policer_burst);
 	if (opts->present & (DL_OPT_PORT_FUNCTION_HW_ADDR | DL_OPT_PORT_FUNCTION_STATE |
-			     DL_OPT_PORT_FN_CAPS))
+			     DL_OPT_PORT_FN_CAPS | DL_OPT_PORT_FN_MAX_IO_EQS))
 		dl_function_attr_put(nlh, opts);
 	if (opts->present & DL_OPT_PORT_FLAVOUR)
 		mnl_attr_put_u16(nlh, DEVLINK_ATTR_PORT_FLAVOUR, opts->port_flavour);
Signature · 1 line
2.26.2
#1 lore raw
Quoted 10 lines

From: Parav Pandit <[email protected]>
Sent: Thursday, June 6, 2024 10:08 AM
To: [email protected]; [email protected]; [email protected]
Cc: Jiri Pirko <[email protected]>; Shay Drori <[email protected]>; Parav Pandit <[email protected]>
Subject: [PATCH net] devlink: Fix setting max_io_eqs as the sole attribute

I missed to include iproute2 in the subject prefix. :( Will avoid this mistake next time.

Quoted 33 lines

dl_opts_put() function missed to consider IO eqs option flag. Due to this, when max_io_eqs setting is applied only when it is combined with other attributes such as roce/hw_addr.
When max_io_eqs is the only attribute set, it missed to apply the attribute.

Fix it by adding the missing flag.

Fixes e8add23c59b7 ("devlink: Support setting max_io_eqs")
---
 devlink/devlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
devlink/devlink.c index 03d27202..3ab5a85d renamed from devlink/devlink.c +0 -0

100644

devlink/devlink.c +0 -0
@@ -2637,7 +2637,7 @@ static void dl_opts_put(struct nlmsghdr *nlh,
 struct dl *dl)
 		mnl_attr_put_u64(nlh,
 DEVLINK_ATTR_TRAP_POLICER_BURST,
 				 opts->trap_policer_burst);
 	if (opts->present & (DL_OPT_PORT_FUNCTION_HW_ADDR |

DL_OPT_PORT_FUNCTION_STATE |

devlink/devlink.c +1 -1
-			     DL_OPT_PORT_FN_CAPS))
+			     DL_OPT_PORT_FN_CAPS |

DL_OPT_PORT_FN_MAX_IO_EQS))

devlink/devlink.c +0 -0
 		dl_function_attr_put(nlh, opts);
 	if (opts->present & DL_OPT_PORT_FLAVOUR)
 		mnl_attr_put_u16(nlh, DEVLINK_ATTR_PORT_FLAVOUR,

opts->port_flavour);
--
2.26.2

#2 lore raw
In reply to Parav Pandit
This patch was applied to iproute2/iproute2.git (main) by Stephen Hemminger <[email protected]>:

Hello:

This patch was applied to iproute2/iproute2.git (main) by Stephen Hemminger <[email protected]>:

Quoted 9 lines · On Thu, 6 Jun 2024 07:38:08 +0300 you wrote:

dl_opts_put() function missed to consider IO eqs option flag. Due to this, when max_io_eqs setting is applied only when it is combined with other attributes such as roce/hw_addr. When max_io_eqs is the only attribute set, it missed to apply the attribute.

Fix it by adding the missing flag.

[...]

Here is the summary with links:
- [net] devlink: Fix setting max_io_eqs as the sole attribute

    https://git.kernel.org/pub/scm/network/iproute2/iproute2.git/commit/?id=c6c39f3c6da4

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html