Skip to content
Commit dbd6b11e authored by Linus Lüssing's avatar Linus Lüssing Committed by David S. Miller
Browse files

batman-adv: make batadv_test_bit() return 0 or 1 only



On some architectures test_bit() can return other values than 0 or 1:

With a generic x86 OpenWrt image in a kvm setup (batadv_)test_bit()
frequently returns -1 for me, leading to batadv_iv_ogm_update_seqnos()
wrongly signaling a protected seqno window.

This patch tries to fix this issue by making batadv_test_bit() return 0
or 1 only.

Signed-off-by: default avatarLinus Lüssing <linus.luessing@web.de>
Acked-by: default avatarSven Eckelmann <sven@narfation.org>
Signed-off-by: default avatarAntonio Quartulli <ordex@autistici.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 59d86c76
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment