Skip to content

Commit

Permalink
iwlwifi: use dev_printk instead of dev_dbg for debug logs
Browse files Browse the repository at this point in the history
When calling IWL_DEBUG_*() dev_dbg() is currently used, and this
could result in the log being ignored no matter the internal
loglevel, since dev_dbg() may get turned on or off based on the
dynamic debug mechanism.

Replace the dev_dbg() with dev_printk() since dynamic printing
is pointless as we use our own debug level mechanism and there
is just a single dev_dbg() call in the code.

Signed-off-by: Liad Kaufman <liad.kaufman@intel.com>
[rephrase commit message a bit]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
  • Loading branch information
Liad Kaufman authored and Emmanuel Grumbach committed May 13, 2014
1 parent a102292 commit 7f71562
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/net/wireless/iwlwifi/iwl-debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@
*
*****************************************************************************/

#define DEBUG

#include <linux/device.h>
#include <linux/interrupt.h>
#include <linux/export.h>
Expand Down Expand Up @@ -128,8 +126,8 @@ void __iwl_dbg(struct device *dev,
#ifdef CONFIG_IWLWIFI_DEBUG
if (iwl_have_debug_level(level) &&
(!limit || net_ratelimit()))
dev_dbg(dev, "%c %s %pV", in_interrupt() ? 'I' : 'U',
function, &vaf);
dev_printk(KERN_DEBUG, dev, "%c %s %pV",
in_interrupt() ? 'I' : 'U', function, &vaf);
#endif
trace_iwlwifi_dbg(level, in_interrupt(), function, &vaf);
va_end(args);
Expand Down

0 comments on commit 7f71562

Please sign in to comment.