projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8ca712c
)
mac802154: replace hardcoded value with macro
author
Diogenes Pereira
<dvnp@cesar.org.br>
Wed, 9 Aug 2017 16:19:24 +0000
(13:19 -0300)
committer
Stefan Schmidt
<stefan@osg.samsung.com>
Wed, 20 Sep 2017 11:37:16 +0000
(13:37 +0200)
Use IEEE802154_SCF_SECLEVEL_NONE macro defined at ieee802154.h file.
Signed-off-by: Diogenes Pereira <dvnp@cesar.org.br>
Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com>
net/mac802154/llsec.c
patch
|
blob
|
history
diff --git
a/net/mac802154/llsec.c
b/net/mac802154/llsec.c
index 1e1c9b20bab7f4c4835ca928cb1aee87324aae20..edec2f9919d0aae91f475b6b01a9eb31b9e0f3a4 100644
(file)
--- a/
net/mac802154/llsec.c
+++ b/
net/mac802154/llsec.c
@@
-713,7
+713,8
@@
int mac802154_llsec_encrypt(struct mac802154_llsec *sec, struct sk_buff *skb)
if (hlen < 0 || hdr.fc.type != IEEE802154_FC_TYPE_DATA)
return -EINVAL;
- if (!hdr.fc.security_enabled || hdr.sec.level == 0) {
+ if (!hdr.fc.security_enabled ||
+ (hdr.sec.level == IEEE802154_SCF_SECLEVEL_NONE)) {
skb_push(skb, hlen);
return 0;
}