projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5f93592
)
drbd: drbd_nla_check_mandatory(): Need to remove the DRBD_GENLA_F_MANDATORY flag...
author
Andreas Gruenbacher
<agruen@linbit.com>
Tue, 24 May 2011 12:08:58 +0000
(14:08 +0200)
committer
Philipp Reisner
<philipp.reisner@linbit.com>
Thu, 8 Nov 2012 15:55:56 +0000
(16:55 +0100)
We need to remove the flag before checking for valid types.
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
include/linux/genl_magic_func.h
patch
|
blob
|
history
diff --git
a/include/linux/genl_magic_func.h
b/include/linux/genl_magic_func.h
index 58edd403a3ff8be84aa1c5d4e4ee2aba93b1f509..357f2ad403b1d32a1e9ddd27b7c50ba92d0844bf 100644
(file)
--- a/
include/linux/genl_magic_func.h
+++ b/
include/linux/genl_magic_func.h
@@
-158,9
+158,9
@@
static inline int drbd_nla_check_mandatory(int maxtype, struct nlattr *nla)
nla_for_each_attr(nla, head, len, rem) {
if (nla->nla_type & DRBD_GENLA_F_MANDATORY) {
+ nla->nla_type &= ~DRBD_GENLA_F_MANDATORY;
if (nla_type(nla) > maxtype)
return -EOPNOTSUPP;
- nla->nla_type &= ~DRBD_GENLA_F_MANDATORY;
}
}
return 0;