mac802154: llsec: fold useless return value check

llsec_do_encrypt will never return a positive value, so the restriction
to 0-or-negative on return is useless.

Signed-off-by: Phoebe Buckheister <phoebe.buckheister@itwm.fraunhofer.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Phoebe Buckheister 2014-05-20 13:14:23 +02:00 committed by David S. Miller
parent 6f3eabcd04
commit 62e9c117ee

View File

@ -773,7 +773,7 @@ int mac802154_llsec_encrypt(struct mac802154_llsec *sec, struct sk_buff *skb)
rc = llsec_do_encrypt(skb, sec, &hdr, key); rc = llsec_do_encrypt(skb, sec, &hdr, key);
llsec_key_put(key); llsec_key_put(key);
return rc < 0 ? rc : 0; return rc;
fail_read: fail_read:
read_unlock_bh(&sec->lock); read_unlock_bh(&sec->lock);