aboutsummaryrefslogtreecommitdiffstats
path: root/net/irda/ircomm/ircomm_lmp.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/irda/ircomm/ircomm_lmp.c')
-rw-r--r--net/irda/ircomm/ircomm_lmp.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/net/irda/ircomm/ircomm_lmp.c b/net/irda/ircomm/ircomm_lmp.c
index 55860ee4e39e..67c99d20857f 100644
--- a/net/irda/ircomm/ircomm_lmp.c
+++ b/net/irda/ircomm/ircomm_lmp.c
@@ -53,7 +53,7 @@ static int ircomm_lmp_connect_request(struct ircomm_cb *self,
53{ 53{
54 int ret = 0; 54 int ret = 0;
55 55
56 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 56 IRDA_DEBUG(0, "%s()\n", __func__ );
57 57
58 /* Don't forget to refcount it - should be NULL anyway */ 58 /* Don't forget to refcount it - should be NULL anyway */
59 if(userdata) 59 if(userdata)
@@ -76,7 +76,7 @@ static int ircomm_lmp_connect_response(struct ircomm_cb *self,
76 struct sk_buff *tx_skb; 76 struct sk_buff *tx_skb;
77 int ret; 77 int ret;
78 78
79 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 79 IRDA_DEBUG(0, "%s()\n", __func__ );
80 80
81 /* Any userdata supplied? */ 81 /* Any userdata supplied? */
82 if (userdata == NULL) { 82 if (userdata == NULL) {
@@ -111,7 +111,7 @@ static int ircomm_lmp_disconnect_request(struct ircomm_cb *self,
111 struct sk_buff *tx_skb; 111 struct sk_buff *tx_skb;
112 int ret; 112 int ret;
113 113
114 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 114 IRDA_DEBUG(0, "%s()\n", __func__ );
115 115
116 if (!userdata) { 116 if (!userdata) {
117 tx_skb = alloc_skb(LMP_MAX_HEADER, GFP_ATOMIC); 117 tx_skb = alloc_skb(LMP_MAX_HEADER, GFP_ATOMIC);
@@ -148,13 +148,13 @@ static void ircomm_lmp_flow_control(struct sk_buff *skb)
148 148
149 cb = (struct irda_skb_cb *) skb->cb; 149 cb = (struct irda_skb_cb *) skb->cb;
150 150
151 IRDA_DEBUG(2, "%s()\n", __FUNCTION__ ); 151 IRDA_DEBUG(2, "%s()\n", __func__ );
152 152
153 line = cb->line; 153 line = cb->line;
154 154
155 self = (struct ircomm_cb *) hashbin_lock_find(ircomm, line, NULL); 155 self = (struct ircomm_cb *) hashbin_lock_find(ircomm, line, NULL);
156 if (!self) { 156 if (!self) {
157 IRDA_DEBUG(2, "%s(), didn't find myself\n", __FUNCTION__ ); 157 IRDA_DEBUG(2, "%s(), didn't find myself\n", __func__ );
158 return; 158 return;
159 } 159 }
160 160
@@ -164,7 +164,7 @@ static void ircomm_lmp_flow_control(struct sk_buff *skb)
164 self->pkt_count--; 164 self->pkt_count--;
165 165
166 if ((self->pkt_count < 2) && (self->flow_status == FLOW_STOP)) { 166 if ((self->pkt_count < 2) && (self->flow_status == FLOW_STOP)) {
167 IRDA_DEBUG(2, "%s(), asking TTY to start again!\n", __FUNCTION__ ); 167 IRDA_DEBUG(2, "%s(), asking TTY to start again!\n", __func__ );
168 self->flow_status = FLOW_START; 168 self->flow_status = FLOW_START;
169 if (self->notify.flow_indication) 169 if (self->notify.flow_indication)
170 self->notify.flow_indication(self->notify.instance, 170 self->notify.flow_indication(self->notify.instance,
@@ -191,7 +191,7 @@ static int ircomm_lmp_data_request(struct ircomm_cb *self,
191 191
192 cb->line = self->line; 192 cb->line = self->line;
193 193
194 IRDA_DEBUG(4, "%s(), sending frame\n", __FUNCTION__ ); 194 IRDA_DEBUG(4, "%s(), sending frame\n", __func__ );
195 195
196 /* Don't forget to refcount it - see ircomm_tty_do_softint() */ 196 /* Don't forget to refcount it - see ircomm_tty_do_softint() */
197 skb_get(skb); 197 skb_get(skb);
@@ -199,7 +199,7 @@ static int ircomm_lmp_data_request(struct ircomm_cb *self,
199 skb->destructor = ircomm_lmp_flow_control; 199 skb->destructor = ircomm_lmp_flow_control;
200 200
201 if ((self->pkt_count++ > 7) && (self->flow_status == FLOW_START)) { 201 if ((self->pkt_count++ > 7) && (self->flow_status == FLOW_START)) {
202 IRDA_DEBUG(2, "%s(), asking TTY to slow down!\n", __FUNCTION__ ); 202 IRDA_DEBUG(2, "%s(), asking TTY to slow down!\n", __func__ );
203 self->flow_status = FLOW_STOP; 203 self->flow_status = FLOW_STOP;
204 if (self->notify.flow_indication) 204 if (self->notify.flow_indication)
205 self->notify.flow_indication(self->notify.instance, 205 self->notify.flow_indication(self->notify.instance,
@@ -207,7 +207,7 @@ static int ircomm_lmp_data_request(struct ircomm_cb *self,
207 } 207 }
208 ret = irlmp_data_request(self->lsap, skb); 208 ret = irlmp_data_request(self->lsap, skb);
209 if (ret) { 209 if (ret) {
210 IRDA_ERROR("%s(), failed\n", __FUNCTION__); 210 IRDA_ERROR("%s(), failed\n", __func__);
211 /* irlmp_data_request already free the packet */ 211 /* irlmp_data_request already free the packet */
212 } 212 }
213 213
@@ -225,7 +225,7 @@ static int ircomm_lmp_data_indication(void *instance, void *sap,
225{ 225{
226 struct ircomm_cb *self = (struct ircomm_cb *) instance; 226 struct ircomm_cb *self = (struct ircomm_cb *) instance;
227 227
228 IRDA_DEBUG(4, "%s()\n", __FUNCTION__ ); 228 IRDA_DEBUG(4, "%s()\n", __func__ );
229 229
230 IRDA_ASSERT(self != NULL, return -1;); 230 IRDA_ASSERT(self != NULL, return -1;);
231 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return -1;); 231 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return -1;);
@@ -255,7 +255,7 @@ static void ircomm_lmp_connect_confirm(void *instance, void *sap,
255 struct ircomm_cb *self = (struct ircomm_cb *) instance; 255 struct ircomm_cb *self = (struct ircomm_cb *) instance;
256 struct ircomm_info info; 256 struct ircomm_info info;
257 257
258 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 258 IRDA_DEBUG(0, "%s()\n", __func__ );
259 259
260 IRDA_ASSERT(self != NULL, return;); 260 IRDA_ASSERT(self != NULL, return;);
261 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;); 261 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;);
@@ -288,7 +288,7 @@ static void ircomm_lmp_connect_indication(void *instance, void *sap,
288 struct ircomm_cb *self = (struct ircomm_cb *)instance; 288 struct ircomm_cb *self = (struct ircomm_cb *)instance;
289 struct ircomm_info info; 289 struct ircomm_info info;
290 290
291 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 291 IRDA_DEBUG(0, "%s()\n", __func__ );
292 292
293 IRDA_ASSERT(self != NULL, return;); 293 IRDA_ASSERT(self != NULL, return;);
294 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;); 294 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;);
@@ -318,7 +318,7 @@ static void ircomm_lmp_disconnect_indication(void *instance, void *sap,
318 struct ircomm_cb *self = (struct ircomm_cb *) instance; 318 struct ircomm_cb *self = (struct ircomm_cb *) instance;
319 struct ircomm_info info; 319 struct ircomm_info info;
320 320
321 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 321 IRDA_DEBUG(0, "%s()\n", __func__ );
322 322
323 IRDA_ASSERT(self != NULL, return;); 323 IRDA_ASSERT(self != NULL, return;);
324 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;); 324 IRDA_ASSERT(self->magic == IRCOMM_MAGIC, return;);
@@ -341,7 +341,7 @@ int ircomm_open_lsap(struct ircomm_cb *self)
341{ 341{
342 notify_t notify; 342 notify_t notify;
343 343
344 IRDA_DEBUG(0, "%s()\n", __FUNCTION__ ); 344 IRDA_DEBUG(0, "%s()\n", __func__ );
345 345
346 /* Register callbacks */ 346 /* Register callbacks */
347 irda_notify_init(&notify); 347 irda_notify_init(&notify);
@@ -354,7 +354,7 @@ int ircomm_open_lsap(struct ircomm_cb *self)
354 354
355 self->lsap = irlmp_open_lsap(LSAP_ANY, &notify, 0); 355 self->lsap = irlmp_open_lsap(LSAP_ANY, &notify, 0);
356 if (!self->lsap) { 356 if (!self->lsap) {
357 IRDA_DEBUG(0,"%sfailed to allocate tsap\n", __FUNCTION__ ); 357 IRDA_DEBUG(0,"%sfailed to allocate tsap\n", __func__ );
358 return -1; 358 return -1;
359 } 359 }
360 self->slsap_sel = self->lsap->slsap_sel; 360 self->slsap_sel = self->lsap->slsap_sel;