Commit 277aa23
CKI Backport Bot
netlink: correct nlmsg size for multicast notifications
JIRA: https://issues.redhat.com/browse/RHEL-84540
commit aa4ad7c
Author: Yuyang Huang <yuyanghuang@google.com>
Date: Sat Dec 21 19:00:07 2024 +0900
netlink: correct nlmsg size for multicast notifications
Corrected the netlink message size calculation for multicast group
join/leave notifications. The previous calculation did not account for
the inclusion of both IPv4/IPv6 addresses and ifa_cacheinfo in the
payload. This fix ensures that the allocated message size is
sufficient to hold all necessary information.
This patch also includes the following improvements:
* Uses GFP_KERNEL instead of GFP_ATOMIC when holding the RTNL mutex.
* Uses nla_total_size(sizeof(struct in6_addr)) instead of
nla_total_size(16).
* Removes unnecessary EXPORT_SYMBOL().
Fixes: 2c2b61d ("netlink: add IGMP/MLD join/leave notifications")
Cc: Maciej Żenczykowski <maze@google.com>
Cc: Lorenzo Colitti <lorenzo@google.com>
Signed-off-by: Yuyang Huang <yuyanghuang@google.com>
Link: https://patch.msgid.link/20241221100007.1910089-1-yuyanghuang@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: CKI Backport Bot <cki-ci-bot+cki-gitlab-backport-bot@redhat.com>1 parent 36fdf8d commit 277aa23
3 files changed
+8
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1473 | 1473 | | |
1474 | 1474 | | |
1475 | 1475 | | |
1476 | | - | |
| 1476 | + | |
| 1477 | + | |
| 1478 | + | |
1477 | 1479 | | |
1478 | 1480 | | |
1479 | 1481 | | |
| |||
1484 | 1486 | | |
1485 | 1487 | | |
1486 | 1488 | | |
1487 | | - | |
| 1489 | + | |
1488 | 1490 | | |
1489 | 1491 | | |
1490 | 1492 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5242 | 5242 | | |
5243 | 5243 | | |
5244 | 5244 | | |
5245 | | - | |
5246 | 5245 | | |
5247 | 5246 | | |
5248 | 5247 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
920 | 920 | | |
921 | 921 | | |
922 | 922 | | |
923 | | - | |
| 923 | + | |
| 924 | + | |
| 925 | + | |
924 | 926 | | |
925 | 927 | | |
926 | 928 | | |
| |||
931 | 933 | | |
932 | 934 | | |
933 | 935 | | |
934 | | - | |
| 936 | + | |
935 | 937 | | |
936 | 938 | | |
937 | 939 | | |
| |||
0 commit comments