aboutsummaryrefslogtreecommitdiffstats
path: root/net/dccp/ccids/ccid3.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/dccp/ccids/ccid3.c')
-rw-r--r--net/dccp/ccids/ccid3.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/net/dccp/ccids/ccid3.c b/net/dccp/ccids/ccid3.c
index 2fa0c6d1fbee..7db801ec1ab9 100644
--- a/net/dccp/ccids/ccid3.c
+++ b/net/dccp/ccids/ccid3.c
@@ -60,13 +60,11 @@ static u32 usecs_div(const u32 a, const u32 b)
60 return (b >= 2 * div) ? tmp / (b / div) : tmp; 60 return (b >= 2 * div) ? tmp / (b / div) : tmp;
61} 61}
62 62
63static int ccid3_debug;
64 63
65#ifdef CCID3_DEBUG 64
66#define ccid3_pr_debug(format, a...) \ 65#ifdef CONFIG_IP_DCCP_CCID3_DEBUG
67 do { if (ccid3_debug) \ 66static int ccid3_debug;
68 printk(KERN_DEBUG "%s: " format, __FUNCTION__, ##a); \ 67#define ccid3_pr_debug(format, a...) DCCP_PR_DEBUG(ccid3_debug, format, ##a)
69 } while (0)
70#else 68#else
71#define ccid3_pr_debug(format, a...) 69#define ccid3_pr_debug(format, a...)
72#endif 70#endif
@@ -75,7 +73,7 @@ static struct dccp_tx_hist *ccid3_tx_hist;
75static struct dccp_rx_hist *ccid3_rx_hist; 73static struct dccp_rx_hist *ccid3_rx_hist;
76static struct dccp_li_hist *ccid3_li_hist; 74static struct dccp_li_hist *ccid3_li_hist;
77 75
78#ifdef CCID3_DEBUG 76#ifdef CONFIG_IP_DCCP_CCID3_DEBUG
79static const char *ccid3_tx_state_name(enum ccid3_hc_tx_states state) 77static const char *ccid3_tx_state_name(enum ccid3_hc_tx_states state)
80{ 78{
81 static char *ccid3_state_names[] = { 79 static char *ccid3_state_names[] = {
@@ -676,7 +674,7 @@ static void ccid3_hc_tx_exit(struct sock *sk)
676 * RX Half Connection methods 674 * RX Half Connection methods
677 */ 675 */
678 676
679#ifdef CCID3_DEBUG 677#ifdef CONFIG_IP_DCCP_CCID3_DEBUG
680static const char *ccid3_rx_state_name(enum ccid3_hc_rx_states state) 678static const char *ccid3_rx_state_name(enum ccid3_hc_rx_states state)
681{ 679{
682 static char *ccid3_rx_state_names[] = { 680 static char *ccid3_rx_state_names[] = {
@@ -1240,8 +1238,10 @@ static struct ccid_operations ccid3 = {
1240 .ccid_hc_tx_getsockopt = ccid3_hc_tx_getsockopt, 1238 .ccid_hc_tx_getsockopt = ccid3_hc_tx_getsockopt,
1241}; 1239};
1242 1240
1241#ifdef CONFIG_IP_DCCP_CCID3_DEBUG
1243module_param(ccid3_debug, int, 0444); 1242module_param(ccid3_debug, int, 0444);
1244MODULE_PARM_DESC(ccid3_debug, "Enable debug messages"); 1243MODULE_PARM_DESC(ccid3_debug, "Enable debug messages");
1244#endif
1245 1245
1246static __init int ccid3_module_init(void) 1246static __init int ccid3_module_init(void)
1247{ 1247{