]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/netfilter/x_tables.h
[NETFILTER]: x_tables: add data member to struct xt_match
[linux-2.6-omap-h63xx.git] / include / linux / netfilter / x_tables.h
index 48cc32d83f77acb935768224e8cdd7ac8a3d982f..03d1027fb0e88568a9598a3d9d976192c298760a 100644 (file)
@@ -174,12 +174,10 @@ struct xt_match
                          const void *ip,
                          const struct xt_match *match,
                          void *matchinfo,
-                         unsigned int matchinfosize,
                          unsigned int hook_mask);
 
        /* Called when entry of this type deleted. */
-       void (*destroy)(const struct xt_match *match, void *matchinfo,
-                       unsigned int matchinfosize);
+       void (*destroy)(const struct xt_match *match, void *matchinfo);
 
        /* Called when userspace align differs from kernel space one */
        int (*compat)(void *match, void **dstptr, int *size, int convert);
@@ -187,6 +185,9 @@ struct xt_match
        /* Set this to THIS_MODULE if you are a module, otherwise NULL */
        struct module *me;
 
+       /* Free to use by each match */
+       unsigned long data;
+
        char *table;
        unsigned int matchsize;
        unsigned int hooks;
@@ -211,8 +212,7 @@ struct xt_target
                               const struct net_device *out,
                               unsigned int hooknum,
                               const struct xt_target *target,
-                              const void *targinfo,
-                              void *userdata);
+                              const void *targinfo);
 
        /* Called when user tries to insert an entry of this type:
            hook_mask is a bitmask of hooks from which it can be
@@ -222,12 +222,10 @@ struct xt_target
                          const void *entry,
                          const struct xt_target *target,
                          void *targinfo,
-                         unsigned int targinfosize,
                          unsigned int hook_mask);
 
        /* Called when entry of this type deleted. */
-       void (*destroy)(const struct xt_target *target, void *targinfo,
-                       unsigned int targinfosize);
+       void (*destroy)(const struct xt_target *target, void *targinfo);
 
        /* Called when userspace align differs from kernel space one */
        int (*compat)(void *target, void **dstptr, int *size, int convert);
@@ -290,8 +288,13 @@ struct xt_table_info
 
 extern int xt_register_target(struct xt_target *target);
 extern void xt_unregister_target(struct xt_target *target);
+extern int xt_register_targets(struct xt_target *target, unsigned int n);
+extern void xt_unregister_targets(struct xt_target *target, unsigned int n);
+
 extern int xt_register_match(struct xt_match *target);
 extern void xt_unregister_match(struct xt_match *target);
+extern int xt_register_matches(struct xt_match *match, unsigned int n);
+extern void xt_unregister_matches(struct xt_match *match, unsigned int n);
 
 extern int xt_check_match(const struct xt_match *match, unsigned short family,
                          unsigned int size, const char *table, unsigned int hook,