Hi Florian, 2017-04-24 21:37 GMT+08:00 Florian Westphal <fw@xxxxxxxxx>: > nf_log_unregister() (which is what gets called in the logger backends > module exit paths) does a (required, module is removed) synchronize_rcu(). > > But nf_log_unset() is only called from pernet exit handlers. It doesn't > free any memory so there appears to be no need to call synchronize_rcu. If I did not miss something, maybe there's an exception here, in the nfnetlink_log.ko's module exit routine, nf_log_unregister is invoked before unregister_pernet_subsys, i.e. _log_unregister will be done before _log_unset. So removing the synchronize_rcu in _log_unset will become unsafe when uninstalling the nfnetlink_log.ko: static void __exit nfnetlink_log_fini(void) { nf_log_unregister(&nfulnl_logger); --> synchronize_rcu here. nfnetlink_subsys_unregister(&nfulnl_subsys); netlink_unregister_notifier(&nfulnl_rtnl_notifier); unregister_pernet_subsys(&nfnl_log_net_ops); --> _log_unset without synchronize_rcu. } So I think after dropping the synchronize_rcu in _log_unset, we should also put the "nf_log_unregister(&nfulnl_logger);" to the end, just like other nf_log_X modules do. -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html