diff options
author | Joe Perches <joe@perches.com> | 2014-11-11 17:44:57 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-11-12 13:56:41 -0500 |
commit | 955a9d202f470019f42979f0d1caec98843e39ce (patch) | |
tree | fff6124b339bc33e3b5c67668bfcc13098be865c /net/irda/irlan | |
parent | 8d326d818a2a8fc80c7df85dd88cb214804d1499 (diff) |
irda: Convert IRDA_DEBUG to pr_debug
Use the normal kernel debugging mechanism which also
enables dynamic_debug at the same time.
Other miscellanea:
o Remove sysctl for irda_debug
o Remove function tracing like uses (use ftrace instead)
o Coalesce formats
o Realign arguments
o Remove unnecessary OOM messages
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/irda/irlan')
-rw-r--r-- | net/irda/irlan/irlan_client.c | 64 | ||||
-rw-r--r-- | net/irda/irlan/irlan_client_event.c | 62 | ||||
-rw-r--r-- | net/irda/irlan/irlan_common.c | 77 | ||||
-rw-r--r-- | net/irda/irlan/irlan_eth.c | 24 | ||||
-rw-r--r-- | net/irda/irlan/irlan_event.c | 4 | ||||
-rw-r--r-- | net/irda/irlan/irlan_filter.c | 23 | ||||
-rw-r--r-- | net/irda/irlan/irlan_provider.c | 42 | ||||
-rw-r--r-- | net/irda/irlan/irlan_provider_event.c | 16 |
8 files changed, 106 insertions, 206 deletions
diff --git a/net/irda/irlan/irlan_client.c b/net/irda/irlan/irlan_client.c index f8eea02843f5..c5837a40c78e 100644 --- a/net/irda/irlan/irlan_client.c +++ b/net/irda/irlan/irlan_client.c | |||
@@ -72,8 +72,6 @@ static void irlan_client_kick_timer_expired(void *data) | |||
72 | { | 72 | { |
73 | struct irlan_cb *self = (struct irlan_cb *) data; | 73 | struct irlan_cb *self = (struct irlan_cb *) data; |
74 | 74 | ||
75 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
76 | |||
77 | IRDA_ASSERT(self != NULL, return;); | 75 | IRDA_ASSERT(self != NULL, return;); |
78 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 76 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
79 | 77 | ||
@@ -91,8 +89,6 @@ static void irlan_client_kick_timer_expired(void *data) | |||
91 | 89 | ||
92 | static void irlan_client_start_kick_timer(struct irlan_cb *self, int timeout) | 90 | static void irlan_client_start_kick_timer(struct irlan_cb *self, int timeout) |
93 | { | 91 | { |
94 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
95 | |||
96 | irda_start_timer(&self->client.kick_timer, timeout, (void *) self, | 92 | irda_start_timer(&self->client.kick_timer, timeout, (void *) self, |
97 | irlan_client_kick_timer_expired); | 93 | irlan_client_kick_timer_expired); |
98 | } | 94 | } |
@@ -105,8 +101,6 @@ static void irlan_client_start_kick_timer(struct irlan_cb *self, int timeout) | |||
105 | */ | 101 | */ |
106 | void irlan_client_wakeup(struct irlan_cb *self, __u32 saddr, __u32 daddr) | 102 | void irlan_client_wakeup(struct irlan_cb *self, __u32 saddr, __u32 daddr) |
107 | { | 103 | { |
108 | IRDA_DEBUG(1, "%s()\n", __func__ ); | ||
109 | |||
110 | IRDA_ASSERT(self != NULL, return;); | 104 | IRDA_ASSERT(self != NULL, return;); |
111 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 105 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
112 | 106 | ||
@@ -117,7 +111,7 @@ void irlan_client_wakeup(struct irlan_cb *self, __u32 saddr, __u32 daddr) | |||
117 | if ((self->client.state != IRLAN_IDLE) || | 111 | if ((self->client.state != IRLAN_IDLE) || |
118 | (self->provider.access_type == ACCESS_DIRECT)) | 112 | (self->provider.access_type == ACCESS_DIRECT)) |
119 | { | 113 | { |
120 | IRDA_DEBUG(0, "%s(), already awake!\n", __func__ ); | 114 | pr_debug("%s(), already awake!\n", __func__); |
121 | return; | 115 | return; |
122 | } | 116 | } |
123 | 117 | ||
@@ -126,7 +120,7 @@ void irlan_client_wakeup(struct irlan_cb *self, __u32 saddr, __u32 daddr) | |||
126 | self->daddr = daddr; | 120 | self->daddr = daddr; |
127 | 121 | ||
128 | if (self->disconnect_reason == LM_USER_REQUEST) { | 122 | if (self->disconnect_reason == LM_USER_REQUEST) { |
129 | IRDA_DEBUG(0, "%s(), still stopped by user\n", __func__ ); | 123 | pr_debug("%s(), still stopped by user\n", __func__); |
130 | return; | 124 | return; |
131 | } | 125 | } |
132 | 126 | ||
@@ -153,8 +147,6 @@ void irlan_client_discovery_indication(discinfo_t *discovery, | |||
153 | struct irlan_cb *self; | 147 | struct irlan_cb *self; |
154 | __u32 saddr, daddr; | 148 | __u32 saddr, daddr; |
155 | 149 | ||
156 | IRDA_DEBUG(1, "%s()\n", __func__ ); | ||
157 | |||
158 | IRDA_ASSERT(discovery != NULL, return;); | 150 | IRDA_ASSERT(discovery != NULL, return;); |
159 | 151 | ||
160 | /* | 152 | /* |
@@ -175,8 +167,8 @@ void irlan_client_discovery_indication(discinfo_t *discovery, | |||
175 | if (self) { | 167 | if (self) { |
176 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, goto out;); | 168 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, goto out;); |
177 | 169 | ||
178 | IRDA_DEBUG(1, "%s(), Found instance (%08x)!\n", __func__ , | 170 | pr_debug("%s(), Found instance (%08x)!\n", __func__ , |
179 | daddr); | 171 | daddr); |
180 | 172 | ||
181 | irlan_client_wakeup(self, saddr, daddr); | 173 | irlan_client_wakeup(self, saddr, daddr); |
182 | } | 174 | } |
@@ -195,8 +187,6 @@ static int irlan_client_ctrl_data_indication(void *instance, void *sap, | |||
195 | { | 187 | { |
196 | struct irlan_cb *self; | 188 | struct irlan_cb *self; |
197 | 189 | ||
198 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
199 | |||
200 | self = instance; | 190 | self = instance; |
201 | 191 | ||
202 | IRDA_ASSERT(self != NULL, return -1;); | 192 | IRDA_ASSERT(self != NULL, return -1;); |
@@ -206,7 +196,7 @@ static int irlan_client_ctrl_data_indication(void *instance, void *sap, | |||
206 | irlan_do_client_event(self, IRLAN_DATA_INDICATION, skb); | 196 | irlan_do_client_event(self, IRLAN_DATA_INDICATION, skb); |
207 | 197 | ||
208 | /* Ready for a new command */ | 198 | /* Ready for a new command */ |
209 | IRDA_DEBUG(2, "%s(), clearing tx_busy\n", __func__ ); | 199 | pr_debug("%s(), clearing tx_busy\n", __func__); |
210 | self->client.tx_busy = FALSE; | 200 | self->client.tx_busy = FALSE; |
211 | 201 | ||
212 | /* Check if we have some queued commands waiting to be sent */ | 202 | /* Check if we have some queued commands waiting to be sent */ |
@@ -223,7 +213,7 @@ static void irlan_client_ctrl_disconnect_indication(void *instance, void *sap, | |||
223 | struct tsap_cb *tsap; | 213 | struct tsap_cb *tsap; |
224 | struct sk_buff *skb; | 214 | struct sk_buff *skb; |
225 | 215 | ||
226 | IRDA_DEBUG(4, "%s(), reason=%d\n", __func__ , reason); | 216 | pr_debug("%s(), reason=%d\n", __func__ , reason); |
227 | 217 | ||
228 | self = instance; | 218 | self = instance; |
229 | tsap = sap; | 219 | tsap = sap; |
@@ -255,8 +245,6 @@ static void irlan_client_open_ctrl_tsap(struct irlan_cb *self) | |||
255 | struct tsap_cb *tsap; | 245 | struct tsap_cb *tsap; |
256 | notify_t notify; | 246 | notify_t notify; |
257 | 247 | ||
258 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
259 | |||
260 | IRDA_ASSERT(self != NULL, return;); | 248 | IRDA_ASSERT(self != NULL, return;); |
261 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 249 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
262 | 250 | ||
@@ -275,7 +263,7 @@ static void irlan_client_open_ctrl_tsap(struct irlan_cb *self) | |||
275 | 263 | ||
276 | tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, ¬ify); | 264 | tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, ¬ify); |
277 | if (!tsap) { | 265 | if (!tsap) { |
278 | IRDA_DEBUG(2, "%s(), Got no tsap!\n", __func__ ); | 266 | pr_debug("%s(), Got no tsap!\n", __func__); |
279 | return; | 267 | return; |
280 | } | 268 | } |
281 | self->client.tsap_ctrl = tsap; | 269 | self->client.tsap_ctrl = tsap; |
@@ -295,8 +283,6 @@ static void irlan_client_ctrl_connect_confirm(void *instance, void *sap, | |||
295 | { | 283 | { |
296 | struct irlan_cb *self; | 284 | struct irlan_cb *self; |
297 | 285 | ||
298 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
299 | |||
300 | self = instance; | 286 | self = instance; |
301 | 287 | ||
302 | IRDA_ASSERT(self != NULL, return;); | 288 | IRDA_ASSERT(self != NULL, return;); |
@@ -374,7 +360,7 @@ void irlan_client_parse_response(struct irlan_cb *self, struct sk_buff *skb) | |||
374 | 360 | ||
375 | IRDA_ASSERT(skb != NULL, return;); | 361 | IRDA_ASSERT(skb != NULL, return;); |
376 | 362 | ||
377 | IRDA_DEBUG(4, "%s() skb->len=%d\n", __func__ , (int) skb->len); | 363 | pr_debug("%s() skb->len=%d\n", __func__ , (int)skb->len); |
378 | 364 | ||
379 | IRDA_ASSERT(self != NULL, return;); | 365 | IRDA_ASSERT(self != NULL, return;); |
380 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 366 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
@@ -405,7 +391,7 @@ void irlan_client_parse_response(struct irlan_cb *self, struct sk_buff *skb) | |||
405 | /* How many parameters? */ | 391 | /* How many parameters? */ |
406 | count = frame[1]; | 392 | count = frame[1]; |
407 | 393 | ||
408 | IRDA_DEBUG(4, "%s(), got %d parameters\n", __func__ , count); | 394 | pr_debug("%s(), got %d parameters\n", __func__ , count); |
409 | 395 | ||
410 | ptr = frame+2; | 396 | ptr = frame+2; |
411 | 397 | ||
@@ -413,7 +399,7 @@ void irlan_client_parse_response(struct irlan_cb *self, struct sk_buff *skb) | |||
413 | for (i=0; i<count;i++) { | 399 | for (i=0; i<count;i++) { |
414 | ret = irlan_extract_param(ptr, name, value, &val_len); | 400 | ret = irlan_extract_param(ptr, name, value, &val_len); |
415 | if (ret < 0) { | 401 | if (ret < 0) { |
416 | IRDA_DEBUG(2, "%s(), IrLAN, Error!\n", __func__ ); | 402 | pr_debug("%s(), IrLAN, Error!\n", __func__); |
417 | break; | 403 | break; |
418 | } | 404 | } |
419 | ptr += ret; | 405 | ptr += ret; |
@@ -437,7 +423,7 @@ static void irlan_check_response_param(struct irlan_cb *self, char *param, | |||
437 | __u8 *bytes; | 423 | __u8 *bytes; |
438 | int i; | 424 | int i; |
439 | 425 | ||
440 | IRDA_DEBUG(4, "%s(), parm=%s\n", __func__ , param); | 426 | pr_debug("%s(), parm=%s\n", __func__ , param); |
441 | 427 | ||
442 | IRDA_ASSERT(self != NULL, return;); | 428 | IRDA_ASSERT(self != NULL, return;); |
443 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 429 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
@@ -475,13 +461,13 @@ static void irlan_check_response_param(struct irlan_cb *self, char *param, | |||
475 | else if (strcmp(value, "HOSTED") == 0) | 461 | else if (strcmp(value, "HOSTED") == 0) |
476 | self->client.access_type = ACCESS_HOSTED; | 462 | self->client.access_type = ACCESS_HOSTED; |
477 | else { | 463 | else { |
478 | IRDA_DEBUG(2, "%s(), unknown access type!\n", __func__ ); | 464 | pr_debug("%s(), unknown access type!\n", __func__); |
479 | } | 465 | } |
480 | } | 466 | } |
481 | /* IRLAN version */ | 467 | /* IRLAN version */ |
482 | if (strcmp(param, "IRLAN_VER") == 0) { | 468 | if (strcmp(param, "IRLAN_VER") == 0) { |
483 | IRDA_DEBUG(4, "IrLAN version %d.%d\n", (__u8) value[0], | 469 | pr_debug("IrLAN version %d.%d\n", (__u8)value[0], |
484 | (__u8) value[1]); | 470 | (__u8)value[1]); |
485 | 471 | ||
486 | self->version[0] = value[0]; | 472 | self->version[0] = value[0]; |
487 | self->version[1] = value[1]; | 473 | self->version[1] = value[1]; |
@@ -490,37 +476,37 @@ static void irlan_check_response_param(struct irlan_cb *self, char *param, | |||
490 | /* Which remote TSAP to use for data channel */ | 476 | /* Which remote TSAP to use for data channel */ |
491 | if (strcmp(param, "DATA_CHAN") == 0) { | 477 | if (strcmp(param, "DATA_CHAN") == 0) { |
492 | self->dtsap_sel_data = value[0]; | 478 | self->dtsap_sel_data = value[0]; |
493 | IRDA_DEBUG(4, "Data TSAP = %02x\n", self->dtsap_sel_data); | 479 | pr_debug("Data TSAP = %02x\n", self->dtsap_sel_data); |
494 | return; | 480 | return; |
495 | } | 481 | } |
496 | if (strcmp(param, "CON_ARB") == 0) { | 482 | if (strcmp(param, "CON_ARB") == 0) { |
497 | memcpy(&tmp_cpu, value, 2); /* Align value */ | 483 | memcpy(&tmp_cpu, value, 2); /* Align value */ |
498 | le16_to_cpus(&tmp_cpu); /* Convert to host order */ | 484 | le16_to_cpus(&tmp_cpu); /* Convert to host order */ |
499 | self->client.recv_arb_val = tmp_cpu; | 485 | self->client.recv_arb_val = tmp_cpu; |
500 | IRDA_DEBUG(2, "%s(), receive arb val=%d\n", __func__ , | 486 | pr_debug("%s(), receive arb val=%d\n", __func__ , |
501 | self->client.recv_arb_val); | 487 | self->client.recv_arb_val); |
502 | } | 488 | } |
503 | if (strcmp(param, "MAX_FRAME") == 0) { | 489 | if (strcmp(param, "MAX_FRAME") == 0) { |
504 | memcpy(&tmp_cpu, value, 2); /* Align value */ | 490 | memcpy(&tmp_cpu, value, 2); /* Align value */ |
505 | le16_to_cpus(&tmp_cpu); /* Convert to host order */ | 491 | le16_to_cpus(&tmp_cpu); /* Convert to host order */ |
506 | self->client.max_frame = tmp_cpu; | 492 | self->client.max_frame = tmp_cpu; |
507 | IRDA_DEBUG(4, "%s(), max frame=%d\n", __func__ , | 493 | pr_debug("%s(), max frame=%d\n", __func__ , |
508 | self->client.max_frame); | 494 | self->client.max_frame); |
509 | } | 495 | } |
510 | 496 | ||
511 | /* RECONNECT_KEY, in case the link goes down! */ | 497 | /* RECONNECT_KEY, in case the link goes down! */ |
512 | if (strcmp(param, "RECONNECT_KEY") == 0) { | 498 | if (strcmp(param, "RECONNECT_KEY") == 0) { |
513 | IRDA_DEBUG(4, "Got reconnect key: "); | 499 | pr_debug("Got reconnect key: "); |
514 | /* for (i = 0; i < val_len; i++) */ | 500 | /* for (i = 0; i < val_len; i++) */ |
515 | /* printk("%02x", value[i]); */ | 501 | /* printk("%02x", value[i]); */ |
516 | memcpy(self->client.reconnect_key, value, val_len); | 502 | memcpy(self->client.reconnect_key, value, val_len); |
517 | self->client.key_len = val_len; | 503 | self->client.key_len = val_len; |
518 | IRDA_DEBUG(4, "\n"); | 504 | pr_debug("\n"); |
519 | } | 505 | } |
520 | /* FILTER_ENTRY, have we got an ethernet address? */ | 506 | /* FILTER_ENTRY, have we got an ethernet address? */ |
521 | if (strcmp(param, "FILTER_ENTRY") == 0) { | 507 | if (strcmp(param, "FILTER_ENTRY") == 0) { |
522 | bytes = value; | 508 | bytes = value; |
523 | IRDA_DEBUG(4, "Ethernet address = %pM\n", bytes); | 509 | pr_debug("Ethernet address = %pM\n", bytes); |
524 | for (i = 0; i < 6; i++) | 510 | for (i = 0; i < 6; i++) |
525 | self->dev->dev_addr[i] = bytes[i]; | 511 | self->dev->dev_addr[i] = bytes[i]; |
526 | } | 512 | } |
@@ -537,8 +523,6 @@ void irlan_client_get_value_confirm(int result, __u16 obj_id, | |||
537 | { | 523 | { |
538 | struct irlan_cb *self; | 524 | struct irlan_cb *self; |
539 | 525 | ||
540 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
541 | |||
542 | IRDA_ASSERT(priv != NULL, return;); | 526 | IRDA_ASSERT(priv != NULL, return;); |
543 | 527 | ||
544 | self = priv; | 528 | self = priv; |
@@ -550,7 +534,7 @@ void irlan_client_get_value_confirm(int result, __u16 obj_id, | |||
550 | 534 | ||
551 | /* Check if request succeeded */ | 535 | /* Check if request succeeded */ |
552 | if (result != IAS_SUCCESS) { | 536 | if (result != IAS_SUCCESS) { |
553 | IRDA_DEBUG(2, "%s(), got NULL value!\n", __func__ ); | 537 | pr_debug("%s(), got NULL value!\n", __func__); |
554 | irlan_do_client_event(self, IRLAN_IAS_PROVIDER_NOT_AVAIL, | 538 | irlan_do_client_event(self, IRLAN_IAS_PROVIDER_NOT_AVAIL, |
555 | NULL); | 539 | NULL); |
556 | return; | 540 | return; |
@@ -568,7 +552,7 @@ void irlan_client_get_value_confirm(int result, __u16 obj_id, | |||
568 | irias_delete_value(value); | 552 | irias_delete_value(value); |
569 | break; | 553 | break; |
570 | default: | 554 | default: |
571 | IRDA_DEBUG(2, "%s(), unknown type!\n", __func__ ); | 555 | pr_debug("%s(), unknown type!\n", __func__); |
572 | break; | 556 | break; |
573 | } | 557 | } |
574 | irlan_do_client_event(self, IRLAN_IAS_PROVIDER_NOT_AVAIL, NULL); | 558 | irlan_do_client_event(self, IRLAN_IAS_PROVIDER_NOT_AVAIL, NULL); |
diff --git a/net/irda/irlan/irlan_client_event.c b/net/irda/irlan/irlan_client_event.c index f9d11bf38157..cc93fabbbb19 100644 --- a/net/irda/irlan/irlan_client_event.c +++ b/net/irda/irlan/irlan_client_event.c | |||
@@ -92,8 +92,6 @@ void irlan_do_client_event(struct irlan_cb *self, IRLAN_EVENT event, | |||
92 | static int irlan_client_state_idle(struct irlan_cb *self, IRLAN_EVENT event, | 92 | static int irlan_client_state_idle(struct irlan_cb *self, IRLAN_EVENT event, |
93 | struct sk_buff *skb) | 93 | struct sk_buff *skb) |
94 | { | 94 | { |
95 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
96 | |||
97 | IRDA_ASSERT(self != NULL, return -1;); | 95 | IRDA_ASSERT(self != NULL, return -1;); |
98 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); | 96 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); |
99 | 97 | ||
@@ -114,10 +112,10 @@ static int irlan_client_state_idle(struct irlan_cb *self, IRLAN_EVENT event, | |||
114 | "IrLAN", "IrDA:TinyTP:LsapSel"); | 112 | "IrLAN", "IrDA:TinyTP:LsapSel"); |
115 | break; | 113 | break; |
116 | case IRLAN_WATCHDOG_TIMEOUT: | 114 | case IRLAN_WATCHDOG_TIMEOUT: |
117 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 115 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
118 | break; | 116 | break; |
119 | default: | 117 | default: |
120 | IRDA_DEBUG(4, "%s(), Unknown event %d\n", __func__ , event); | 118 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
121 | break; | 119 | break; |
122 | } | 120 | } |
123 | if (skb) | 121 | if (skb) |
@@ -136,8 +134,6 @@ static int irlan_client_state_idle(struct irlan_cb *self, IRLAN_EVENT event, | |||
136 | static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, | 134 | static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, |
137 | struct sk_buff *skb) | 135 | struct sk_buff *skb) |
138 | { | 136 | { |
139 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
140 | |||
141 | IRDA_ASSERT(self != NULL, return -1;); | 137 | IRDA_ASSERT(self != NULL, return -1;); |
142 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); | 138 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); |
143 | 139 | ||
@@ -154,7 +150,7 @@ static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, | |||
154 | irlan_next_client_state(self, IRLAN_CONN); | 150 | irlan_next_client_state(self, IRLAN_CONN); |
155 | break; | 151 | break; |
156 | case IRLAN_IAS_PROVIDER_NOT_AVAIL: | 152 | case IRLAN_IAS_PROVIDER_NOT_AVAIL: |
157 | IRDA_DEBUG(2, "%s(), IAS_PROVIDER_NOT_AVAIL\n", __func__ ); | 153 | pr_debug("%s(), IAS_PROVIDER_NOT_AVAIL\n", __func__); |
158 | irlan_next_client_state(self, IRLAN_IDLE); | 154 | irlan_next_client_state(self, IRLAN_IDLE); |
159 | 155 | ||
160 | /* Give the client a kick! */ | 156 | /* Give the client a kick! */ |
@@ -167,10 +163,10 @@ static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, | |||
167 | irlan_next_client_state(self, IRLAN_IDLE); | 163 | irlan_next_client_state(self, IRLAN_IDLE); |
168 | break; | 164 | break; |
169 | case IRLAN_WATCHDOG_TIMEOUT: | 165 | case IRLAN_WATCHDOG_TIMEOUT: |
170 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 166 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
171 | break; | 167 | break; |
172 | default: | 168 | default: |
173 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 169 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
174 | break; | 170 | break; |
175 | } | 171 | } |
176 | if (skb) | 172 | if (skb) |
@@ -189,8 +185,6 @@ static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, | |||
189 | static int irlan_client_state_conn(struct irlan_cb *self, IRLAN_EVENT event, | 185 | static int irlan_client_state_conn(struct irlan_cb *self, IRLAN_EVENT event, |
190 | struct sk_buff *skb) | 186 | struct sk_buff *skb) |
191 | { | 187 | { |
192 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
193 | |||
194 | IRDA_ASSERT(self != NULL, return -1;); | 188 | IRDA_ASSERT(self != NULL, return -1;); |
195 | 189 | ||
196 | switch (event) { | 190 | switch (event) { |
@@ -204,10 +198,10 @@ static int irlan_client_state_conn(struct irlan_cb *self, IRLAN_EVENT event, | |||
204 | irlan_next_client_state(self, IRLAN_IDLE); | 198 | irlan_next_client_state(self, IRLAN_IDLE); |
205 | break; | 199 | break; |
206 | case IRLAN_WATCHDOG_TIMEOUT: | 200 | case IRLAN_WATCHDOG_TIMEOUT: |
207 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 201 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
208 | break; | 202 | break; |
209 | default: | 203 | default: |
210 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 204 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
211 | break; | 205 | break; |
212 | } | 206 | } |
213 | if (skb) | 207 | if (skb) |
@@ -224,8 +218,6 @@ static int irlan_client_state_conn(struct irlan_cb *self, IRLAN_EVENT event, | |||
224 | static int irlan_client_state_info(struct irlan_cb *self, IRLAN_EVENT event, | 218 | static int irlan_client_state_info(struct irlan_cb *self, IRLAN_EVENT event, |
225 | struct sk_buff *skb) | 219 | struct sk_buff *skb) |
226 | { | 220 | { |
227 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
228 | |||
229 | IRDA_ASSERT(self != NULL, return -1;); | 221 | IRDA_ASSERT(self != NULL, return -1;); |
230 | 222 | ||
231 | switch (event) { | 223 | switch (event) { |
@@ -244,10 +236,10 @@ static int irlan_client_state_info(struct irlan_cb *self, IRLAN_EVENT event, | |||
244 | irlan_next_client_state(self, IRLAN_IDLE); | 236 | irlan_next_client_state(self, IRLAN_IDLE); |
245 | break; | 237 | break; |
246 | case IRLAN_WATCHDOG_TIMEOUT: | 238 | case IRLAN_WATCHDOG_TIMEOUT: |
247 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 239 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
248 | break; | 240 | break; |
249 | default: | 241 | default: |
250 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 242 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
251 | break; | 243 | break; |
252 | } | 244 | } |
253 | if (skb) | 245 | if (skb) |
@@ -266,8 +258,6 @@ static int irlan_client_state_info(struct irlan_cb *self, IRLAN_EVENT event, | |||
266 | static int irlan_client_state_media(struct irlan_cb *self, IRLAN_EVENT event, | 258 | static int irlan_client_state_media(struct irlan_cb *self, IRLAN_EVENT event, |
267 | struct sk_buff *skb) | 259 | struct sk_buff *skb) |
268 | { | 260 | { |
269 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
270 | |||
271 | IRDA_ASSERT(self != NULL, return -1;); | 261 | IRDA_ASSERT(self != NULL, return -1;); |
272 | 262 | ||
273 | switch(event) { | 263 | switch(event) { |
@@ -281,10 +271,10 @@ static int irlan_client_state_media(struct irlan_cb *self, IRLAN_EVENT event, | |||
281 | irlan_next_client_state(self, IRLAN_IDLE); | 271 | irlan_next_client_state(self, IRLAN_IDLE); |
282 | break; | 272 | break; |
283 | case IRLAN_WATCHDOG_TIMEOUT: | 273 | case IRLAN_WATCHDOG_TIMEOUT: |
284 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 274 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
285 | break; | 275 | break; |
286 | default: | 276 | default: |
287 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 277 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
288 | break; | 278 | break; |
289 | } | 279 | } |
290 | if (skb) | 280 | if (skb) |
@@ -305,8 +295,6 @@ static int irlan_client_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
305 | { | 295 | { |
306 | struct qos_info qos; | 296 | struct qos_info qos; |
307 | 297 | ||
308 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
309 | |||
310 | IRDA_ASSERT(self != NULL, return -1;); | 298 | IRDA_ASSERT(self != NULL, return -1;); |
311 | 299 | ||
312 | switch(event) { | 300 | switch(event) { |
@@ -344,7 +332,7 @@ static int irlan_client_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
344 | irlan_next_client_state(self, IRLAN_DATA); | 332 | irlan_next_client_state(self, IRLAN_DATA); |
345 | break; | 333 | break; |
346 | default: | 334 | default: |
347 | IRDA_DEBUG(2, "%s(), unknown access type!\n", __func__ ); | 335 | pr_debug("%s(), unknown access type!\n", __func__); |
348 | break; | 336 | break; |
349 | } | 337 | } |
350 | break; | 338 | break; |
@@ -353,10 +341,10 @@ static int irlan_client_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
353 | irlan_next_client_state(self, IRLAN_IDLE); | 341 | irlan_next_client_state(self, IRLAN_IDLE); |
354 | break; | 342 | break; |
355 | case IRLAN_WATCHDOG_TIMEOUT: | 343 | case IRLAN_WATCHDOG_TIMEOUT: |
356 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 344 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
357 | break; | 345 | break; |
358 | default: | 346 | default: |
359 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 347 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
360 | break; | 348 | break; |
361 | } | 349 | } |
362 | 350 | ||
@@ -376,8 +364,6 @@ static int irlan_client_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
376 | static int irlan_client_state_wait(struct irlan_cb *self, IRLAN_EVENT event, | 364 | static int irlan_client_state_wait(struct irlan_cb *self, IRLAN_EVENT event, |
377 | struct sk_buff *skb) | 365 | struct sk_buff *skb) |
378 | { | 366 | { |
379 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
380 | |||
381 | IRDA_ASSERT(self != NULL, return -1;); | 367 | IRDA_ASSERT(self != NULL, return -1;); |
382 | 368 | ||
383 | switch(event) { | 369 | switch(event) { |
@@ -390,10 +376,10 @@ static int irlan_client_state_wait(struct irlan_cb *self, IRLAN_EVENT event, | |||
390 | irlan_next_client_state(self, IRLAN_IDLE); | 376 | irlan_next_client_state(self, IRLAN_IDLE); |
391 | break; | 377 | break; |
392 | case IRLAN_WATCHDOG_TIMEOUT: | 378 | case IRLAN_WATCHDOG_TIMEOUT: |
393 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 379 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
394 | break; | 380 | break; |
395 | default: | 381 | default: |
396 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 382 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
397 | break; | 383 | break; |
398 | } | 384 | } |
399 | if (skb) | 385 | if (skb) |
@@ -407,8 +393,6 @@ static int irlan_client_state_arb(struct irlan_cb *self, IRLAN_EVENT event, | |||
407 | { | 393 | { |
408 | struct qos_info qos; | 394 | struct qos_info qos; |
409 | 395 | ||
410 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
411 | |||
412 | IRDA_ASSERT(self != NULL, return -1;); | 396 | IRDA_ASSERT(self != NULL, return -1;); |
413 | 397 | ||
414 | switch(event) { | 398 | switch(event) { |
@@ -429,7 +413,7 @@ static int irlan_client_state_arb(struct irlan_cb *self, IRLAN_EVENT event, | |||
429 | } else if (self->client.recv_arb_val > | 413 | } else if (self->client.recv_arb_val > |
430 | self->provider.send_arb_val) | 414 | self->provider.send_arb_val) |
431 | { | 415 | { |
432 | IRDA_DEBUG(2, "%s(), lost the battle :-(\n", __func__ ); | 416 | pr_debug("%s(), lost the battle :-(\n", __func__); |
433 | } | 417 | } |
434 | break; | 418 | break; |
435 | case IRLAN_DATA_CONNECT_INDICATION: | 419 | case IRLAN_DATA_CONNECT_INDICATION: |
@@ -440,10 +424,10 @@ static int irlan_client_state_arb(struct irlan_cb *self, IRLAN_EVENT event, | |||
440 | irlan_next_client_state(self, IRLAN_IDLE); | 424 | irlan_next_client_state(self, IRLAN_IDLE); |
441 | break; | 425 | break; |
442 | case IRLAN_WATCHDOG_TIMEOUT: | 426 | case IRLAN_WATCHDOG_TIMEOUT: |
443 | IRDA_DEBUG(2, "%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__ ); | 427 | pr_debug("%s(), IRLAN_WATCHDOG_TIMEOUT\n", __func__); |
444 | break; | 428 | break; |
445 | default: | 429 | default: |
446 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 430 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
447 | break; | 431 | break; |
448 | } | 432 | } |
449 | if (skb) | 433 | if (skb) |
@@ -462,8 +446,6 @@ static int irlan_client_state_arb(struct irlan_cb *self, IRLAN_EVENT event, | |||
462 | static int irlan_client_state_data(struct irlan_cb *self, IRLAN_EVENT event, | 446 | static int irlan_client_state_data(struct irlan_cb *self, IRLAN_EVENT event, |
463 | struct sk_buff *skb) | 447 | struct sk_buff *skb) |
464 | { | 448 | { |
465 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
466 | |||
467 | IRDA_ASSERT(self != NULL, return -1;); | 449 | IRDA_ASSERT(self != NULL, return -1;); |
468 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); | 450 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); |
469 | 451 | ||
@@ -476,7 +458,7 @@ static int irlan_client_state_data(struct irlan_cb *self, IRLAN_EVENT event, | |||
476 | irlan_next_client_state(self, IRLAN_IDLE); | 458 | irlan_next_client_state(self, IRLAN_IDLE); |
477 | break; | 459 | break; |
478 | default: | 460 | default: |
479 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 461 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
480 | break; | 462 | break; |
481 | } | 463 | } |
482 | if (skb) | 464 | if (skb) |
@@ -494,8 +476,6 @@ static int irlan_client_state_data(struct irlan_cb *self, IRLAN_EVENT event, | |||
494 | static int irlan_client_state_close(struct irlan_cb *self, IRLAN_EVENT event, | 476 | static int irlan_client_state_close(struct irlan_cb *self, IRLAN_EVENT event, |
495 | struct sk_buff *skb) | 477 | struct sk_buff *skb) |
496 | { | 478 | { |
497 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
498 | |||
499 | if (skb) | 479 | if (skb) |
500 | dev_kfree_skb(skb); | 480 | dev_kfree_skb(skb); |
501 | 481 | ||
@@ -511,8 +491,6 @@ static int irlan_client_state_close(struct irlan_cb *self, IRLAN_EVENT event, | |||
511 | static int irlan_client_state_sync(struct irlan_cb *self, IRLAN_EVENT event, | 491 | static int irlan_client_state_sync(struct irlan_cb *self, IRLAN_EVENT event, |
512 | struct sk_buff *skb) | 492 | struct sk_buff *skb) |
513 | { | 493 | { |
514 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
515 | |||
516 | if (skb) | 494 | if (skb) |
517 | dev_kfree_skb(skb); | 495 | dev_kfree_skb(skb); |
518 | 496 | ||
diff --git a/net/irda/irlan/irlan_common.c b/net/irda/irlan/irlan_common.c index cc60b4a282ae..481bbc2a4349 100644 --- a/net/irda/irlan/irlan_common.c +++ b/net/irda/irlan/irlan_common.c | |||
@@ -118,8 +118,6 @@ static int __init irlan_init(void) | |||
118 | struct irlan_cb *new; | 118 | struct irlan_cb *new; |
119 | __u16 hints; | 119 | __u16 hints; |
120 | 120 | ||
121 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
122 | |||
123 | #ifdef CONFIG_PROC_FS | 121 | #ifdef CONFIG_PROC_FS |
124 | { struct proc_dir_entry *proc; | 122 | { struct proc_dir_entry *proc; |
125 | proc = proc_create("irlan", 0, proc_irda, &irlan_fops); | 123 | proc = proc_create("irlan", 0, proc_irda, &irlan_fops); |
@@ -130,7 +128,6 @@ static int __init irlan_init(void) | |||
130 | } | 128 | } |
131 | #endif /* CONFIG_PROC_FS */ | 129 | #endif /* CONFIG_PROC_FS */ |
132 | 130 | ||
133 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
134 | hints = irlmp_service_to_hint(S_LAN); | 131 | hints = irlmp_service_to_hint(S_LAN); |
135 | 132 | ||
136 | /* Register with IrLMP as a client */ | 133 | /* Register with IrLMP as a client */ |
@@ -173,8 +170,6 @@ static void __exit irlan_cleanup(void) | |||
173 | { | 170 | { |
174 | struct irlan_cb *self, *next; | 171 | struct irlan_cb *self, *next; |
175 | 172 | ||
176 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
177 | |||
178 | irlmp_unregister_client(ckey); | 173 | irlmp_unregister_client(ckey); |
179 | irlmp_unregister_service(skey); | 174 | irlmp_unregister_service(skey); |
180 | 175 | ||
@@ -201,8 +196,6 @@ static struct irlan_cb __init *irlan_open(__u32 saddr, __u32 daddr) | |||
201 | struct net_device *dev; | 196 | struct net_device *dev; |
202 | struct irlan_cb *self; | 197 | struct irlan_cb *self; |
203 | 198 | ||
204 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
205 | |||
206 | /* Create network device with irlan */ | 199 | /* Create network device with irlan */ |
207 | dev = alloc_irlandev(eth ? "eth%d" : "irlan%d"); | 200 | dev = alloc_irlandev(eth ? "eth%d" : "irlan%d"); |
208 | if (!dev) | 201 | if (!dev) |
@@ -245,8 +238,8 @@ static struct irlan_cb __init *irlan_open(__u32 saddr, __u32 daddr) | |||
245 | irlan_next_provider_state(self, IRLAN_IDLE); | 238 | irlan_next_provider_state(self, IRLAN_IDLE); |
246 | 239 | ||
247 | if (register_netdev(dev)) { | 240 | if (register_netdev(dev)) { |
248 | IRDA_DEBUG(2, "%s(), register_netdev() failed!\n", | 241 | pr_debug("%s(), register_netdev() failed!\n", |
249 | __func__ ); | 242 | __func__); |
250 | self = NULL; | 243 | self = NULL; |
251 | free_netdev(dev); | 244 | free_netdev(dev); |
252 | } else { | 245 | } else { |
@@ -266,8 +259,6 @@ static struct irlan_cb __init *irlan_open(__u32 saddr, __u32 daddr) | |||
266 | */ | 259 | */ |
267 | static void __irlan_close(struct irlan_cb *self) | 260 | static void __irlan_close(struct irlan_cb *self) |
268 | { | 261 | { |
269 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
270 | |||
271 | ASSERT_RTNL(); | 262 | ASSERT_RTNL(); |
272 | IRDA_ASSERT(self != NULL, return;); | 263 | IRDA_ASSERT(self != NULL, return;); |
273 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 264 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
@@ -314,8 +305,6 @@ static void irlan_connect_indication(void *instance, void *sap, | |||
314 | struct irlan_cb *self; | 305 | struct irlan_cb *self; |
315 | struct tsap_cb *tsap; | 306 | struct tsap_cb *tsap; |
316 | 307 | ||
317 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
318 | |||
319 | self = instance; | 308 | self = instance; |
320 | tsap = sap; | 309 | tsap = sap; |
321 | 310 | ||
@@ -326,7 +315,7 @@ static void irlan_connect_indication(void *instance, void *sap, | |||
326 | self->max_sdu_size = max_sdu_size; | 315 | self->max_sdu_size = max_sdu_size; |
327 | self->max_header_size = max_header_size; | 316 | self->max_header_size = max_header_size; |
328 | 317 | ||
329 | IRDA_DEBUG(0, "%s: We are now connected!\n", __func__); | 318 | pr_debug("%s: We are now connected!\n", __func__); |
330 | 319 | ||
331 | del_timer(&self->watchdog_timer); | 320 | del_timer(&self->watchdog_timer); |
332 | 321 | ||
@@ -370,7 +359,7 @@ static void irlan_connect_confirm(void *instance, void *sap, | |||
370 | 359 | ||
371 | /* TODO: we could set the MTU depending on the max_sdu_size */ | 360 | /* TODO: we could set the MTU depending on the max_sdu_size */ |
372 | 361 | ||
373 | IRDA_DEBUG(0, "%s: We are now connected!\n", __func__); | 362 | pr_debug("%s: We are now connected!\n", __func__); |
374 | del_timer(&self->watchdog_timer); | 363 | del_timer(&self->watchdog_timer); |
375 | 364 | ||
376 | /* | 365 | /* |
@@ -403,7 +392,7 @@ static void irlan_disconnect_indication(void *instance, | |||
403 | struct irlan_cb *self; | 392 | struct irlan_cb *self; |
404 | struct tsap_cb *tsap; | 393 | struct tsap_cb *tsap; |
405 | 394 | ||
406 | IRDA_DEBUG(0, "%s(), reason=%d\n", __func__ , reason); | 395 | pr_debug("%s(), reason=%d\n", __func__ , reason); |
407 | 396 | ||
408 | self = instance; | 397 | self = instance; |
409 | tsap = sap; | 398 | tsap = sap; |
@@ -415,26 +404,26 @@ static void irlan_disconnect_indication(void *instance, | |||
415 | 404 | ||
416 | IRDA_ASSERT(tsap == self->tsap_data, return;); | 405 | IRDA_ASSERT(tsap == self->tsap_data, return;); |
417 | 406 | ||
418 | IRDA_DEBUG(2, "IrLAN, data channel disconnected by peer!\n"); | 407 | pr_debug("IrLAN, data channel disconnected by peer!\n"); |
419 | 408 | ||
420 | /* Save reason so we know if we should try to reconnect or not */ | 409 | /* Save reason so we know if we should try to reconnect or not */ |
421 | self->disconnect_reason = reason; | 410 | self->disconnect_reason = reason; |
422 | 411 | ||
423 | switch (reason) { | 412 | switch (reason) { |
424 | case LM_USER_REQUEST: /* User request */ | 413 | case LM_USER_REQUEST: /* User request */ |
425 | IRDA_DEBUG(2, "%s(), User requested\n", __func__ ); | 414 | pr_debug("%s(), User requested\n", __func__); |
426 | break; | 415 | break; |
427 | case LM_LAP_DISCONNECT: /* Unexpected IrLAP disconnect */ | 416 | case LM_LAP_DISCONNECT: /* Unexpected IrLAP disconnect */ |
428 | IRDA_DEBUG(2, "%s(), Unexpected IrLAP disconnect\n", __func__ ); | 417 | pr_debug("%s(), Unexpected IrLAP disconnect\n", __func__); |
429 | break; | 418 | break; |
430 | case LM_CONNECT_FAILURE: /* Failed to establish IrLAP connection */ | 419 | case LM_CONNECT_FAILURE: /* Failed to establish IrLAP connection */ |
431 | IRDA_DEBUG(2, "%s(), IrLAP connect failed\n", __func__ ); | 420 | pr_debug("%s(), IrLAP connect failed\n", __func__); |
432 | break; | 421 | break; |
433 | case LM_LAP_RESET: /* IrLAP reset */ | 422 | case LM_LAP_RESET: /* IrLAP reset */ |
434 | IRDA_DEBUG(2, "%s(), IrLAP reset\n", __func__ ); | 423 | pr_debug("%s(), IrLAP reset\n", __func__); |
435 | break; | 424 | break; |
436 | case LM_INIT_DISCONNECT: | 425 | case LM_INIT_DISCONNECT: |
437 | IRDA_DEBUG(2, "%s(), IrLMP connect failed\n", __func__ ); | 426 | pr_debug("%s(), IrLMP connect failed\n", __func__); |
438 | break; | 427 | break; |
439 | default: | 428 | default: |
440 | net_err_ratelimited("%s(), Unknown disconnect reason\n", | 429 | net_err_ratelimited("%s(), Unknown disconnect reason\n", |
@@ -460,8 +449,6 @@ void irlan_open_data_tsap(struct irlan_cb *self) | |||
460 | struct tsap_cb *tsap; | 449 | struct tsap_cb *tsap; |
461 | notify_t notify; | 450 | notify_t notify; |
462 | 451 | ||
463 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
464 | |||
465 | IRDA_ASSERT(self != NULL, return;); | 452 | IRDA_ASSERT(self != NULL, return;); |
466 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 453 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
467 | 454 | ||
@@ -482,7 +469,7 @@ void irlan_open_data_tsap(struct irlan_cb *self) | |||
482 | 469 | ||
483 | tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, ¬ify); | 470 | tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, ¬ify); |
484 | if (!tsap) { | 471 | if (!tsap) { |
485 | IRDA_DEBUG(2, "%s(), Got no tsap!\n", __func__ ); | 472 | pr_debug("%s(), Got no tsap!\n", __func__); |
486 | return; | 473 | return; |
487 | } | 474 | } |
488 | self->tsap_data = tsap; | 475 | self->tsap_data = tsap; |
@@ -496,8 +483,6 @@ void irlan_open_data_tsap(struct irlan_cb *self) | |||
496 | 483 | ||
497 | void irlan_close_tsaps(struct irlan_cb *self) | 484 | void irlan_close_tsaps(struct irlan_cb *self) |
498 | { | 485 | { |
499 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
500 | |||
501 | IRDA_ASSERT(self != NULL, return;); | 486 | IRDA_ASSERT(self != NULL, return;); |
502 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 487 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
503 | 488 | ||
@@ -586,8 +571,6 @@ int irlan_run_ctrl_tx_queue(struct irlan_cb *self) | |||
586 | { | 571 | { |
587 | struct sk_buff *skb; | 572 | struct sk_buff *skb; |
588 | 573 | ||
589 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
590 | |||
591 | if (irda_lock(&self->client.tx_busy) == FALSE) | 574 | if (irda_lock(&self->client.tx_busy) == FALSE) |
592 | return -EBUSY; | 575 | return -EBUSY; |
593 | 576 | ||
@@ -605,7 +588,7 @@ int irlan_run_ctrl_tx_queue(struct irlan_cb *self) | |||
605 | dev_kfree_skb(skb); | 588 | dev_kfree_skb(skb); |
606 | return -1; | 589 | return -1; |
607 | } | 590 | } |
608 | IRDA_DEBUG(2, "%s(), sending ...\n", __func__ ); | 591 | pr_debug("%s(), sending ...\n", __func__); |
609 | 592 | ||
610 | return irttp_data_request(self->client.tsap_ctrl, skb); | 593 | return irttp_data_request(self->client.tsap_ctrl, skb); |
611 | } | 594 | } |
@@ -618,8 +601,6 @@ int irlan_run_ctrl_tx_queue(struct irlan_cb *self) | |||
618 | */ | 601 | */ |
619 | static void irlan_ctrl_data_request(struct irlan_cb *self, struct sk_buff *skb) | 602 | static void irlan_ctrl_data_request(struct irlan_cb *self, struct sk_buff *skb) |
620 | { | 603 | { |
621 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
622 | |||
623 | /* Queue command */ | 604 | /* Queue command */ |
624 | skb_queue_tail(&self->client.txq, skb); | 605 | skb_queue_tail(&self->client.txq, skb); |
625 | 606 | ||
@@ -638,8 +619,6 @@ void irlan_get_provider_info(struct irlan_cb *self) | |||
638 | struct sk_buff *skb; | 619 | struct sk_buff *skb; |
639 | __u8 *frame; | 620 | __u8 *frame; |
640 | 621 | ||
641 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
642 | |||
643 | IRDA_ASSERT(self != NULL, return;); | 622 | IRDA_ASSERT(self != NULL, return;); |
644 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 623 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
645 | 624 | ||
@@ -671,8 +650,6 @@ void irlan_open_data_channel(struct irlan_cb *self) | |||
671 | struct sk_buff *skb; | 650 | struct sk_buff *skb; |
672 | __u8 *frame; | 651 | __u8 *frame; |
673 | 652 | ||
674 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
675 | |||
676 | IRDA_ASSERT(self != NULL, return;); | 653 | IRDA_ASSERT(self != NULL, return;); |
677 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 654 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
678 | 655 | ||
@@ -706,8 +683,6 @@ void irlan_close_data_channel(struct irlan_cb *self) | |||
706 | struct sk_buff *skb; | 683 | struct sk_buff *skb; |
707 | __u8 *frame; | 684 | __u8 *frame; |
708 | 685 | ||
709 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
710 | |||
711 | IRDA_ASSERT(self != NULL, return;); | 686 | IRDA_ASSERT(self != NULL, return;); |
712 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 687 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
713 | 688 | ||
@@ -747,8 +722,6 @@ static void irlan_open_unicast_addr(struct irlan_cb *self) | |||
747 | struct sk_buff *skb; | 722 | struct sk_buff *skb; |
748 | __u8 *frame; | 723 | __u8 *frame; |
749 | 724 | ||
750 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
751 | |||
752 | IRDA_ASSERT(self != NULL, return;); | 725 | IRDA_ASSERT(self != NULL, return;); |
753 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 726 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
754 | 727 | ||
@@ -789,8 +762,6 @@ void irlan_set_broadcast_filter(struct irlan_cb *self, int status) | |||
789 | struct sk_buff *skb; | 762 | struct sk_buff *skb; |
790 | __u8 *frame; | 763 | __u8 *frame; |
791 | 764 | ||
792 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
793 | |||
794 | IRDA_ASSERT(self != NULL, return;); | 765 | IRDA_ASSERT(self != NULL, return;); |
795 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 766 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
796 | 767 | ||
@@ -833,8 +804,6 @@ void irlan_set_multicast_filter(struct irlan_cb *self, int status) | |||
833 | struct sk_buff *skb; | 804 | struct sk_buff *skb; |
834 | __u8 *frame; | 805 | __u8 *frame; |
835 | 806 | ||
836 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
837 | |||
838 | IRDA_ASSERT(self != NULL, return;); | 807 | IRDA_ASSERT(self != NULL, return;); |
839 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 808 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
840 | 809 | ||
@@ -878,8 +847,6 @@ static void irlan_get_unicast_addr(struct irlan_cb *self) | |||
878 | struct sk_buff *skb; | 847 | struct sk_buff *skb; |
879 | __u8 *frame; | 848 | __u8 *frame; |
880 | 849 | ||
881 | IRDA_DEBUG(2, "%s()\n", __func__ ); | ||
882 | |||
883 | IRDA_ASSERT(self != NULL, return;); | 850 | IRDA_ASSERT(self != NULL, return;); |
884 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 851 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
885 | 852 | ||
@@ -918,8 +885,6 @@ void irlan_get_media_char(struct irlan_cb *self) | |||
918 | struct sk_buff *skb; | 885 | struct sk_buff *skb; |
919 | __u8 *frame; | 886 | __u8 *frame; |
920 | 887 | ||
921 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
922 | |||
923 | IRDA_ASSERT(self != NULL, return;); | 888 | IRDA_ASSERT(self != NULL, return;); |
924 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 889 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
925 | 890 | ||
@@ -1006,7 +971,7 @@ static int __irlan_insert_param(struct sk_buff *skb, char *param, int type, | |||
1006 | int n=0; | 971 | int n=0; |
1007 | 972 | ||
1008 | if (skb == NULL) { | 973 | if (skb == NULL) { |
1009 | IRDA_DEBUG(2, "%s(), Got NULL skb\n", __func__ ); | 974 | pr_debug("%s(), Got NULL skb\n", __func__); |
1010 | return 0; | 975 | return 0; |
1011 | } | 976 | } |
1012 | 977 | ||
@@ -1023,7 +988,7 @@ static int __irlan_insert_param(struct sk_buff *skb, char *param, int type, | |||
1023 | IRDA_ASSERT(value_len > 0, return 0;); | 988 | IRDA_ASSERT(value_len > 0, return 0;); |
1024 | break; | 989 | break; |
1025 | default: | 990 | default: |
1026 | IRDA_DEBUG(2, "%s(), Unknown parameter type!\n", __func__ ); | 991 | pr_debug("%s(), Unknown parameter type!\n", __func__); |
1027 | return 0; | 992 | return 0; |
1028 | } | 993 | } |
1029 | 994 | ||
@@ -1032,7 +997,7 @@ static int __irlan_insert_param(struct sk_buff *skb, char *param, int type, | |||
1032 | 997 | ||
1033 | /* Make space for data */ | 998 | /* Make space for data */ |
1034 | if (skb_tailroom(skb) < (param_len+value_len+3)) { | 999 | if (skb_tailroom(skb) < (param_len+value_len+3)) { |
1035 | IRDA_DEBUG(2, "%s(), No more space at end of skb\n", __func__ ); | 1000 | pr_debug("%s(), No more space at end of skb\n", __func__); |
1036 | return 0; | 1001 | return 0; |
1037 | } | 1002 | } |
1038 | skb_put(skb, param_len+value_len+3); | 1003 | skb_put(skb, param_len+value_len+3); |
@@ -1079,13 +1044,11 @@ int irlan_extract_param(__u8 *buf, char *name, char *value, __u16 *len) | |||
1079 | __u16 val_len; | 1044 | __u16 val_len; |
1080 | int n=0; | 1045 | int n=0; |
1081 | 1046 | ||
1082 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
1083 | |||
1084 | /* get length of parameter name (1 byte) */ | 1047 | /* get length of parameter name (1 byte) */ |
1085 | name_len = buf[n++]; | 1048 | name_len = buf[n++]; |
1086 | 1049 | ||
1087 | if (name_len > 254) { | 1050 | if (name_len > 254) { |
1088 | IRDA_DEBUG(2, "%s(), name_len > 254\n", __func__ ); | 1051 | pr_debug("%s(), name_len > 254\n", __func__); |
1089 | return -RSP_INVALID_COMMAND_FORMAT; | 1052 | return -RSP_INVALID_COMMAND_FORMAT; |
1090 | } | 1053 | } |
1091 | 1054 | ||
@@ -1102,7 +1065,7 @@ int irlan_extract_param(__u8 *buf, char *name, char *value, __u16 *len) | |||
1102 | le16_to_cpus(&val_len); n+=2; | 1065 | le16_to_cpus(&val_len); n+=2; |
1103 | 1066 | ||
1104 | if (val_len >= 1016) { | 1067 | if (val_len >= 1016) { |
1105 | IRDA_DEBUG(2, "%s(), parameter length to long\n", __func__ ); | 1068 | pr_debug("%s(), parameter length to long\n", __func__); |
1106 | return -RSP_INVALID_COMMAND_FORMAT; | 1069 | return -RSP_INVALID_COMMAND_FORMAT; |
1107 | } | 1070 | } |
1108 | *len = val_len; | 1071 | *len = val_len; |
@@ -1112,8 +1075,8 @@ int irlan_extract_param(__u8 *buf, char *name, char *value, __u16 *len) | |||
1112 | value[val_len] = '\0'; | 1075 | value[val_len] = '\0'; |
1113 | n+=val_len; | 1076 | n+=val_len; |
1114 | 1077 | ||
1115 | IRDA_DEBUG(4, "Parameter: %s ", name); | 1078 | pr_debug("Parameter: %s ", name); |
1116 | IRDA_DEBUG(4, "Value: %s\n", value); | 1079 | pr_debug("Value: %s\n", value); |
1117 | 1080 | ||
1118 | return n; | 1081 | return n; |
1119 | } | 1082 | } |
diff --git a/net/irda/irlan/irlan_eth.c b/net/irda/irlan/irlan_eth.c index 94b948ef36f9..fcfbe579434a 100644 --- a/net/irda/irlan/irlan_eth.c +++ b/net/irda/irlan/irlan_eth.c | |||
@@ -110,8 +110,6 @@ static int irlan_eth_open(struct net_device *dev) | |||
110 | { | 110 | { |
111 | struct irlan_cb *self = netdev_priv(dev); | 111 | struct irlan_cb *self = netdev_priv(dev); |
112 | 112 | ||
113 | IRDA_DEBUG(2, "%s()\n", __func__); | ||
114 | |||
115 | /* Ready to play! */ | 113 | /* Ready to play! */ |
116 | netif_stop_queue(dev); /* Wait until data link is ready */ | 114 | netif_stop_queue(dev); /* Wait until data link is ready */ |
117 | 115 | ||
@@ -137,8 +135,6 @@ static int irlan_eth_close(struct net_device *dev) | |||
137 | { | 135 | { |
138 | struct irlan_cb *self = netdev_priv(dev); | 136 | struct irlan_cb *self = netdev_priv(dev); |
139 | 137 | ||
140 | IRDA_DEBUG(2, "%s()\n", __func__); | ||
141 | |||
142 | /* Stop device */ | 138 | /* Stop device */ |
143 | netif_stop_queue(dev); | 139 | netif_stop_queue(dev); |
144 | 140 | ||
@@ -231,8 +227,8 @@ int irlan_eth_receive(void *instance, void *sap, struct sk_buff *skb) | |||
231 | return 0; | 227 | return 0; |
232 | } | 228 | } |
233 | if (skb->len < ETH_HLEN) { | 229 | if (skb->len < ETH_HLEN) { |
234 | IRDA_DEBUG(0, "%s() : IrLAN frame too short (%d)\n", | 230 | pr_debug("%s() : IrLAN frame too short (%d)\n", |
235 | __func__, skb->len); | 231 | __func__, skb->len); |
236 | dev->stats.rx_dropped++; | 232 | dev->stats.rx_dropped++; |
237 | dev_kfree_skb(skb); | 233 | dev_kfree_skb(skb); |
238 | return 0; | 234 | return 0; |
@@ -281,9 +277,9 @@ void irlan_eth_flow_indication(void *instance, void *sap, LOCAL_FLOW flow) | |||
281 | 277 | ||
282 | IRDA_ASSERT(dev != NULL, return;); | 278 | IRDA_ASSERT(dev != NULL, return;); |
283 | 279 | ||
284 | IRDA_DEBUG(0, "%s() : flow %s ; running %d\n", __func__, | 280 | pr_debug("%s() : flow %s ; running %d\n", __func__, |
285 | flow == FLOW_STOP ? "FLOW_STOP" : "FLOW_START", | 281 | flow == FLOW_STOP ? "FLOW_STOP" : "FLOW_START", |
286 | netif_running(dev)); | 282 | netif_running(dev)); |
287 | 283 | ||
288 | switch (flow) { | 284 | switch (flow) { |
289 | case FLOW_STOP: | 285 | case FLOW_STOP: |
@@ -310,11 +306,9 @@ static void irlan_eth_set_multicast_list(struct net_device *dev) | |||
310 | { | 306 | { |
311 | struct irlan_cb *self = netdev_priv(dev); | 307 | struct irlan_cb *self = netdev_priv(dev); |
312 | 308 | ||
313 | IRDA_DEBUG(2, "%s()\n", __func__); | ||
314 | |||
315 | /* Check if data channel has been connected yet */ | 309 | /* Check if data channel has been connected yet */ |
316 | if (self->client.state != IRLAN_DATA) { | 310 | if (self->client.state != IRLAN_DATA) { |
317 | IRDA_DEBUG(1, "%s(), delaying!\n", __func__); | 311 | pr_debug("%s(), delaying!\n", __func__); |
318 | return; | 312 | return; |
319 | } | 313 | } |
320 | 314 | ||
@@ -324,18 +318,18 @@ static void irlan_eth_set_multicast_list(struct net_device *dev) | |||
324 | } else if ((dev->flags & IFF_ALLMULTI) || | 318 | } else if ((dev->flags & IFF_ALLMULTI) || |
325 | netdev_mc_count(dev) > HW_MAX_ADDRS) { | 319 | netdev_mc_count(dev) > HW_MAX_ADDRS) { |
326 | /* Disable promiscuous mode, use normal mode. */ | 320 | /* Disable promiscuous mode, use normal mode. */ |
327 | IRDA_DEBUG(4, "%s(), Setting multicast filter\n", __func__); | 321 | pr_debug("%s(), Setting multicast filter\n", __func__); |
328 | /* hardware_set_filter(NULL); */ | 322 | /* hardware_set_filter(NULL); */ |
329 | 323 | ||
330 | irlan_set_multicast_filter(self, TRUE); | 324 | irlan_set_multicast_filter(self, TRUE); |
331 | } else if (!netdev_mc_empty(dev)) { | 325 | } else if (!netdev_mc_empty(dev)) { |
332 | IRDA_DEBUG(4, "%s(), Setting multicast filter\n", __func__); | 326 | pr_debug("%s(), Setting multicast filter\n", __func__); |
333 | /* Walk the address list, and load the filter */ | 327 | /* Walk the address list, and load the filter */ |
334 | /* hardware_set_filter(dev->mc_list); */ | 328 | /* hardware_set_filter(dev->mc_list); */ |
335 | 329 | ||
336 | irlan_set_multicast_filter(self, TRUE); | 330 | irlan_set_multicast_filter(self, TRUE); |
337 | } else { | 331 | } else { |
338 | IRDA_DEBUG(4, "%s(), Clearing multicast filter\n", __func__); | 332 | pr_debug("%s(), Clearing multicast filter\n", __func__); |
339 | irlan_set_multicast_filter(self, FALSE); | 333 | irlan_set_multicast_filter(self, FALSE); |
340 | } | 334 | } |
341 | 335 | ||
diff --git a/net/irda/irlan/irlan_event.c b/net/irda/irlan/irlan_event.c index 43f16040a6fe..9a1cc11c16f6 100644 --- a/net/irda/irlan/irlan_event.c +++ b/net/irda/irlan/irlan_event.c | |||
@@ -40,7 +40,7 @@ const char * const irlan_state[] = { | |||
40 | 40 | ||
41 | void irlan_next_client_state(struct irlan_cb *self, IRLAN_STATE state) | 41 | void irlan_next_client_state(struct irlan_cb *self, IRLAN_STATE state) |
42 | { | 42 | { |
43 | IRDA_DEBUG(2, "%s(), %s\n", __func__ , irlan_state[state]); | 43 | pr_debug("%s(), %s\n", __func__ , irlan_state[state]); |
44 | 44 | ||
45 | IRDA_ASSERT(self != NULL, return;); | 45 | IRDA_ASSERT(self != NULL, return;); |
46 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 46 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
@@ -50,7 +50,7 @@ void irlan_next_client_state(struct irlan_cb *self, IRLAN_STATE state) | |||
50 | 50 | ||
51 | void irlan_next_provider_state(struct irlan_cb *self, IRLAN_STATE state) | 51 | void irlan_next_provider_state(struct irlan_cb *self, IRLAN_STATE state) |
52 | { | 52 | { |
53 | IRDA_DEBUG(2, "%s(), %s\n", __func__ , irlan_state[state]); | 53 | pr_debug("%s(), %s\n", __func__ , irlan_state[state]); |
54 | 54 | ||
55 | IRDA_ASSERT(self != NULL, return;); | 55 | IRDA_ASSERT(self != NULL, return;); |
56 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 56 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
diff --git a/net/irda/irlan/irlan_filter.c b/net/irda/irlan/irlan_filter.c index 7977be7caf0f..e755e90b2f26 100644 --- a/net/irda/irlan/irlan_filter.c +++ b/net/irda/irlan/irlan_filter.c | |||
@@ -43,7 +43,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
43 | if ((self->provider.filter_type == IRLAN_DIRECTED) && | 43 | if ((self->provider.filter_type == IRLAN_DIRECTED) && |
44 | (self->provider.filter_operation == DYNAMIC)) | 44 | (self->provider.filter_operation == DYNAMIC)) |
45 | { | 45 | { |
46 | IRDA_DEBUG(0, "Giving peer a dynamic Ethernet address\n"); | 46 | pr_debug("Giving peer a dynamic Ethernet address\n"); |
47 | self->provider.mac_address[0] = 0x40; | 47 | self->provider.mac_address[0] = 0x40; |
48 | self->provider.mac_address[1] = 0x00; | 48 | self->provider.mac_address[1] = 0x00; |
49 | self->provider.mac_address[2] = 0x00; | 49 | self->provider.mac_address[2] = 0x00; |
@@ -73,7 +73,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
73 | if ((self->provider.filter_type == IRLAN_DIRECTED) && | 73 | if ((self->provider.filter_type == IRLAN_DIRECTED) && |
74 | (self->provider.filter_mode == FILTER)) | 74 | (self->provider.filter_mode == FILTER)) |
75 | { | 75 | { |
76 | IRDA_DEBUG(0, "Directed filter on\n"); | 76 | pr_debug("Directed filter on\n"); |
77 | skb->data[0] = 0x00; /* Success */ | 77 | skb->data[0] = 0x00; /* Success */ |
78 | skb->data[1] = 0x00; | 78 | skb->data[1] = 0x00; |
79 | return; | 79 | return; |
@@ -81,7 +81,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
81 | if ((self->provider.filter_type == IRLAN_DIRECTED) && | 81 | if ((self->provider.filter_type == IRLAN_DIRECTED) && |
82 | (self->provider.filter_mode == NONE)) | 82 | (self->provider.filter_mode == NONE)) |
83 | { | 83 | { |
84 | IRDA_DEBUG(0, "Directed filter off\n"); | 84 | pr_debug("Directed filter off\n"); |
85 | skb->data[0] = 0x00; /* Success */ | 85 | skb->data[0] = 0x00; /* Success */ |
86 | skb->data[1] = 0x00; | 86 | skb->data[1] = 0x00; |
87 | return; | 87 | return; |
@@ -90,7 +90,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
90 | if ((self->provider.filter_type == IRLAN_BROADCAST) && | 90 | if ((self->provider.filter_type == IRLAN_BROADCAST) && |
91 | (self->provider.filter_mode == FILTER)) | 91 | (self->provider.filter_mode == FILTER)) |
92 | { | 92 | { |
93 | IRDA_DEBUG(0, "Broadcast filter on\n"); | 93 | pr_debug("Broadcast filter on\n"); |
94 | skb->data[0] = 0x00; /* Success */ | 94 | skb->data[0] = 0x00; /* Success */ |
95 | skb->data[1] = 0x00; | 95 | skb->data[1] = 0x00; |
96 | return; | 96 | return; |
@@ -98,7 +98,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
98 | if ((self->provider.filter_type == IRLAN_BROADCAST) && | 98 | if ((self->provider.filter_type == IRLAN_BROADCAST) && |
99 | (self->provider.filter_mode == NONE)) | 99 | (self->provider.filter_mode == NONE)) |
100 | { | 100 | { |
101 | IRDA_DEBUG(0, "Broadcast filter off\n"); | 101 | pr_debug("Broadcast filter off\n"); |
102 | skb->data[0] = 0x00; /* Success */ | 102 | skb->data[0] = 0x00; /* Success */ |
103 | skb->data[1] = 0x00; | 103 | skb->data[1] = 0x00; |
104 | return; | 104 | return; |
@@ -106,7 +106,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
106 | if ((self->provider.filter_type == IRLAN_MULTICAST) && | 106 | if ((self->provider.filter_type == IRLAN_MULTICAST) && |
107 | (self->provider.filter_mode == FILTER)) | 107 | (self->provider.filter_mode == FILTER)) |
108 | { | 108 | { |
109 | IRDA_DEBUG(0, "Multicast filter on\n"); | 109 | pr_debug("Multicast filter on\n"); |
110 | skb->data[0] = 0x00; /* Success */ | 110 | skb->data[0] = 0x00; /* Success */ |
111 | skb->data[1] = 0x00; | 111 | skb->data[1] = 0x00; |
112 | return; | 112 | return; |
@@ -114,7 +114,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
114 | if ((self->provider.filter_type == IRLAN_MULTICAST) && | 114 | if ((self->provider.filter_type == IRLAN_MULTICAST) && |
115 | (self->provider.filter_mode == NONE)) | 115 | (self->provider.filter_mode == NONE)) |
116 | { | 116 | { |
117 | IRDA_DEBUG(0, "Multicast filter off\n"); | 117 | pr_debug("Multicast filter off\n"); |
118 | skb->data[0] = 0x00; /* Success */ | 118 | skb->data[0] = 0x00; /* Success */ |
119 | skb->data[1] = 0x00; | 119 | skb->data[1] = 0x00; |
120 | return; | 120 | return; |
@@ -122,7 +122,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
122 | if ((self->provider.filter_type == IRLAN_MULTICAST) && | 122 | if ((self->provider.filter_type == IRLAN_MULTICAST) && |
123 | (self->provider.filter_operation == GET)) | 123 | (self->provider.filter_operation == GET)) |
124 | { | 124 | { |
125 | IRDA_DEBUG(0, "Multicast filter get\n"); | 125 | pr_debug("Multicast filter get\n"); |
126 | skb->data[0] = 0x00; /* Success? */ | 126 | skb->data[0] = 0x00; /* Success? */ |
127 | skb->data[1] = 0x02; | 127 | skb->data[1] = 0x02; |
128 | irlan_insert_string_param(skb, "FILTER_MODE", "NONE"); | 128 | irlan_insert_string_param(skb, "FILTER_MODE", "NONE"); |
@@ -132,7 +132,7 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
132 | skb->data[0] = 0x00; /* Command not supported */ | 132 | skb->data[0] = 0x00; /* Command not supported */ |
133 | skb->data[1] = 0x00; | 133 | skb->data[1] = 0x00; |
134 | 134 | ||
135 | IRDA_DEBUG(0, "Not implemented!\n"); | 135 | pr_debug("Not implemented!\n"); |
136 | } | 136 | } |
137 | 137 | ||
138 | /* | 138 | /* |
@@ -143,18 +143,15 @@ void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) | |||
143 | */ | 143 | */ |
144 | void irlan_check_command_param(struct irlan_cb *self, char *param, char *value) | 144 | void irlan_check_command_param(struct irlan_cb *self, char *param, char *value) |
145 | { | 145 | { |
146 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
147 | |||
148 | IRDA_ASSERT(self != NULL, return;); | 146 | IRDA_ASSERT(self != NULL, return;); |
149 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 147 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
150 | 148 | ||
151 | IRDA_DEBUG(4, "%s, %s\n", param, value); | 149 | pr_debug("%s, %s\n", param, value); |
152 | 150 | ||
153 | /* | 151 | /* |
154 | * This is experimental!! DB. | 152 | * This is experimental!! DB. |
155 | */ | 153 | */ |
156 | if (strcmp(param, "MODE") == 0) { | 154 | if (strcmp(param, "MODE") == 0) { |
157 | IRDA_DEBUG(0, "%s()\n", __func__ ); | ||
158 | self->use_udata = TRUE; | 155 | self->use_udata = TRUE; |
159 | return; | 156 | return; |
160 | } | 157 | } |
diff --git a/net/irda/irlan/irlan_provider.c b/net/irda/irlan/irlan_provider.c index 4664855222f4..15c292cf2644 100644 --- a/net/irda/irlan/irlan_provider.c +++ b/net/irda/irlan/irlan_provider.c | |||
@@ -70,8 +70,6 @@ static int irlan_provider_data_indication(void *instance, void *sap, | |||
70 | struct irlan_cb *self; | 70 | struct irlan_cb *self; |
71 | __u8 code; | 71 | __u8 code; |
72 | 72 | ||
73 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
74 | |||
75 | self = instance; | 73 | self = instance; |
76 | 74 | ||
77 | IRDA_ASSERT(self != NULL, return -1;); | 75 | IRDA_ASSERT(self != NULL, return -1;); |
@@ -82,32 +80,32 @@ static int irlan_provider_data_indication(void *instance, void *sap, | |||
82 | code = skb->data[0]; | 80 | code = skb->data[0]; |
83 | switch(code) { | 81 | switch(code) { |
84 | case CMD_GET_PROVIDER_INFO: | 82 | case CMD_GET_PROVIDER_INFO: |
85 | IRDA_DEBUG(4, "Got GET_PROVIDER_INFO command!\n"); | 83 | pr_debug("Got GET_PROVIDER_INFO command!\n"); |
86 | irlan_do_provider_event(self, IRLAN_GET_INFO_CMD, skb); | 84 | irlan_do_provider_event(self, IRLAN_GET_INFO_CMD, skb); |
87 | break; | 85 | break; |
88 | 86 | ||
89 | case CMD_GET_MEDIA_CHAR: | 87 | case CMD_GET_MEDIA_CHAR: |
90 | IRDA_DEBUG(4, "Got GET_MEDIA_CHAR command!\n"); | 88 | pr_debug("Got GET_MEDIA_CHAR command!\n"); |
91 | irlan_do_provider_event(self, IRLAN_GET_MEDIA_CMD, skb); | 89 | irlan_do_provider_event(self, IRLAN_GET_MEDIA_CMD, skb); |
92 | break; | 90 | break; |
93 | case CMD_OPEN_DATA_CHANNEL: | 91 | case CMD_OPEN_DATA_CHANNEL: |
94 | IRDA_DEBUG(4, "Got OPEN_DATA_CHANNEL command!\n"); | 92 | pr_debug("Got OPEN_DATA_CHANNEL command!\n"); |
95 | irlan_do_provider_event(self, IRLAN_OPEN_DATA_CMD, skb); | 93 | irlan_do_provider_event(self, IRLAN_OPEN_DATA_CMD, skb); |
96 | break; | 94 | break; |
97 | case CMD_FILTER_OPERATION: | 95 | case CMD_FILTER_OPERATION: |
98 | IRDA_DEBUG(4, "Got FILTER_OPERATION command!\n"); | 96 | pr_debug("Got FILTER_OPERATION command!\n"); |
99 | irlan_do_provider_event(self, IRLAN_FILTER_CONFIG_CMD, skb); | 97 | irlan_do_provider_event(self, IRLAN_FILTER_CONFIG_CMD, skb); |
100 | break; | 98 | break; |
101 | case CMD_RECONNECT_DATA_CHAN: | 99 | case CMD_RECONNECT_DATA_CHAN: |
102 | IRDA_DEBUG(2, "%s(), Got RECONNECT_DATA_CHAN command\n", __func__ ); | 100 | pr_debug("%s(), Got RECONNECT_DATA_CHAN command\n", __func__); |
103 | IRDA_DEBUG(2, "%s(), NOT IMPLEMENTED\n", __func__ ); | 101 | pr_debug("%s(), NOT IMPLEMENTED\n", __func__); |
104 | break; | 102 | break; |
105 | case CMD_CLOSE_DATA_CHAN: | 103 | case CMD_CLOSE_DATA_CHAN: |
106 | IRDA_DEBUG(2, "Got CLOSE_DATA_CHAN command!\n"); | 104 | pr_debug("Got CLOSE_DATA_CHAN command!\n"); |
107 | IRDA_DEBUG(2, "%s(), NOT IMPLEMENTED\n", __func__ ); | 105 | pr_debug("%s(), NOT IMPLEMENTED\n", __func__); |
108 | break; | 106 | break; |
109 | default: | 107 | default: |
110 | IRDA_DEBUG(2, "%s(), Unknown command!\n", __func__ ); | 108 | pr_debug("%s(), Unknown command!\n", __func__); |
111 | break; | 109 | break; |
112 | } | 110 | } |
113 | return 0; | 111 | return 0; |
@@ -128,8 +126,6 @@ static void irlan_provider_connect_indication(void *instance, void *sap, | |||
128 | struct irlan_cb *self; | 126 | struct irlan_cb *self; |
129 | struct tsap_cb *tsap; | 127 | struct tsap_cb *tsap; |
130 | 128 | ||
131 | IRDA_DEBUG(0, "%s()\n", __func__ ); | ||
132 | |||
133 | self = instance; | 129 | self = instance; |
134 | tsap = sap; | 130 | tsap = sap; |
135 | 131 | ||
@@ -179,7 +175,7 @@ static void irlan_provider_disconnect_indication(void *instance, void *sap, | |||
179 | struct irlan_cb *self; | 175 | struct irlan_cb *self; |
180 | struct tsap_cb *tsap; | 176 | struct tsap_cb *tsap; |
181 | 177 | ||
182 | IRDA_DEBUG(4, "%s(), reason=%d\n", __func__ , reason); | 178 | pr_debug("%s(), reason=%d\n", __func__ , reason); |
183 | 179 | ||
184 | self = instance; | 180 | self = instance; |
185 | tsap = sap; | 181 | tsap = sap; |
@@ -233,7 +229,7 @@ int irlan_provider_parse_command(struct irlan_cb *self, int cmd, | |||
233 | 229 | ||
234 | IRDA_ASSERT(skb != NULL, return -RSP_PROTOCOL_ERROR;); | 230 | IRDA_ASSERT(skb != NULL, return -RSP_PROTOCOL_ERROR;); |
235 | 231 | ||
236 | IRDA_DEBUG(4, "%s(), skb->len=%d\n", __func__ , (int)skb->len); | 232 | pr_debug("%s(), skb->len=%d\n", __func__ , (int)skb->len); |
237 | 233 | ||
238 | IRDA_ASSERT(self != NULL, return -RSP_PROTOCOL_ERROR;); | 234 | IRDA_ASSERT(self != NULL, return -RSP_PROTOCOL_ERROR;); |
239 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -RSP_PROTOCOL_ERROR;); | 235 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -RSP_PROTOCOL_ERROR;); |
@@ -255,7 +251,7 @@ int irlan_provider_parse_command(struct irlan_cb *self, int cmd, | |||
255 | /* How many parameters? */ | 251 | /* How many parameters? */ |
256 | count = frame[1]; | 252 | count = frame[1]; |
257 | 253 | ||
258 | IRDA_DEBUG(4, "Got %d parameters\n", count); | 254 | pr_debug("Got %d parameters\n", count); |
259 | 255 | ||
260 | ptr = frame+2; | 256 | ptr = frame+2; |
261 | 257 | ||
@@ -263,7 +259,7 @@ int irlan_provider_parse_command(struct irlan_cb *self, int cmd, | |||
263 | for (i=0; i<count;i++) { | 259 | for (i=0; i<count;i++) { |
264 | ret = irlan_extract_param(ptr, name, value, &val_len); | 260 | ret = irlan_extract_param(ptr, name, value, &val_len); |
265 | if (ret < 0) { | 261 | if (ret < 0) { |
266 | IRDA_DEBUG(2, "%s(), IrLAN, Error!\n", __func__ ); | 262 | pr_debug("%s(), IrLAN, Error!\n", __func__); |
267 | break; | 263 | break; |
268 | } | 264 | } |
269 | ptr+=ret; | 265 | ptr+=ret; |
@@ -288,8 +284,6 @@ void irlan_provider_send_reply(struct irlan_cb *self, int command, | |||
288 | { | 284 | { |
289 | struct sk_buff *skb; | 285 | struct sk_buff *skb; |
290 | 286 | ||
291 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
292 | |||
293 | IRDA_ASSERT(self != NULL, return;); | 287 | IRDA_ASSERT(self != NULL, return;); |
294 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); | 288 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); |
295 | 289 | ||
@@ -320,7 +314,7 @@ void irlan_provider_send_reply(struct irlan_cb *self, int command, | |||
320 | irlan_insert_string_param(skb, "MEDIA", "802.5"); | 314 | irlan_insert_string_param(skb, "MEDIA", "802.5"); |
321 | break; | 315 | break; |
322 | default: | 316 | default: |
323 | IRDA_DEBUG(2, "%s(), unknown media type!\n", __func__ ); | 317 | pr_debug("%s(), unknown media type!\n", __func__); |
324 | break; | 318 | break; |
325 | } | 319 | } |
326 | irlan_insert_short_param(skb, "IRLAN_VER", 0x0101); | 320 | irlan_insert_short_param(skb, "IRLAN_VER", 0x0101); |
@@ -344,7 +338,7 @@ void irlan_provider_send_reply(struct irlan_cb *self, int command, | |||
344 | irlan_insert_string_param(skb, "ACCESS_TYPE", "HOSTED"); | 338 | irlan_insert_string_param(skb, "ACCESS_TYPE", "HOSTED"); |
345 | break; | 339 | break; |
346 | default: | 340 | default: |
347 | IRDA_DEBUG(2, "%s(), Unknown access type\n", __func__ ); | 341 | pr_debug("%s(), Unknown access type\n", __func__); |
348 | break; | 342 | break; |
349 | } | 343 | } |
350 | irlan_insert_short_param(skb, "MAX_FRAME", 0x05ee); | 344 | irlan_insert_short_param(skb, "MAX_FRAME", 0x05ee); |
@@ -364,7 +358,7 @@ void irlan_provider_send_reply(struct irlan_cb *self, int command, | |||
364 | irlan_filter_request(self, skb); | 358 | irlan_filter_request(self, skb); |
365 | break; | 359 | break; |
366 | default: | 360 | default: |
367 | IRDA_DEBUG(2, "%s(), Unknown command!\n", __func__ ); | 361 | pr_debug("%s(), Unknown command!\n", __func__); |
368 | break; | 362 | break; |
369 | } | 363 | } |
370 | 364 | ||
@@ -382,8 +376,6 @@ int irlan_provider_open_ctrl_tsap(struct irlan_cb *self) | |||
382 | struct tsap_cb *tsap; | 376 | struct tsap_cb *tsap; |
383 | notify_t notify; | 377 | notify_t notify; |
384 | 378 | ||
385 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
386 | |||
387 | IRDA_ASSERT(self != NULL, return -1;); | 379 | IRDA_ASSERT(self != NULL, return -1;); |
388 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); | 380 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); |
389 | 381 | ||
@@ -403,7 +395,7 @@ int irlan_provider_open_ctrl_tsap(struct irlan_cb *self) | |||
403 | 395 | ||
404 | tsap = irttp_open_tsap(LSAP_ANY, 1, ¬ify); | 396 | tsap = irttp_open_tsap(LSAP_ANY, 1, ¬ify); |
405 | if (!tsap) { | 397 | if (!tsap) { |
406 | IRDA_DEBUG(2, "%s(), Got no tsap!\n", __func__ ); | 398 | pr_debug("%s(), Got no tsap!\n", __func__); |
407 | return -1; | 399 | return -1; |
408 | } | 400 | } |
409 | self->provider.tsap_ctrl = tsap; | 401 | self->provider.tsap_ctrl = tsap; |
diff --git a/net/irda/irlan/irlan_provider_event.c b/net/irda/irlan/irlan_provider_event.c index 01a9d7c993ee..9c4f7f51d6b5 100644 --- a/net/irda/irlan/irlan_provider_event.c +++ b/net/irda/irlan/irlan_provider_event.c | |||
@@ -72,8 +72,6 @@ void irlan_do_provider_event(struct irlan_cb *self, IRLAN_EVENT event, | |||
72 | static int irlan_provider_state_idle(struct irlan_cb *self, IRLAN_EVENT event, | 72 | static int irlan_provider_state_idle(struct irlan_cb *self, IRLAN_EVENT event, |
73 | struct sk_buff *skb) | 73 | struct sk_buff *skb) |
74 | { | 74 | { |
75 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
76 | |||
77 | IRDA_ASSERT(self != NULL, return -1;); | 75 | IRDA_ASSERT(self != NULL, return -1;); |
78 | 76 | ||
79 | switch(event) { | 77 | switch(event) { |
@@ -82,7 +80,7 @@ static int irlan_provider_state_idle(struct irlan_cb *self, IRLAN_EVENT event, | |||
82 | irlan_next_provider_state( self, IRLAN_INFO); | 80 | irlan_next_provider_state( self, IRLAN_INFO); |
83 | break; | 81 | break; |
84 | default: | 82 | default: |
85 | IRDA_DEBUG(4, "%s(), Unknown event %d\n", __func__ , event); | 83 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
86 | break; | 84 | break; |
87 | } | 85 | } |
88 | if (skb) | 86 | if (skb) |
@@ -101,8 +99,6 @@ static int irlan_provider_state_info(struct irlan_cb *self, IRLAN_EVENT event, | |||
101 | { | 99 | { |
102 | int ret; | 100 | int ret; |
103 | 101 | ||
104 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
105 | |||
106 | IRDA_ASSERT(self != NULL, return -1;); | 102 | IRDA_ASSERT(self != NULL, return -1;); |
107 | 103 | ||
108 | switch(event) { | 104 | switch(event) { |
@@ -147,7 +143,7 @@ static int irlan_provider_state_info(struct irlan_cb *self, IRLAN_EVENT event, | |||
147 | irlan_next_provider_state(self, IRLAN_IDLE); | 143 | irlan_next_provider_state(self, IRLAN_IDLE); |
148 | break; | 144 | break; |
149 | default: | 145 | default: |
150 | IRDA_DEBUG( 0, "%s(), Unknown event %d\n", __func__ , event); | 146 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
151 | break; | 147 | break; |
152 | } | 148 | } |
153 | if (skb) | 149 | if (skb) |
@@ -166,8 +162,6 @@ static int irlan_provider_state_info(struct irlan_cb *self, IRLAN_EVENT event, | |||
166 | static int irlan_provider_state_open(struct irlan_cb *self, IRLAN_EVENT event, | 162 | static int irlan_provider_state_open(struct irlan_cb *self, IRLAN_EVENT event, |
167 | struct sk_buff *skb) | 163 | struct sk_buff *skb) |
168 | { | 164 | { |
169 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
170 | |||
171 | IRDA_ASSERT(self != NULL, return -1;); | 165 | IRDA_ASSERT(self != NULL, return -1;); |
172 | 166 | ||
173 | switch(event) { | 167 | switch(event) { |
@@ -186,7 +180,7 @@ static int irlan_provider_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
186 | irlan_next_provider_state(self, IRLAN_IDLE); | 180 | irlan_next_provider_state(self, IRLAN_IDLE); |
187 | break; | 181 | break; |
188 | default: | 182 | default: |
189 | IRDA_DEBUG(2, "%s(), Unknown event %d\n", __func__ , event); | 183 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
190 | break; | 184 | break; |
191 | } | 185 | } |
192 | if (skb) | 186 | if (skb) |
@@ -205,8 +199,6 @@ static int irlan_provider_state_open(struct irlan_cb *self, IRLAN_EVENT event, | |||
205 | static int irlan_provider_state_data(struct irlan_cb *self, IRLAN_EVENT event, | 199 | static int irlan_provider_state_data(struct irlan_cb *self, IRLAN_EVENT event, |
206 | struct sk_buff *skb) | 200 | struct sk_buff *skb) |
207 | { | 201 | { |
208 | IRDA_DEBUG(4, "%s()\n", __func__ ); | ||
209 | |||
210 | IRDA_ASSERT(self != NULL, return -1;); | 202 | IRDA_ASSERT(self != NULL, return -1;); |
211 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); | 203 | IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); |
212 | 204 | ||
@@ -221,7 +213,7 @@ static int irlan_provider_state_data(struct irlan_cb *self, IRLAN_EVENT event, | |||
221 | irlan_next_provider_state(self, IRLAN_IDLE); | 213 | irlan_next_provider_state(self, IRLAN_IDLE); |
222 | break; | 214 | break; |
223 | default: | 215 | default: |
224 | IRDA_DEBUG( 0, "%s(), Unknown event %d\n", __func__ , event); | 216 | pr_debug("%s(), Unknown event %d\n", __func__ , event); |
225 | break; | 217 | break; |
226 | } | 218 | } |
227 | if (skb) | 219 | if (skb) |