1. 13 Jun, 2009 3 commits
    • Pablo Neira Ayuso's avatar
      netfilter: conntrack: move event caching to conntrack extension infrastructure · a0891aa6
      Pablo Neira Ayuso authored
      This patch reworks the per-cpu event caching to use the conntrack
      extension infrastructure.
      
      The main drawback is that we consume more memory per conntrack
      if event delivery is enabled. This patch is required by the
      reliable event delivery that follows to this patch.
      
      BTW, this patch allows you to enable/disable event delivery via
      /proc/sys/net/netfilter/nf_conntrack_events in runtime, although
      you can still disable event caching as compilation option.
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
      a0891aa6
    • Patrick McHardy's avatar
      netfilter: nf_conntrack: use mod_timer_pending() for conntrack refresh · 65cb9fda
      Patrick McHardy authored
      Use mod_timer_pending() instead of atomic sequence of del_timer()/
      add_timer(). mod_timer_pending() does not rearm an inactive timer,
      so we don't need the conntrack lock anymore to make sure we don't
      accidentally rearm a timer of a conntrack which is in the process
      of being destroyed.
      
      With this change, we don't need to take the global lock anymore at all,
      counter updates can be performed under the per-conntrack lock.
      Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
      65cb9fda
    • Patrick McHardy's avatar
      netfilter: nf_log: fix sleeping function called from invalid context · 266d07cb
      Patrick McHardy authored
      Fix regression introduced by 17625274 "netfilter: sysctl support of
      logger choice":
      
      BUG: sleeping function called from invalid context at /mnt/s390test/linux-2.6-tip/arch/s390/include/asm/uaccess.h:234
      in_atomic(): 1, irqs_disabled(): 0, pid: 3245, name: sysctl
      CPU: 1 Not tainted 2.6.30-rc8-tipjun10-02053-g39ae214 #1
      Process sysctl (pid: 3245, task: 000000007f675da0, ksp: 000000007eb17cf0)
      0000000000000000 000000007eb17be8 0000000000000002 0000000000000000
             000000007eb17c88 000000007eb17c00 000000007eb17c00 0000000000048156
             00000000003e2de8 000000007f676118 000000007eb17f10 0000000000000000
             0000000000000000 000000007eb17be8 000000000000000d 000000007eb17c58
             00000000003e2050 000000000001635c 000000007eb17be8 000000007eb17c30
      Call Trace:
      (<00000000000162e6> show_trace+0x13a/0x148)
       <00000000000349ea> __might_sleep+0x13a/0x164
       <0000000000050300> proc_dostring+0x134/0x22c
       <0000000000312b70> nf_log_proc_dostring+0xfc/0x188
       <0000000000136f5e> proc_sys_call_handler+0xf6/0x118
       <0000000000136fda> proc_sys_read+0x26/0x34
       <00000000000d6e9c> vfs_read+0xac/0x158
       <00000000000d703e> SyS_read+0x56/0x88
       <0000000000027f42> sysc_noemu+0x10/0x16
      
      Use the nf_log_mutex instead of RCU to fix this.
      Reported-and-tested-by: default avatarMaran Pakkirisamy <maranpsamy@in.ibm.com>
      Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
      266d07cb
  2. 12 Jun, 2009 4 commits
  3. 11 Jun, 2009 33 commits