diff options
author | Tilman Schmidt <tilman@imap.cc> | 2009-05-13 12:44:17 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-05-17 20:51:25 -0700 |
commit | 1315d69634834f1f485b21b0ed8f10b763a675d2 (patch) | |
tree | 850f0763f142be84e265c7ffff90574467472672 /drivers/isdn | |
parent | 42e3d611158faa2d372ccfb1e17bfde13935de68 (diff) | |
download | linux-3.10-1315d69634834f1f485b21b0ed8f10b763a675d2.tar.gz linux-3.10-1315d69634834f1f485b21b0ed8f10b763a675d2.tar.bz2 linux-3.10-1315d69634834f1f485b21b0ed8f10b763a675d2.zip |
gigaset: skip unnecessary hex formatting
Don't generate the hex representation of the payload data if it
isn't actually used afterwards.
Impact: optimization
Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/isdn')
-rw-r--r-- | drivers/isdn/gigaset/isocdata.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/isdn/gigaset/isocdata.c b/drivers/isdn/gigaset/isocdata.c index b171e75cb52..09202a5a344 100644 --- a/drivers/isdn/gigaset/isocdata.c +++ b/drivers/isdn/gigaset/isocdata.c @@ -246,6 +246,10 @@ static inline void dump_bytes(enum debuglevel level, const char *tag, unsigned char c; static char dbgline[3 * 32 + 1]; int i = 0; + + if (!(gigaset_debuglevel & level)) + return; + while (count-- > 0) { if (i > sizeof(dbgline) - 4) { dbgline[i] = '\0'; |