diff options
Diffstat (limited to 'net/ipv4/fib_trie.c')
-rw-r--r-- | net/ipv4/fib_trie.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c index f155a66d6ebf..6009df238ed9 100644 --- a/net/ipv4/fib_trie.c +++ b/net/ipv4/fib_trie.c | |||
@@ -2251,18 +2251,7 @@ static int fib_triestat_seq_show(struct seq_file *seq, void *v) | |||
2251 | 2251 | ||
2252 | static int fib_triestat_seq_open(struct inode *inode, struct file *file) | 2252 | static int fib_triestat_seq_open(struct inode *inode, struct file *file) |
2253 | { | 2253 | { |
2254 | int err; | 2254 | return single_open_net(inode, file, fib_triestat_seq_show); |
2255 | struct net *net; | ||
2256 | |||
2257 | net = get_proc_net(inode); | ||
2258 | if (net == NULL) | ||
2259 | return -ENXIO; | ||
2260 | err = single_open(file, fib_triestat_seq_show, net); | ||
2261 | if (err < 0) { | ||
2262 | put_net(net); | ||
2263 | return err; | ||
2264 | } | ||
2265 | return 0; | ||
2266 | } | 2255 | } |
2267 | 2256 | ||
2268 | static int fib_triestat_seq_release(struct inode *ino, struct file *f) | 2257 | static int fib_triestat_seq_release(struct inode *ino, struct file *f) |