mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-24 05:29:04 -04:00
netfilter: xtables: generate initial table on-demand
The static initial tables are pretty large, and after the net namespace has been instantiated, they just hang around for nothing. This commit removes them and creates tables on-demand at runtime when needed. Size shrinks by 7735 bytes (x86_64). Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
This commit is contained in:
parent
2b95efe7f6
commit
e3eaa9910b
18 changed files with 141 additions and 334 deletions
|
|
@ -258,6 +258,7 @@ struct arpt_error {
|
|||
.target.errorname = "ERROR", \
|
||||
}
|
||||
|
||||
extern void *arpt_alloc_initial_table(const struct xt_table *);
|
||||
extern struct xt_table *arpt_register_table(struct net *net,
|
||||
const struct xt_table *table,
|
||||
const struct arpt_replace *repl);
|
||||
|
|
|
|||
|
|
@ -282,6 +282,7 @@ struct ipt_error {
|
|||
.target.errorname = "ERROR", \
|
||||
}
|
||||
|
||||
extern void *ipt_alloc_initial_table(const struct xt_table *);
|
||||
extern unsigned int ipt_do_table(struct sk_buff *skb,
|
||||
unsigned int hook,
|
||||
const struct net_device *in,
|
||||
|
|
|
|||
|
|
@ -297,6 +297,7 @@ ip6t_get_target(struct ip6t_entry *e)
|
|||
#include <linux/init.h>
|
||||
extern void ip6t_init(void) __init;
|
||||
|
||||
extern void *ip6t_alloc_initial_table(const struct xt_table *);
|
||||
extern struct xt_table *ip6t_register_table(struct net *net,
|
||||
const struct xt_table *table,
|
||||
const struct ip6t_replace *repl);
|
||||
|
|
|
|||
Loading…
Reference in a new issue