浏览代码

net: ipmr: drop ip_mr_init() mrt_cachep null check as we'll panic if it fails

It's not necessary to check for null as SLAB_PANIC is used and we'll
panic if the alloc fails, so just drop it.

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Nikolay Aleksandrov 9 年之前
父节点
当前提交
af623236a9
共有 1 个文件被更改,包括 0 次插入2 次删除
  1. 0 2
      net/ipv4/ipmr.c

+ 0 - 2
net/ipv4/ipmr.c

@@ -2677,8 +2677,6 @@ int __init ip_mr_init(void)
 				       sizeof(struct mfc_cache),
 				       0, SLAB_HWCACHE_ALIGN | SLAB_PANIC,
 				       NULL);
-	if (!mrt_cachep)
-		return -ENOMEM;
 
 	err = register_pernet_subsys(&ipmr_net_ops);
 	if (err)