diff options
author | Takashi Iwai <tiwai@suse.de> | 2012-12-04 18:22:17 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2012-12-04 18:23:04 +0100 |
commit | e20db4bd19368709d92b3b895588b3a4f83af78a (patch) | |
tree | fe411f5863213e6be02c5802eacf9f091da41957 | |
parent | dd041e31d11ab3703b1d34109e944b644f7fcdf8 (diff) | |
download | hda-emu-e20db4bd19368709d92b3b895588b3a4f83af78a.tar.gz |
Add pr_*() macro, dma_addr_t, and time_before() macro definitions
Added in wrapper.h.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r-- | include/wrapper.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/include/wrapper.h b/include/wrapper.h index 7038581..b47f37f 100644 --- a/include/wrapper.h +++ b/include/wrapper.h @@ -72,6 +72,25 @@ #define KERN_WARNING "<4>" #define KERN_ERR "<3>" +#define pr_fmt(fmt) fmt +#define pr_emerg(fmt, ...) \ + printk(KERN_EMERG pr_fmt(fmt), ##__VA_ARGS__) +#define pr_alert(fmt, ...) \ + printk(KERN_ALERT pr_fmt(fmt), ##__VA_ARGS__) +#define pr_crit(fmt, ...) \ + printk(KERN_CRIT pr_fmt(fmt), ##__VA_ARGS__) +#define pr_err(fmt, ...) \ + printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__) +#define pr_warning(fmt, ...) \ + printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__) +#define pr_warn pr_warning +#define pr_notice(fmt, ...) \ + printk(KERN_NOTICE pr_fmt(fmt), ##__VA_ARGS__) +#define pr_info(fmt, ...) \ + printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) +#define pr_cont(fmt, ...) \ + printk(KERN_CONT fmt, ##__VA_ARGS__) + typedef uint64_t u64; typedef uint64_t __u64; typedef int64_t s64; @@ -106,6 +125,8 @@ typedef _Bool bool; #define true 1 #define false 0 +typedef unsigned long dma_addr_t; + #define PAGE_SIZE 4096 #define __user @@ -137,6 +158,9 @@ typedef int pm_message_t; static inline bool time_after_eq(unsigned long a, unsigned long b) { return 1; } +static inline bool time_before(unsigned long a, unsigned long b) +{ return 0; } + #define BUG_ON(x) do { \ if (x) { fprintf(stderr, "ERROR!\n"); } \ } while (0) |