1 #ifndef __LINUX_COMPAT_H__ 2 #define __LINUX_COMPAT_H__ 3 4 #include <malloc.h> 5 #include <linux/list.h> 6 #include <linux/compat.h> 7 8 #define pr_debug(fmt, args...) debug(fmt, ##args) 9 10 #define WARN(condition, fmt, args...) ({ \ 11 int ret_warn = !!condition; \ 12 if (ret_warn) \ 13 printf(fmt, ##args); \ 14 ret_warn; }) 15 16 #define writesl(a, d, s) __raw_writesl((unsigned long)a, d, s) 17 #define readsl(a, d, s) __raw_readsl((unsigned long)a, d, s) 18 #define writesw(a, d, s) __raw_writesw((unsigned long)a, d, s) 19 #define readsw(a, d, s) __raw_readsw((unsigned long)a, d, s) 20 #define writesb(a, d, s) __raw_writesb((unsigned long)a, d, s) 21 #define readsb(a, d, s) __raw_readsb((unsigned long)a, d, s) 22 23 #define device_init_wakeup(dev, a) do {} while (0) 24 25 #define platform_data device_data 26 27 #ifndef wmb 28 #define wmb() asm volatile ("" : : : "memory") 29 #endif 30 31 #define msleep(a) udelay(a * 1000) 32 33 /* 34 * Map U-Boot config options to Linux ones 35 */ 36 #ifdef CONFIG_OMAP34XX 37 #define CONFIG_SOC_OMAP3430 38 #endif 39 40 #endif /* __LINUX_COMPAT_H__ */ 41