1 #ifndef LINUX_3_5_COMPAT_H
2 #define LINUX_3_5_COMPAT_H
4 #include <linux/version.h>
6 #include <linux/etherdevice.h>
8 #if (LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0))
10 extern int simple_open(struct inode *inode, struct file *file);
12 /* Backports tty_lock: Localise the lock */
13 #define tty_lock(__tty) tty_lock()
14 #define tty_unlock(__tty) tty_unlock()
16 /* Backport ether_addr_equal */
17 static inline bool ether_addr_equal(const u8 *addr1, const u8 *addr2)
19 return !compare_ether_addr(addr1, addr2);
22 #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0)) */
24 #endif /* LINUX_3_5_COMPAT_H */