mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-10 20:48:12 +00:00
netlink: specs: devlink: fix resource-scope type
The correct type for resource-scope is flags, not enum: - DEVLINK_RESOURCE_SCOPE_DEV is _BITUL(0) aka. 1, not 0. - DEVLINK_RESOURCE_SCOPE_PORT is _BITUL(1) aka. 2, not 1. This patch also removes "enum-as-flags", as it is now redundant, these changes does not change the generated policy. Before this patch, this generated devlink-user.c function call: devlink_resource_scope_str(DEVLINK_RESOURCE_SCOPE_DEV) returned "port", not "dev", as it didn't use ffs() to convert the value. CC: Jiri Pirko <jiri@resnulli.us> CC: Tariq Toukan <tariqt@nvidia.com> Reviewed-by: Moshe Shemesh <moshe@nvidia.com> Reviewed-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Asbjørn Sloth Tønnesen <ast@fiberby.net> Reviewed-by: Hangbin Liu <liuhangbin@kylinos.cn> Link: https://patch.msgid.link/20260925213918.204767-5-ast@fiberby.net Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
parent
306df818cc
commit
bef8442f5f
1 changed files with 1 additions and 2 deletions
Loading…
Add table
Add a link
Reference in a new issue