tipc: Exclude debug-only print buffer code when not debugging
This patch modifies TIPC to only exclude debug-related print buffer routines when debugging capabilities are not required. It also fixes up some related #defines that exceed 80 characters. Signed-off-by: Allan Stephens <allan.stephens@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
6063da9d74
commit
48c9713946
@@ -41,7 +41,9 @@
|
||||
#include "bearer.h"
|
||||
|
||||
|
||||
void tipc_msg_print(struct print_buf *buf, struct tipc_msg *msg, const char *str)
|
||||
#ifdef CONFIG_TIPC_DEBUG
|
||||
|
||||
void tipc_msg_dbg(struct print_buf *buf, struct tipc_msg *msg, const char *str)
|
||||
{
|
||||
u32 usr = msg_user(msg);
|
||||
tipc_printf(buf, str);
|
||||
@@ -315,9 +317,11 @@ void tipc_msg_print(struct print_buf *buf, struct tipc_msg *msg, const char *str
|
||||
}
|
||||
tipc_printf(buf, "\n");
|
||||
if ((usr == CHANGEOVER_PROTOCOL) && (msg_msgcnt(msg))) {
|
||||
tipc_msg_print(buf,msg_get_wrapped(msg)," /");
|
||||
tipc_msg_dbg(buf, msg_get_wrapped(msg), " /");
|
||||
}
|
||||
if ((usr == MSG_FRAGMENTER) && (msg_type(msg) == FIRST_FRAGMENT)) {
|
||||
tipc_msg_print(buf,msg_get_wrapped(msg)," /");
|
||||
tipc_msg_dbg(buf, msg_get_wrapped(msg), " /");
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user