* [PATCH] backports: add lockdep_rtnl_is_held() for < 3.13 without CONFIG_PROVE_LOCKING
@ 2017-05-31 8:30 Luca Coelho
2017-06-16 13:00 ` Johannes Berg
0 siblings, 1 reply; 2+ messages in thread
From: Luca Coelho @ 2017-05-31 8:30 UTC (permalink / raw)
To: johannes; +Cc: backports
From: Luca Coelho <luciano.coelho@intel.com>
In kernels earlier than 3.13, lockdep_rtnl_is_held() is only declared
in rtnetlink.h when CONFIG_PROVE_LOCKING is not set. Backport this
function if that's the case.
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
backport/backport-include/linux/rtnetlink.h | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/backport/backport-include/linux/rtnetlink.h b/backport/backport-include/linux/rtnetlink.h
index 9b68be820049..59beffa8316a 100644
--- a/backport/backport-include/linux/rtnetlink.h
+++ b/backport/backport-include/linux/rtnetlink.h
@@ -18,4 +18,12 @@
ndo_dflt_fdb_add(ndm, tb, dev, addr, flags)
#endif
+#if LINUX_VERSION_IS_LESS(3,13,0) && \
+ !defined(CONFIG_PROVE_LOCKING)
+static inline bool lockdep_rtnl_is_held(void)
+{
+ return true;
+}
+#endif
+
#endif /* __BACKPORT_LINUX_RTNETLINK_H */
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe backports" in
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-16 13:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-31 8:30 [PATCH] backports: add lockdep_rtnl_is_held() for < 3.13 without CONFIG_PROVE_LOCKING Luca Coelho
2017-06-16 13:00 ` Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox