diff options
-rw-r--r-- | net/packet/af_packet.c | 2 | ||||
-rw-r--r-- | net/tls/tls_proc.c | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c index a667b19eab78..de8e8dbbdeb8 100644 --- a/net/packet/af_packet.c +++ b/net/packet/af_packet.c @@ -4629,9 +4629,11 @@ static int __net_init packet_net_init(struct net *net) mutex_init(&net->packet.sklist_lock); INIT_HLIST_HEAD(&net->packet.sklist); +#ifdef CONFIG_PROC_FS if (!proc_create_net("packet", 0, net->proc_net, &packet_seq_ops, sizeof(struct seq_net_private))) return -ENOMEM; +#endif /* CONFIG_PROC_FS */ return 0; } diff --git a/net/tls/tls_proc.c b/net/tls/tls_proc.c index 3a5dd1e07233..feeceb0e4cb4 100644 --- a/net/tls/tls_proc.c +++ b/net/tls/tls_proc.c @@ -37,9 +37,12 @@ static int tls_statistics_seq_show(struct seq_file *seq, void *v) int __net_init tls_proc_init(struct net *net) { +#ifdef CONFIG_PROC_FS if (!proc_create_net_single("tls_stat", 0444, net->proc_net, tls_statistics_seq_show, NULL)) return -ENOMEM; +#endif /* CONFIG_PROC_FS */ + return 0; } |