[<prev] [next>] [day] [month] [year] [list]
Message-Id: <a74034e340d7db52dfb0b1a01c18759eb091fd18.1353521783.git.joe@perches.com>
Date: Wed, 21 Nov 2012 10:17:34 -0800
From: Joe Perches <joe@...ches.com>
To: linux-kernel@...r.kernel.org
Cc: Brett Rudley <brudley@...adcom.com>,
Roland Vossen <rvossen@...adcom.com>,
Arend van Spriel <arend@...adcom.com>,
"Franky (Zhenhui) Lin" <frankyl@...adcom.com>,
Kan Yan <kanyan@...adcom.com>,
"John W. Linville" <linville@...driver.com>,
linux-wireless@...r.kernel.org, brcm80211-dev-list@...adcom.com,
netdev@...r.kernel.org
Subject: [PATCH] brcmsmac: Add __printf verification to logging prototypes
Adding __printf helps spot format and argument mismatches.
Signed-off-by: Joe Perches <joe@...ches.com>
---
drivers/net/wireless/brcm80211/brcmsmac/debug.h | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/debug.h b/drivers/net/wireless/brcm80211/brcmsmac/debug.h
index c0d2cf7..f77066b 100644
--- a/drivers/net/wireless/brcm80211/brcmsmac/debug.h
+++ b/drivers/net/wireless/brcm80211/brcmsmac/debug.h
@@ -8,17 +8,23 @@
#include "main.h"
#include "mac80211_if.h"
+__printf(2, 3)
void __brcms_info(struct device *dev, const char *fmt, ...);
+__printf(2, 3)
void __brcms_warn(struct device *dev, const char *fmt, ...);
+__printf(2, 3)
void __brcms_err(struct device *dev, const char *fmt, ...);
+__printf(2, 3)
void __brcms_crit(struct device *dev, const char *fmt, ...);
#if defined(CONFIG_BRCMDBG) || defined(CONFIG_BRCM_TRACING)
+__printf(4, 5)
void __brcms_dbg(struct device *dev, u32 level, const char *func,
const char *fmt, ...);
#else
-static inline void __brcms_dbg(struct device *dev, u32 level,
- const char *func, const char *fmt, ...)
+static inline __printf(4, 5)
+void __brcms_dbg(struct device *dev, u32 level, const char *func,
+ const char *fmt, ...)
{
}
#endif
--
1.7.8.112.g3fd21
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists