]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - net/netfilter/nft_compat.c
netfilter: x_tables: add context to know if extension runs from nft_compat
[karo-tx-linux.git] / net / netfilter / nft_compat.c
index 7f29cfc76349f56d7408f4519213a98d564ab135..66def315eb5619a26b64da8a1a5525af7d4a5e3f 100644 (file)
@@ -161,6 +161,7 @@ nft_target_set_tgchk_param(struct xt_tgchk_param *par,
                par->hook_mask = 0;
        }
        par->family     = ctx->afi->family;
+       par->nft_compat = true;
 }
 
 static void target_compat_from_user(struct xt_target *t, void *in, void *out)
@@ -377,6 +378,7 @@ nft_match_set_mtchk_param(struct xt_mtchk_param *par, const struct nft_ctx *ctx,
                par->hook_mask = 0;
        }
        par->family     = ctx->afi->family;
+       par->nft_compat = true;
 }
 
 static void match_compat_from_user(struct xt_match *m, void *in, void *out)