aboutsummaryrefslogtreecommitdiffstats
path: root/net/bridge
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2010-02-03 07:45:12 -0500
committerPatrick McHardy <kaber@trash.net>2010-02-03 07:45:12 -0500
commitadd67461240c1dadc7c8d97e66f8f92b556ca523 (patch)
treedac0f8982130e407ac184fb55d18140a3ebcef5d /net/bridge
parent794e68716bab578ae8f8912dc934496d7c7abc90 (diff)
netfilter: add struct net * to target parameters
Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'net/bridge')
-rw-r--r--net/bridge/netfilter/ebtables.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebtables.c
index 1aa0e4c1f52d..12beb580aa21 100644
--- a/net/bridge/netfilter/ebtables.c
+++ b/net/bridge/netfilter/ebtables.c
@@ -579,13 +579,14 @@ ebt_cleanup_match(struct ebt_entry_match *m, struct net *net, unsigned int *i)
579} 579}
580 580
581static inline int 581static inline int
582ebt_cleanup_watcher(struct ebt_entry_watcher *w, unsigned int *i) 582ebt_cleanup_watcher(struct ebt_entry_watcher *w, struct net *net, unsigned int *i)
583{ 583{
584 struct xt_tgdtor_param par; 584 struct xt_tgdtor_param par;
585 585
586 if (i && (*i)-- == 0) 586 if (i && (*i)-- == 0)
587 return 1; 587 return 1;
588 588
589 par.net = net;
589 par.target = w->u.watcher; 590 par.target = w->u.watcher;
590 par.targinfo = w->data; 591 par.targinfo = w->data;
591 par.family = NFPROTO_BRIDGE; 592 par.family = NFPROTO_BRIDGE;
@@ -606,10 +607,11 @@ ebt_cleanup_entry(struct ebt_entry *e, struct net *net, unsigned int *cnt)
606 /* we're done */ 607 /* we're done */
607 if (cnt && (*cnt)-- == 0) 608 if (cnt && (*cnt)-- == 0)
608 return 1; 609 return 1;
609 EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, NULL); 610 EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, net, NULL);
610 EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, NULL); 611 EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, NULL);
611 t = (struct ebt_entry_target *)(((char *)e) + e->target_offset); 612 t = (struct ebt_entry_target *)(((char *)e) + e->target_offset);
612 613
614 par.net = net;
613 par.target = t->u.target; 615 par.target = t->u.target;
614 par.targinfo = t->data; 616 par.targinfo = t->data;
615 par.family = NFPROTO_BRIDGE; 617 par.family = NFPROTO_BRIDGE;
@@ -674,7 +676,7 @@ ebt_check_entry(struct ebt_entry *e,
674 } 676 }
675 i = 0; 677 i = 0;
676 678
677 mtpar.net = net; 679 mtpar.net = tgpar.net = net;
678 mtpar.table = tgpar.table = name; 680 mtpar.table = tgpar.table = name;
679 mtpar.entryinfo = tgpar.entryinfo = e; 681 mtpar.entryinfo = tgpar.entryinfo = e;
680 mtpar.hook_mask = tgpar.hook_mask = hookmask; 682 mtpar.hook_mask = tgpar.hook_mask = hookmask;
@@ -730,7 +732,7 @@ ebt_check_entry(struct ebt_entry *e,
730 (*cnt)++; 732 (*cnt)++;
731 return 0; 733 return 0;
732cleanup_watchers: 734cleanup_watchers:
733 EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, &j); 735 EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, net, &j);
734cleanup_matches: 736cleanup_matches:
735 EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, &i); 737 EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, &i);
736 return ret; 738 return ret;