浏览代码

[NETFILTER]: xt_hashlimit: remove unneeded struct member

By allocating ->hinfo, we already have the needed indirection to cope
with the per-cpu xtables struct match_entry.

[Patrick: do this now before the revision 1 struct is used by userspace]

Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Jan Engelhardt 17 年之前
父节点
当前提交
7d9904c260
共有 2 个文件被更改,包括 0 次插入4 次删除
  1. 0 1
      include/linux/netfilter/xt_hashlimit.h
  2. 0 3
      net/netfilter/xt_hashlimit.c

+ 0 - 1
include/linux/netfilter/xt_hashlimit.h

@@ -61,7 +61,6 @@ struct xt_hashlimit_mtinfo1 {
 
 	/* Used internally by the kernel */
 	struct xt_hashlimit_htable *hinfo __attribute__((aligned(8)));
-	struct xt_hashlimit_mtinfo1 *master __attribute__((aligned(8)));
 };
 
 #endif /*_XT_HASHLIMIT_H*/

+ 0 - 3
net/netfilter/xt_hashlimit.c

@@ -774,9 +774,6 @@ hashlimit_mt_check(const char *tablename, const void *inf,
 		return false;
 	}
 	mutex_unlock(&hlimit_mutex);
-
-	/* Ugly hack: For SMP, we only want to use one set */
-	info->master = info;
 	return true;
 }