diff options
author | Paul Moore <pmoore@redhat.com> | 2012-03-06 18:16:39 -0500 |
---|---|---|
committer | Paul Moore <pmoore@redhat.com> | 2012-03-09 11:46:50 -0500 |
commit | fc033fb661fc2285b098ad9c444672ad9a62d0bc (patch) | |
tree | 94cb13318c116c448ac61f3c45c8915fcc0d27be /src/gen_bpf.h | |
parent | 7092a0d72e0de8b82269f9f3b0a2cb313aa002dc (diff) | |
download | libseccomp-fc033fb661fc2285b098ad9c444672ad9a62d0bc.tar.gz |
arch: introduce a single place for all the machine dependent code
Signed-off-by: Paul Moore <pmoore@redhat.com>
Diffstat (limited to 'src/gen_bpf.h')
-rw-r--r-- | src/gen_bpf.h | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/gen_bpf.h b/src/gen_bpf.h index 9896574..af183b8 100644 --- a/src/gen_bpf.h +++ b/src/gen_bpf.h @@ -24,6 +24,7 @@ #include <inttypes.h> +#include "arch.h" #include "db.h" /* XXX - should we just use "sock_filter" in linux/filter.h? the name is @@ -42,21 +43,8 @@ struct bpf_program { #define BPF_PGM_SIZE(x) \ ((x)->blk_cnt * sizeof(*((x)->blks))) -struct bpf_arch { - enum { - _BPF_WLEN_UNSPEC, - _BPF_WLEN_32, - _BPF_WLEN_64, - } word_len; - enum { - _BPF_ENDIAN_UNSPEC, - _BPF_ENDIAN_LITTLE, - _BPF_ENDIAN_BIG, - } endian; -}; - struct bpf_program *gen_bpf_generate(const struct db_filter *db, - const struct bpf_arch *arch); + const struct arch_def *arch); void gen_bpf_destroy(struct bpf_program *program); #endif |