diff options
Diffstat (limited to 'fs/partitions/ldm.c')
-rw-r--r-- | fs/partitions/ldm.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/fs/partitions/ldm.c b/fs/partitions/ldm.c index af9fdf046769..bd8ae788f689 100644 --- a/fs/partitions/ldm.c +++ b/fs/partitions/ldm.c | |||
@@ -49,18 +49,20 @@ | |||
49 | #define ldm_error(f, a...) _ldm_printk (KERN_ERR, __func__, f, ##a) | 49 | #define ldm_error(f, a...) _ldm_printk (KERN_ERR, __func__, f, ##a) |
50 | #define ldm_info(f, a...) _ldm_printk (KERN_INFO, __func__, f, ##a) | 50 | #define ldm_info(f, a...) _ldm_printk (KERN_INFO, __func__, f, ##a) |
51 | 51 | ||
52 | __attribute__ ((format (printf, 3, 4))) | 52 | static __printf(3, 4) |
53 | static void _ldm_printk (const char *level, const char *function, | 53 | void _ldm_printk(const char *level, const char *function, const char *fmt, ...) |
54 | const char *fmt, ...) | ||
55 | { | 54 | { |
56 | static char buf[128]; | 55 | struct va_format vaf; |
57 | va_list args; | 56 | va_list args; |
58 | 57 | ||
59 | va_start (args, fmt); | 58 | va_start (args, fmt); |
60 | vsnprintf (buf, sizeof (buf), fmt, args); | ||
61 | va_end (args); | ||
62 | 59 | ||
63 | printk ("%s%s(): %s\n", level, function, buf); | 60 | vaf.fmt = fmt; |
61 | vaf.va = &args; | ||
62 | |||
63 | printk("%s%s(): %pV\n", level, function, &vaf); | ||
64 | |||
65 | va_end(args); | ||
64 | } | 66 | } |
65 | 67 | ||
66 | /** | 68 | /** |