[B.A.T.M.A.N.] [PATCH 1/2] batman-adv: adding MAC_FMT compatibility

Marek Lindner lindner_marek at yahoo.de
Mon May 3 02:28:37 CEST 2010


Kernel older than 2.6.24 do not have the MAC_FMT definition,
therefore we need to add it to our compat layer.

Signed-off-by: Marek Lindner <lindner_marek at yahoo.de>
---
 batman-adv-kernelland/compat.h |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/batman-adv-kernelland/compat.h b/batman-adv-kernelland/compat.h
index 2e3aded..4eaa128 100644
--- a/batman-adv-kernelland/compat.h
+++ b/batman-adv-kernelland/compat.h
@@ -62,6 +62,12 @@ static inline int skb_clone_writable(struct sk_buff *skb, unsigned int len)
 
 #endif /* < KERNEL_VERSION(2, 6, 23) */
 
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
+
+#define MAC_FMT "%02x:%02x:%02x:%02x:%02x:%02x"
+
+#endif /* < KERNEL_VERSION(2, 6, 24) */
+
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 25)
 
 #define strict_strtoul(cp, base, res) \
-- 
1.7.0



More information about the B.A.T.M.A.N mailing list