diff options
author | Alexander Aring <alex.aring@gmail.com> | 2013-12-12 14:15:25 -0500 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2013-12-12 15:14:54 -0500 |
commit | 841a5ec72c028432f716670c4a7c2e1b70ee1341 (patch) | |
tree | 7f5c061987928ff287c1c55b3ffe596c4c670f98 /net/ieee802154/6lowpan_iphc.c | |
parent | 30d3db44bb337321b25344eea3ed6a64ee16fcc8 (diff) |
6lowpan: fix/move/cleanup debug functions
There are several issues on current debug behaviour.
This patch fix the following issues:
- Fix debug printout only if DEBUG is defined.
- Move debug functions of 6LoWPAN code into 6lowpan header.
- Cleanup codestyle of debug functions.
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/ieee802154/6lowpan_iphc.c')
-rw-r--r-- | net/ieee802154/6lowpan_iphc.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/net/ieee802154/6lowpan_iphc.c b/net/ieee802154/6lowpan_iphc.c index 57c0b7ad6b6c..88e7da599558 100644 --- a/net/ieee802154/6lowpan_iphc.c +++ b/net/ieee802154/6lowpan_iphc.c | |||
@@ -58,32 +58,6 @@ | |||
58 | 58 | ||
59 | #include "6lowpan.h" | 59 | #include "6lowpan.h" |
60 | 60 | ||
61 | /* print data in line */ | ||
62 | static inline void raw_dump_inline(const char *caller, char *msg, | ||
63 | unsigned char *buf, int len) | ||
64 | { | ||
65 | if (msg) | ||
66 | pr_debug("%s():%s: ", caller, msg); | ||
67 | print_hex_dump_debug("", DUMP_PREFIX_NONE, | ||
68 | 16, 1, buf, len, false); | ||
69 | } | ||
70 | |||
71 | /* | ||
72 | * print data in a table format: | ||
73 | * | ||
74 | * addr: xx xx xx xx xx xx | ||
75 | * addr: xx xx xx xx xx xx | ||
76 | * ... | ||
77 | */ | ||
78 | static inline void raw_dump_table(const char *caller, char *msg, | ||
79 | unsigned char *buf, int len) | ||
80 | { | ||
81 | if (msg) | ||
82 | pr_debug("%s():%s:\n", caller, msg); | ||
83 | print_hex_dump_debug("\t", DUMP_PREFIX_OFFSET, | ||
84 | 16, 1, buf, len, false); | ||
85 | } | ||
86 | |||
87 | /* | 61 | /* |
88 | * Uncompress address function for source and | 62 | * Uncompress address function for source and |
89 | * destination address(non-multicast). | 63 | * destination address(non-multicast). |