diff options
author | Jeremy Sowden <jeremy@azazel.net> | 2020-01-01 16:41:32 +0300 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2020-01-16 17:51:14 +0300 |
commit | 4a7faaf4add3108522512c16c9ee08fb2ad4525e (patch) | |
tree | 665470f16d1aed6807b3ddb5fefa2449ca387259 /include/uapi | |
parent | 6bc8038035267d12df2bf78a8e1a5f07069fabb8 (diff) | |
download | linux-4a7faaf4add3108522512c16c9ee08fb2ad4525e.tar.xz |
netfilter: nft_bitwise: correct uapi header comment.
The comment documenting how bitwise expressions work includes a table
which summarizes the mask and xor arguments combined to express the
supported boolean operations. However, the row for OR:
mask xor
0 x
is incorrect.
dreg = (sreg & 0) ^ x
is not equivalent to:
dreg = sreg | x
What the code actually does is:
dreg = (sreg & ~x) ^ x
Update the documentation to match.
Signed-off-by: Jeremy Sowden <jeremy@azazel.net>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include/uapi')
-rw-r--r-- | include/uapi/linux/netfilter/nf_tables.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/uapi/linux/netfilter/nf_tables.h b/include/uapi/linux/netfilter/nf_tables.h index e237ecbdcd8a..dd4611767933 100644 --- a/include/uapi/linux/netfilter/nf_tables.h +++ b/include/uapi/linux/netfilter/nf_tables.h @@ -501,7 +501,7 @@ enum nft_immediate_attributes { * * mask xor * NOT: 1 1 - * OR: 0 x + * OR: ~x x * XOR: 1 x * AND: x 0 */ |