WSL2-Linux-Kernel/net/netlink
Pedro Tammela 7dc379f885 net/netlink: fix NETLINK_LIST_MEMBERSHIPS length report
[ Upstream commit f4e4534850 ]

The current code for the length calculation wrongly truncates the reported
length of the groups array, causing an under report of the subscribed
groups. To fix this, use 'BITS_TO_BYTES()' which rounds up the
division by 8.

Fixes: b42be38b27 ("netlink: add API to retrieve all group memberships")
Signed-off-by: Pedro Tammela <pctammela@mojatatu.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Link: https://lore.kernel.org/r/20230529153335.389815-1-pctammela@mojatatu.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-06-09 10:32:18 +02:00
..
Kconfig
Makefile
af_netlink.c net/netlink: fix NETLINK_LIST_MEMBERSHIPS length report 2023-06-09 10:32:18 +02:00
af_netlink.h
diag.c
genetlink.c net: genl: fix error path memory leak in policy dumping 2022-08-25 11:40:25 +02:00
policy.c net: genl: fix error path memory leak in policy dumping 2022-08-25 11:40:25 +02:00