summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Braun <rbraun@sceen.net>2017-06-15 00:29:00 +0200
committerRichard Braun <rbraun@sceen.net>2017-06-15 00:29:00 +0200
commit0eac4af899270f4ece438a2eb05c186639a9faee (patch)
tree5a7d2dfa26afeaeafe55c9f53275908143c808f5
parentd8ed3b6cda0a7dbc32a6ca2fecfc71a6fb1fe67c (diff)
kern/macros: remove the __format_printf macro
This macro isn't used enough for this alias to have any real value.
-rw-r--r--kern/macros.h3
-rw-r--r--kern/panic.h3
-rw-r--r--kern/printf.h8
3 files changed, 7 insertions, 7 deletions
diff --git a/kern/macros.h b/kern/macros.h
index a5b7b032..8f0d10ca 100644
--- a/kern/macros.h
+++ b/kern/macros.h
@@ -73,7 +73,4 @@
#define __packed __attribute__((packed))
#define __alias(x) __attribute__((alias(x)))
-#define __format_printf(fmt, args) \
- __attribute__((format(printf, fmt, args)))
-
#endif /* _KERN_MACROS_H */
diff --git a/kern/panic.h b/kern/panic.h
index 9d1d31e0..cd0651a4 100644
--- a/kern/panic.h
+++ b/kern/panic.h
@@ -23,6 +23,7 @@
/*
* Print the given message and halt the system immediately.
*/
-void __noreturn panic(const char *format, ...) __format_printf(1, 2);
+void __noreturn panic(const char *format, ...)
+ __attribute__((format(printf, 1, 2)));
#endif /* _KERN_PANIC_H */
diff --git a/kern/printf.h b/kern/printf.h
index 6643d664..0aed7200 100644
--- a/kern/printf.h
+++ b/kern/printf.h
@@ -33,10 +33,12 @@
#include <stdarg.h>
-#include <kern/macros.h>
+int printf(const char *format, ...)
+ __attribute__((format(printf, 1, 2)));
+
+int vprintf(const char *format, va_list ap)
+ __attribute__((format(printf, 1, 0)));
-int printf(const char *format, ...) __format_printf(1, 2);
-int vprintf(const char *format, va_list ap) __format_printf(1, 0);
void printf_setup(void);
#endif /* _KERN_PRINTF_H */