On Thu, Jul 18, 2024 at 3:12 PM Ilya Maximets <[email protected]> wrote: > > There are two types of netlink notifier callbacks: nln_notify_func and > rtnetlink_notify_func. The rtnetlink_notify_func is only registered > via rtnetlink_notifier_create(), so there is no real case where we > could use the wrong function pointer. But UBsan in Clang 17 complains > that the function pointer type is not exactly the same: > > lib/netlink-notifier.c:237:13: runtime error: call to function > name_table_change through pointer to incorrect function type > 'void (*)(const void *, void *)' > > lib/route-table.c:406: note: name_table_change defined here > 0 0xf65ed7 in nln_report lib/netlink-notifier.c:237:13 > 1 0xf64e2e in nln_run lib/netlink-notifier.c > 2 0x50d4f2 in bridge_run vswitchd/bridge.c:3373:5 > 3 0x547c55 in main vswitchd/ovs-vswitchd.c:137:9 > 4 0x7f8149 in __libc_start_call_main > 5 0x7f820a in __libc_start_main@GLIBC_2.2.5 > 6 0x42dfd4 in _start (vswitchd/ovs-vswitchd+0x42dfd4) > > Turn off function sanitizing for nln_report() the same as we do for > RCU callbacks to avoid runtime errors with UBsan enabled. > > Reproduced with OVN test suite running multiple tests in parallel. > > Signed-off-by: Ilya Maximets <[email protected]>
Acked-by: Mike Pattrick <[email protected]> _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
