compat-wireless: fix debugging in iwlwifi
PATCH 1/1 compat-wireless: fix debugging in iwlwifi
From: Johannes Berg <[email protected]>
As compat includes linux/device.h well before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Use dev_printk instead of dev_dbg to get debugging back.
--- patches/57-iwlwifi-debug-fix.patch | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 patches/57-iwlwifi-debug-fix.patch
patches/57-iwlwifi-debug-fix.patch new file +19 -0
@@ -0,0 +1,19 @@ +Due to compat including linux/device.h before we do, +we don't get a chance to #define DEBUG to get our +debugging prints. This patch replaces dev_dbg with +dev_printk to make them show up again. + +--- a/drivers/net/wireless/iwlwifi/iwl-debug.c ++++ b/drivers/net/wireless/iwlwifi/iwl-debug.c +@@ -138,8 +138,9 @@ void __iwl_dbg(struct device *dev, + + va_copy(args2, args); + vaf.va = &args2; +- 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); + va_end(args2); + } + #endif
Signature · 1 line
1.7.10
Quoted 8 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Signed-off-by Johannes Berg <[email protected]>
Applied and pushed, thanks!
Luis
Quoted 11 lines · Luis R. Rodriguez
Quoted 8 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Signed-off-by Johannes Berg <[email protected]>Applied and pushed, thanks!
On today's linux-next.git the dev_dbg() changed to dev_err(), I've updated the patch to reflect this.
mcgrof@tux ~/devel/compat-wireless (git::master)$ git diff
(quoted diff) +0 -0
b/patches/57-iwlwifi-debug-fix.patch
index 4b2dfa9..1bfc88f 100644
patches/57-iwlwifi-debug-fix.patch +1 -1
@@ -9,7 +9,7 @@ dev_printk to make them show up again. va_copy(args2, args); vaf.va = &args2; -- dev_dbg(dev, "%c %s %pV", in_interrupt() ? 'I' : 'U', +- dev_err(dev, "%c %s %pV", in_interrupt() ? 'I' : 'U', - function, &vaf); + dev_printk(KERN_DEBUG, dev, "%c %s %pV", + in_interrupt() ? 'I' : 'U'
Luis
Quoted 9 lines · Luis R. Rodriguez
Quoted 8 lines · Luis R. Rodriguez
Quoted 7 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Signed-off-by Johannes Berg <[email protected]>Applied and pushed, thanks!
On today's linux-next.git the
dev_dbg()changed todev_err(), I've updated the patch to reflect this.
Huh, sorry. Please drop this for now -- the patch to change it *from* dev_err *to* dev_dbg is only in my iwlwifi-next tree now.
johannes
Quoted 12 lines · Johannes Berg
Quoted 11 lines · Luis R. Rodriguez
Quoted 10 lines · Luis R. Rodriguez
Quoted 8 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Signed-off-by Johannes Berg <[email protected]>
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
Applied and pushed, thanks!
On today's linux-next.git the
dev_dbg()changed todev_err(), I've updated the patch to reflect this.Huh, sorry. Please drop this for now -- the patch to change it *from*
dev_err*to*dev_dbgis only in my iwlwifi-next tree now.
And besides, the concept is wrong.
There's no reason to drop dynamic_debug support by forcing output to KERN_DEBUG.
Quoted 18 lines · Joe Perches
Quoted 17 lines · Johannes Berg
Quoted 15 lines · Luis R. Rodriguez
Quoted 11 lines · Luis R. Rodriguez
Quoted 8 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Signed-off-by Johannes Berg <[email protected]>Applied and pushed, thanks!
On today's linux-next.git the
dev_dbg()changed todev_err(), I've updated the patch to reflect this.
Quoted 7 lines
Quoted 2 lines
Huh, sorry. Please drop this for now -- the patch to change it *from*
dev_err*to*dev_dbgis only in my iwlwifi-next tree now.And besides, the concept is wrong.
There's no reason to drop
dynamic_debugsupport by forcing output toKERN_DEBUG.
Well, the thing is, "#define DEBUG" doesn't work in compat-wireless ... We add it to the Makefile though I guess
johannes
Quoted 22 lines · Johannes Berg
Quoted 21 lines · Joe Perches
Quoted 19 lines · Johannes Berg
Quoted 9 lines · Luis R. Rodriguez
Quoted 8 lines · Luis R. Rodriguez
Quoted 7 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Signed-off-by Johannes Berg <[email protected]>Applied and pushed, thanks!
On today's linux-next.git the
dev_dbg()changed todev_err(), I've updated the patch to reflect this.Huh, sorry. Please drop this for now -- the patch to change it *from*
dev_err*to*dev_dbgis only in my iwlwifi-next tree now.
Quoted 7 lines
Quoted 4 lines
And besides, the concept is wrong.
There's no reason to drop
dynamic_debugsupport by forcing output toKERN_DEBUG.Well, the thing is, "#define DEBUG" doesn't work in compat-wireless ... We add it to the
Makefilethough I guess
What if we add a hunk to iwlwifi to undef DEBUG and redefine it ? Sort of similar problem as with pr_fmt no? I've merged this patch now.
Luis
Quoted 12 lines · Johannes Berg
Quoted 11 lines · Luis R. Rodriguez
Quoted 10 lines · Luis R. Rodriguez
Quoted 8 lines · Johannes Berg
From: Johannes Berg <[email protected]>
As compat includes
linux/device.hwell before iwlwifi, the definitions from there are used without DEBUG, but iwlwifi defines DEBUG to get debug output. Usedev_printkinstead ofdev_dbgto get debugging back.Signed-off-by Johannes Berg <[email protected]>
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
Applied and pushed, thanks!
On today's linux-next.git the
dev_dbg()changed todev_err(), I've updated the patch to reflect this.Huh, sorry. Please drop this for now -- the patch to change it *from*
dev_err*to*dev_dbgis only in my iwlwifi-next tree now.
Dropped patches/57-iwlwifi-debug-fix.patch
Luis