Re: [PATCH 04/15] br_netfilter: switch sysctl nf_call_iptables to init_brnf_net

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Vasily Averin schreef op 9/05/2014 23:27:

Signed-off-by: Vasily Averin <vvs@xxxxxxxxxx>
---
  net/bridge/br_netfilter.c |    6 ++----
  1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/net/bridge/br_netfilter.c b/net/bridge/br_netfilter.c
index 2b0dda80..cb75e80 100644
--- a/net/bridge/br_netfilter.c
+++ b/net/bridge/br_netfilter.c
@@ -61,13 +61,11 @@ static struct brnf_net init_brnf_net = {

  #ifdef CONFIG_SYSCTL
  static struct ctl_table_header *brnf_sysctl_header;
-static int brnf_call_iptables __read_mostly = 1;
  static int brnf_call_ip6tables __read_mostly = 1;
  static int brnf_filter_vlan_tagged __read_mostly = 0;
  static int brnf_filter_pppoe_tagged __read_mostly = 0;
  static int brnf_pass_vlan_indev __read_mostly = 0;
  #else
-#define brnf_call_iptables 1

Your patch creates extra unneeded overhead in case CONFIG_SYSCTL isn't defined (a compile-time check of brnf_call_iptables is replaced by a runtime check of brnf_net(dev_net(skb->dev))->brnf_call_iptables). Please refactor to remove this extra overhead (for all flags).

cheers,
Bart


--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux