]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
netfilter: remove messages print and boot/module load time
authorPablo Neira Ayuso <pablo@netfilter.org>
Fri, 19 Jan 2018 12:35:40 +0000 (13:35 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Fri, 19 Jan 2018 17:39:49 +0000 (18:39 +0100)
Several reasons for this:

* Several modules maintain internal version numbers, that they print at
  boot/module load time, that are not exposed to userspace, as a
  primitive mechanism to make revision number control from the earlier
  days of Netfilter.

* IPset shows the protocol version at boot/module load time, instead
  display this via module description, as Jozsef suggested.

* Remove copyright notice at boot/module load time in two spots, the
  Netfilter codebase is a collective development effort, if we would
  have to display copyrights for each contributor at boot/module load
  time for each extensions we have, we would probably fill up logs with
  lots of useless information - from a technical standpoint.

So let's be consistent and remove them all.

Acked-by: Florian Westphal <fw@strlen.de>
Acked-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
12 files changed:
net/bridge/netfilter/ebtables.c
net/ipv4/netfilter/arp_tables.c
net/ipv4/netfilter/ip_tables.c
net/ipv6/netfilter/ip6_tables.c
net/netfilter/ipset/ip_set_core.c
net/netfilter/nf_conntrack_core.c
net/netfilter/nf_conntrack_netlink.c
net/netfilter/nf_tables_api.c
net/netfilter/nfnetlink.c
net/netfilter/nfnetlink_acct.c
net/netfilter/nfnetlink_cttimeout.c
net/netfilter/nft_compat.c

index 37817d25b63d71eaaf0ee8081d705d649c1b8d9c..02c4b409d31733c6192110139570e48980aa1740 100644 (file)
@@ -2445,7 +2445,6 @@ static int __init ebtables_init(void)
                return ret;
        }
 
-       printk(KERN_INFO "Ebtables v2.0 registered\n");
        return 0;
 }
 
@@ -2453,7 +2452,6 @@ static void __exit ebtables_fini(void)
 {
        nf_unregister_sockopt(&ebt_sockopts);
        xt_unregister_target(&ebt_standard_target);
-       printk(KERN_INFO "Ebtables v2.0 unregistered\n");
 }
 
 EXPORT_SYMBOL(ebt_register_table);
index bf8a5340f15e88a9e2ce9e6a91627d2c7e67ed2e..5f7c0d643fb3ffdeee429f321abba892b6e94cb8 100644 (file)
@@ -1656,7 +1656,6 @@ static int __init arp_tables_init(void)
        if (ret < 0)
                goto err4;
 
-       pr_info("arp_tables: (C) 2002 David S. Miller\n");
        return 0;
 
 err4:
index 0b975aa2d363828fba1db5c55a3ce904215a7a7e..1f534aec22f0e3824a6dadbaa1f7789ecc6cffbf 100644 (file)
@@ -1939,7 +1939,6 @@ static int __init ip_tables_init(void)
        if (ret < 0)
                goto err5;
 
-       pr_info("(C) 2000-2006 Netfilter Core Team\n");
        return 0;
 
 err5:
index 6ebbef2dfb60acbea1bad05cf67a4a09e6220f6c..37fa76ee513035dc1303826567d8f5607fa912aa 100644 (file)
@@ -1952,7 +1952,6 @@ static int __init ip6_tables_init(void)
        if (ret < 0)
                goto err5;
 
-       pr_info("(C) 2000-2006 Netfilter Core Team\n");
        return 0;
 
 err5:
index 728bf31bb386f17b9b980690559980aa0a4a40a6..975a85a48d39fad1bf8fb88046a0558e6017af62 100644 (file)
@@ -2122,7 +2122,6 @@ ip_set_init(void)
                return ret;
        }
 
-       pr_info("ip_set: protocol %u\n", IPSET_PROTOCOL);
        return 0;
 }
 
@@ -2138,3 +2137,5 @@ ip_set_fini(void)
 
 module_init(ip_set_init);
 module_exit(ip_set_fini);
+
+MODULE_DESCRIPTION("ip_set: protocol " __stringify(IPSET_PROTOCOL));
index 6a64d528d0765ab5646211344350e23ea08511e5..3d72a0842c01aa6adc10f1d00a4808126153464e 100644 (file)
@@ -58,8 +58,6 @@
 
 #include "nf_internals.h"
 
-#define NF_CONNTRACK_VERSION   "0.5.0"
-
 int (*nfnetlink_parse_nat_setup_hook)(struct nf_conn *ct,
                                      enum nf_nat_manip_type manip,
                                      const struct nlattr *attr) __read_mostly;
@@ -2068,10 +2066,6 @@ int nf_conntrack_init_start(void)
        if (!nf_conntrack_cachep)
                goto err_cachep;
 
-       printk(KERN_INFO "nf_conntrack version %s (%u buckets, %d max)\n",
-              NF_CONNTRACK_VERSION, nf_conntrack_htable_size,
-              nf_conntrack_max);
-
        ret = nf_conntrack_expect_init();
        if (ret < 0)
                goto err_expect;
index 7c7921a53b13c1540f0d78262ba9118b21d6d9b9..dd177ebee9aabcbe47e704e9d4e424f1b718b89f 100644 (file)
@@ -57,8 +57,6 @@
 
 MODULE_LICENSE("GPL");
 
-static char __initdata version[] = "0.93";
-
 static int ctnetlink_dump_tuples_proto(struct sk_buff *skb,
                                const struct nf_conntrack_tuple *tuple,
                                const struct nf_conntrack_l4proto *l4proto)
@@ -3425,7 +3423,6 @@ static int __init ctnetlink_init(void)
 {
        int ret;
 
-       pr_info("ctnetlink v%s: registering with nfnetlink.\n", version);
        ret = nfnetlink_subsys_register(&ctnl_subsys);
        if (ret < 0) {
                pr_err("ctnetlink_init: cannot register with nfnetlink.\n");
@@ -3459,8 +3456,6 @@ err_out:
 
 static void __exit ctnetlink_exit(void)
 {
-       pr_info("ctnetlink: unregistering from nfnetlink.\n");
-
        unregister_pernet_subsys(&ctnetlink_net_ops);
        nfnetlink_subsys_unregister(&ctnl_exp_subsys);
        nfnetlink_subsys_unregister(&ctnl_subsys);
index f87314c6dcc45743e503ee4ef3b1eecf62dd9756..0791813a1e7d34764a0dc557e59801b3274265d6 100644 (file)
@@ -6603,7 +6603,6 @@ static int __init nf_tables_module_init(void)
 
        register_netdevice_notifier(&nf_tables_flowtable_notifier);
 
-       pr_info("nf_tables: (c) 2007-2009 Patrick McHardy <kaber@trash.net>\n");
        return register_pernet_subsys(&nf_tables_net_ops);
 err3:
        nf_tables_core_module_exit();
index 733d3e4a30d85d0bfe5656c1e99a24c01b0fabec..03ead8a9e90ccfcc1936ee66064269dec4719fbd 100644 (file)
@@ -37,8 +37,6 @@ MODULE_ALIAS_NET_PF_PROTO(PF_NETLINK, NETLINK_NETFILTER);
        rcu_dereference_protected(table[(id)].subsys, \
                                  lockdep_nfnl_is_held((id)))
 
-static char __initdata nfversion[] = "0.30";
-
 static struct {
        struct mutex                            mutex;
        const struct nfnetlink_subsystem __rcu  *subsys;
@@ -580,13 +578,11 @@ static int __init nfnetlink_init(void)
        for (i=0; i<NFNL_SUBSYS_COUNT; i++)
                mutex_init(&table[i].mutex);
 
-       pr_info("Netfilter messages via NETLINK v%s.\n", nfversion);
        return register_pernet_subsys(&nfnetlink_net_ops);
 }
 
 static void __exit nfnetlink_exit(void)
 {
-       pr_info("Removing netfilter NETLINK layer.\n");
        unregister_pernet_subsys(&nfnetlink_net_ops);
 }
 module_init(nfnetlink_init);
index c45e6d4358abe912d5a49efca4b183c6fbe21127..88d427f9f9e6a0f461527ad117a157f395982ea9 100644 (file)
@@ -527,7 +527,6 @@ static int __init nfnl_acct_init(void)
                goto err_out;
        }
 
-       pr_info("nfnl_acct: registering with nfnetlink.\n");
        ret = nfnetlink_subsys_register(&nfnl_acct_subsys);
        if (ret < 0) {
                pr_err("nfnl_acct_init: cannot register with nfnetlink.\n");
@@ -543,7 +542,6 @@ err_out:
 
 static void __exit nfnl_acct_exit(void)
 {
-       pr_info("nfnl_acct: unregistering from nfnetlink.\n");
        nfnetlink_subsys_unregister(&nfnl_acct_subsys);
        unregister_pernet_subsys(&nfnl_acct_ops);
 }
index 32b1c0b44e791552693b33f9d24dff8936164542..95b04702a655af03be4297b4a84cafb6dd618fc3 100644 (file)
@@ -615,8 +615,6 @@ err_out:
 
 static void __exit cttimeout_exit(void)
 {
-       pr_info("cttimeout: unregistering from nfnetlink.\n");
-
        nfnetlink_subsys_unregister(&cttimeout_subsys);
 
        unregister_pernet_subsys(&cttimeout_ops);
index 7fa17e241c145da71386079ce6c3f918fc58489d..8e23726b90810d3a7d49c145e5b735245d669b57 100644 (file)
@@ -812,8 +812,6 @@ static int __init nft_compat_module_init(void)
                goto err_target;
        }
 
-       pr_info("nf_tables_compat: (c) 2012 Pablo Neira Ayuso <pablo@netfilter.org>\n");
-
        return ret;
 
 err_target: