aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn
diff options
context:
space:
mode:
authorTodd Poynor <tpoynor@mvista.com>2005-07-11 22:34:39 -0400
committerThomas Gleixner <tglx@mtd.linutronix.de>2005-07-12 18:58:44 -0400
commita98a5d04f400ad112e59cadd739dbabf89417e60 (patch)
tree5eeb7f45c0090de40c7523e2b9dfd5e86b22169e /drivers/isdn
parent751382dd5cb2702368d281a50b55c2d6c4e8fbfc (diff)
parent7ac3db59fd4410405ce55e2a25c397aec440d8da (diff)
Merge with rsync://fileserver/linux
Diffstat (limited to 'drivers/isdn')
-rw-r--r--drivers/isdn/hardware/avm/avm_cs.c7
-rw-r--r--drivers/isdn/hisax/avma1_cs.c7
-rw-r--r--drivers/isdn/hisax/elsa_cs.c7
-rw-r--r--drivers/isdn/hisax/isdnl1.c3
-rw-r--r--drivers/isdn/hisax/isdnl2.c17
-rw-r--r--drivers/isdn/hisax/isdnl3.c2
-rw-r--r--drivers/isdn/hisax/sedlbauer_cs.c7
-rw-r--r--drivers/isdn/hisax/teles_cs.c7
-rw-r--r--drivers/isdn/i4l/isdn_tty.c4
-rw-r--r--drivers/isdn/icn/icn.c4
10 files changed, 21 insertions, 44 deletions
diff --git a/drivers/isdn/hardware/avm/avm_cs.c b/drivers/isdn/hardware/avm/avm_cs.c
index ee750e9456dd..db9bad2b3d16 100644
--- a/drivers/isdn/hardware/avm/avm_cs.c
+++ b/drivers/isdn/hardware/avm/avm_cs.c
@@ -22,7 +22,6 @@
22#include <asm/io.h> 22#include <asm/io.h>
23#include <asm/system.h> 23#include <asm/system.h>
24 24
25#include <pcmcia/version.h>
26#include <pcmcia/cs_types.h> 25#include <pcmcia/cs_types.h>
27#include <pcmcia/cs.h> 26#include <pcmcia/cs.h>
28#include <pcmcia/cistpl.h> 27#include <pcmcia/cistpl.h>
@@ -161,11 +160,6 @@ static dev_link_t *avmcs_attach(void)
161 link->next = dev_list; 160 link->next = dev_list;
162 dev_list = link; 161 dev_list = link;
163 client_reg.dev_info = &dev_info; 162 client_reg.dev_info = &dev_info;
164 client_reg.EventMask =
165 CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
166 CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
167 CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
168 client_reg.event_handler = &avmcs_event;
169 client_reg.Version = 0x0210; 163 client_reg.Version = 0x0210;
170 client_reg.event_callback_args.client_data = link; 164 client_reg.event_callback_args.client_data = link;
171 ret = pcmcia_register_client(&link->handle, &client_reg); 165 ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -500,6 +494,7 @@ static struct pcmcia_driver avmcs_driver = {
500 .name = "avm_cs", 494 .name = "avm_cs",
501 }, 495 },
502 .attach = avmcs_attach, 496 .attach = avmcs_attach,
497 .event = avmcs_event,
503 .detach = avmcs_detach, 498 .detach = avmcs_detach,
504 .id_table = avmcs_ids, 499 .id_table = avmcs_ids,
505}; 500};
diff --git a/drivers/isdn/hisax/avma1_cs.c b/drivers/isdn/hisax/avma1_cs.c
index 67c60e04a37b..0e22991635e7 100644
--- a/drivers/isdn/hisax/avma1_cs.c
+++ b/drivers/isdn/hisax/avma1_cs.c
@@ -21,7 +21,6 @@
21#include <asm/io.h> 21#include <asm/io.h>
22#include <asm/system.h> 22#include <asm/system.h>
23 23
24#include <pcmcia/version.h>
25#include <pcmcia/cs_types.h> 24#include <pcmcia/cs_types.h>
26#include <pcmcia/cs.h> 25#include <pcmcia/cs.h>
27#include <pcmcia/cistpl.h> 26#include <pcmcia/cistpl.h>
@@ -183,11 +182,6 @@ static dev_link_t *avma1cs_attach(void)
183 link->next = dev_list; 182 link->next = dev_list;
184 dev_list = link; 183 dev_list = link;
185 client_reg.dev_info = &dev_info; 184 client_reg.dev_info = &dev_info;
186 client_reg.EventMask =
187 CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
188 CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
189 CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
190 client_reg.event_handler = &avma1cs_event;
191 client_reg.Version = 0x0210; 185 client_reg.Version = 0x0210;
192 client_reg.event_callback_args.client_data = link; 186 client_reg.event_callback_args.client_data = link;
193 ret = pcmcia_register_client(&link->handle, &client_reg); 187 ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -514,6 +508,7 @@ static struct pcmcia_driver avma1cs_driver = {
514 .name = "avma1_cs", 508 .name = "avma1_cs",
515 }, 509 },
516 .attach = avma1cs_attach, 510 .attach = avma1cs_attach,
511 .event = avma1cs_event,
517 .detach = avma1cs_detach, 512 .detach = avma1cs_detach,
518 .id_table = avma1cs_ids, 513 .id_table = avma1cs_ids,
519}; 514};
diff --git a/drivers/isdn/hisax/elsa_cs.c b/drivers/isdn/hisax/elsa_cs.c
index 9146be547044..6fc6868de0b0 100644
--- a/drivers/isdn/hisax/elsa_cs.c
+++ b/drivers/isdn/hisax/elsa_cs.c
@@ -47,7 +47,6 @@
47#include <asm/io.h> 47#include <asm/io.h>
48#include <asm/system.h> 48#include <asm/system.h>
49 49
50#include <pcmcia/version.h>
51#include <pcmcia/cs_types.h> 50#include <pcmcia/cs_types.h>
52#include <pcmcia/cs.h> 51#include <pcmcia/cs.h>
53#include <pcmcia/cistpl.h> 52#include <pcmcia/cistpl.h>
@@ -212,11 +211,6 @@ static dev_link_t *elsa_cs_attach(void)
212 link->next = dev_list; 211 link->next = dev_list;
213 dev_list = link; 212 dev_list = link;
214 client_reg.dev_info = &dev_info; 213 client_reg.dev_info = &dev_info;
215 client_reg.EventMask =
216 CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
217 CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
218 CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
219 client_reg.event_handler = &elsa_cs_event;
220 client_reg.Version = 0x0210; 214 client_reg.Version = 0x0210;
221 client_reg.event_callback_args.client_data = link; 215 client_reg.event_callback_args.client_data = link;
222 ret = pcmcia_register_client(&link->handle, &client_reg); 216 ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -521,6 +515,7 @@ static struct pcmcia_driver elsa_cs_driver = {
521 .name = "elsa_cs", 515 .name = "elsa_cs",
522 }, 516 },
523 .attach = elsa_cs_attach, 517 .attach = elsa_cs_attach,
518 .event = elsa_cs_event,
524 .detach = elsa_cs_detach, 519 .detach = elsa_cs_detach,
525 .id_table = elsa_ids, 520 .id_table = elsa_ids,
526}; 521};
diff --git a/drivers/isdn/hisax/isdnl1.c b/drivers/isdn/hisax/isdnl1.c
index ac899503a74f..bab356886483 100644
--- a/drivers/isdn/hisax/isdnl1.c
+++ b/drivers/isdn/hisax/isdnl1.c
@@ -279,7 +279,8 @@ BChannel_proc_xmt(struct BCState *bcs)
279 if (test_and_clear_bit(FLG_L1_PULL_REQ, &st->l1.Flags)) 279 if (test_and_clear_bit(FLG_L1_PULL_REQ, &st->l1.Flags))
280 st->l1.l1l2(st, PH_PULL | CONFIRM, NULL); 280 st->l1.l1l2(st, PH_PULL | CONFIRM, NULL);
281 if (!test_bit(BC_FLG_ACTIV, &bcs->Flag)) { 281 if (!test_bit(BC_FLG_ACTIV, &bcs->Flag)) {
282 if (!test_bit(BC_FLG_BUSY, &bcs->Flag) && (!skb_queue_len(&bcs->squeue))) { 282 if (!test_bit(BC_FLG_BUSY, &bcs->Flag) &&
283 skb_queue_empty(&bcs->squeue)) {
283 st->l2.l2l1(st, PH_DEACTIVATE | CONFIRM, NULL); 284 st->l2.l2l1(st, PH_DEACTIVATE | CONFIRM, NULL);
284 } 285 }
285 } 286 }
diff --git a/drivers/isdn/hisax/isdnl2.c b/drivers/isdn/hisax/isdnl2.c
index 9022583fd6a0..1615c1a76ab8 100644
--- a/drivers/isdn/hisax/isdnl2.c
+++ b/drivers/isdn/hisax/isdnl2.c
@@ -108,7 +108,8 @@ static int l2addrsize(struct Layer2 *l2);
108static void 108static void
109set_peer_busy(struct Layer2 *l2) { 109set_peer_busy(struct Layer2 *l2) {
110 test_and_set_bit(FLG_PEER_BUSY, &l2->flag); 110 test_and_set_bit(FLG_PEER_BUSY, &l2->flag);
111 if (skb_queue_len(&l2->i_queue) || skb_queue_len(&l2->ui_queue)) 111 if (!skb_queue_empty(&l2->i_queue) ||
112 !skb_queue_empty(&l2->ui_queue))
112 test_and_set_bit(FLG_L2BLOCK, &l2->flag); 113 test_and_set_bit(FLG_L2BLOCK, &l2->flag);
113} 114}
114 115
@@ -754,7 +755,7 @@ l2_restart_multi(struct FsmInst *fi, int event, void *arg)
754 st->l2.l2l3(st, DL_ESTABLISH | INDICATION, NULL); 755 st->l2.l2l3(st, DL_ESTABLISH | INDICATION, NULL);
755 756
756 if ((ST_L2_7==state) || (ST_L2_8 == state)) 757 if ((ST_L2_7==state) || (ST_L2_8 == state))
757 if (skb_queue_len(&st->l2.i_queue) && cansend(st)) 758 if (!skb_queue_empty(&st->l2.i_queue) && cansend(st))
758 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 759 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
759} 760}
760 761
@@ -810,7 +811,7 @@ l2_connected(struct FsmInst *fi, int event, void *arg)
810 if (pr != -1) 811 if (pr != -1)
811 st->l2.l2l3(st, pr, NULL); 812 st->l2.l2l3(st, pr, NULL);
812 813
813 if (skb_queue_len(&st->l2.i_queue) && cansend(st)) 814 if (!skb_queue_empty(&st->l2.i_queue) && cansend(st))
814 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 815 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
815} 816}
816 817
@@ -1014,7 +1015,7 @@ l2_st7_got_super(struct FsmInst *fi, int event, void *arg)
1014 if(typ != RR) FsmDelTimer(&st->l2.t203, 9); 1015 if(typ != RR) FsmDelTimer(&st->l2.t203, 9);
1015 restart_t200(st, 12); 1016 restart_t200(st, 12);
1016 } 1017 }
1017 if (skb_queue_len(&st->l2.i_queue) && (typ == RR)) 1018 if (!skb_queue_empty(&st->l2.i_queue) && (typ == RR))
1018 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 1019 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
1019 } else 1020 } else
1020 nrerrorrecovery(fi); 1021 nrerrorrecovery(fi);
@@ -1120,7 +1121,7 @@ l2_got_iframe(struct FsmInst *fi, int event, void *arg)
1120 return; 1121 return;
1121 } 1122 }
1122 1123
1123 if (skb_queue_len(&st->l2.i_queue) && (fi->state == ST_L2_7)) 1124 if (!skb_queue_empty(&st->l2.i_queue) && (fi->state == ST_L2_7))
1124 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 1125 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
1125 if (test_and_clear_bit(FLG_ACK_PEND, &st->l2.flag)) 1126 if (test_and_clear_bit(FLG_ACK_PEND, &st->l2.flag))
1126 enquiry_cr(st, RR, RSP, 0); 1127 enquiry_cr(st, RR, RSP, 0);
@@ -1138,7 +1139,7 @@ l2_got_tei(struct FsmInst *fi, int event, void *arg)
1138 test_and_set_bit(FLG_L3_INIT, &st->l2.flag); 1139 test_and_set_bit(FLG_L3_INIT, &st->l2.flag);
1139 } else 1140 } else
1140 FsmChangeState(fi, ST_L2_4); 1141 FsmChangeState(fi, ST_L2_4);
1141 if (skb_queue_len(&st->l2.ui_queue)) 1142 if (!skb_queue_empty(&st->l2.ui_queue))
1142 tx_ui(st); 1143 tx_ui(st);
1143} 1144}
1144 1145
@@ -1301,7 +1302,7 @@ l2_pull_iqueue(struct FsmInst *fi, int event, void *arg)
1301 FsmDelTimer(&st->l2.t203, 13); 1302 FsmDelTimer(&st->l2.t203, 13);
1302 FsmAddTimer(&st->l2.t200, st->l2.T200, EV_L2_T200, NULL, 11); 1303 FsmAddTimer(&st->l2.t200, st->l2.T200, EV_L2_T200, NULL, 11);
1303 } 1304 }
1304 if (skb_queue_len(&l2->i_queue) && cansend(st)) 1305 if (!skb_queue_empty(&l2->i_queue) && cansend(st))
1305 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 1306 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
1306} 1307}
1307 1308
@@ -1347,7 +1348,7 @@ l2_st8_got_super(struct FsmInst *fi, int event, void *arg)
1347 } 1348 }
1348 invoke_retransmission(st, nr); 1349 invoke_retransmission(st, nr);
1349 FsmChangeState(fi, ST_L2_7); 1350 FsmChangeState(fi, ST_L2_7);
1350 if (skb_queue_len(&l2->i_queue) && cansend(st)) 1351 if (!skb_queue_empty(&l2->i_queue) && cansend(st))
1351 st->l2.l2l1(st, PH_PULL | REQUEST, NULL); 1352 st->l2.l2l1(st, PH_PULL | REQUEST, NULL);
1352 } else 1353 } else
1353 nrerrorrecovery(fi); 1354 nrerrorrecovery(fi);
diff --git a/drivers/isdn/hisax/isdnl3.c b/drivers/isdn/hisax/isdnl3.c
index abcc9530eb34..c9917cd2132b 100644
--- a/drivers/isdn/hisax/isdnl3.c
+++ b/drivers/isdn/hisax/isdnl3.c
@@ -302,7 +302,7 @@ release_l3_process(struct l3_process *p)
302 !test_bit(FLG_PTP, &p->st->l2.flag)) { 302 !test_bit(FLG_PTP, &p->st->l2.flag)) {
303 if (p->debug) 303 if (p->debug)
304 l3_debug(p->st, "release_l3_process: last process"); 304 l3_debug(p->st, "release_l3_process: last process");
305 if (!skb_queue_len(&p->st->l3.squeue)) { 305 if (skb_queue_empty(&p->st->l3.squeue)) {
306 if (p->debug) 306 if (p->debug)
307 l3_debug(p->st, "release_l3_process: release link"); 307 l3_debug(p->st, "release_l3_process: release link");
308 if (p->st->protocol != ISDN_PTYPE_NI1) 308 if (p->st->protocol != ISDN_PTYPE_NI1)
diff --git a/drivers/isdn/hisax/sedlbauer_cs.c b/drivers/isdn/hisax/sedlbauer_cs.c
index 058147a69576..c6b5bf7d2aca 100644
--- a/drivers/isdn/hisax/sedlbauer_cs.c
+++ b/drivers/isdn/hisax/sedlbauer_cs.c
@@ -47,7 +47,6 @@
47#include <asm/io.h> 47#include <asm/io.h>
48#include <asm/system.h> 48#include <asm/system.h>
49 49
50#include <pcmcia/version.h>
51#include <pcmcia/cs_types.h> 50#include <pcmcia/cs_types.h>
52#include <pcmcia/cs.h> 51#include <pcmcia/cs.h>
53#include <pcmcia/cistpl.h> 52#include <pcmcia/cistpl.h>
@@ -226,11 +225,6 @@ static dev_link_t *sedlbauer_attach(void)
226 link->next = dev_list; 225 link->next = dev_list;
227 dev_list = link; 226 dev_list = link;
228 client_reg.dev_info = &dev_info; 227 client_reg.dev_info = &dev_info;
229 client_reg.EventMask =
230 CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
231 CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
232 CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
233 client_reg.event_handler = &sedlbauer_event;
234 client_reg.Version = 0x0210; 228 client_reg.Version = 0x0210;
235 client_reg.event_callback_args.client_data = link; 229 client_reg.event_callback_args.client_data = link;
236 ret = pcmcia_register_client(&link->handle, &client_reg); 230 ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -634,6 +628,7 @@ static struct pcmcia_driver sedlbauer_driver = {
634 .name = "sedlbauer_cs", 628 .name = "sedlbauer_cs",
635 }, 629 },
636 .attach = sedlbauer_attach, 630 .attach = sedlbauer_attach,
631 .event = sedlbauer_event,
637 .detach = sedlbauer_detach, 632 .detach = sedlbauer_detach,
638 .id_table = sedlbauer_ids, 633 .id_table = sedlbauer_ids,
639}; 634};
diff --git a/drivers/isdn/hisax/teles_cs.c b/drivers/isdn/hisax/teles_cs.c
index 107376ff5b9b..0ddef1bf778b 100644
--- a/drivers/isdn/hisax/teles_cs.c
+++ b/drivers/isdn/hisax/teles_cs.c
@@ -28,7 +28,6 @@
28#include <asm/io.h> 28#include <asm/io.h>
29#include <asm/system.h> 29#include <asm/system.h>
30 30
31#include <pcmcia/version.h>
32#include <pcmcia/cs_types.h> 31#include <pcmcia/cs_types.h>
33#include <pcmcia/cs.h> 32#include <pcmcia/cs.h>
34#include <pcmcia/cistpl.h> 33#include <pcmcia/cistpl.h>
@@ -193,11 +192,6 @@ static dev_link_t *teles_attach(void)
193 link->next = dev_list; 192 link->next = dev_list;
194 dev_list = link; 193 dev_list = link;
195 client_reg.dev_info = &dev_info; 194 client_reg.dev_info = &dev_info;
196 client_reg.EventMask =
197 CS_EVENT_CARD_INSERTION | CS_EVENT_CARD_REMOVAL |
198 CS_EVENT_RESET_PHYSICAL | CS_EVENT_CARD_RESET |
199 CS_EVENT_PM_SUSPEND | CS_EVENT_PM_RESUME;
200 client_reg.event_handler = &teles_cs_event;
201 client_reg.Version = 0x0210; 195 client_reg.Version = 0x0210;
202 client_reg.event_callback_args.client_data = link; 196 client_reg.event_callback_args.client_data = link;
203 ret = pcmcia_register_client(&link->handle, &client_reg); 197 ret = pcmcia_register_client(&link->handle, &client_reg);
@@ -501,6 +495,7 @@ static struct pcmcia_driver teles_cs_driver = {
501 .name = "teles_cs", 495 .name = "teles_cs",
502 }, 496 },
503 .attach = teles_attach, 497 .attach = teles_attach,
498 .event = teles_cs_event,
504 .detach = teles_detach, 499 .detach = teles_detach,
505 .id_table = teles_ids, 500 .id_table = teles_ids,
506}; 501};
diff --git a/drivers/isdn/i4l/isdn_tty.c b/drivers/isdn/i4l/isdn_tty.c
index ad5aa38fb5a6..b37ef1f06b3d 100644
--- a/drivers/isdn/i4l/isdn_tty.c
+++ b/drivers/isdn/i4l/isdn_tty.c
@@ -1223,7 +1223,7 @@ isdn_tty_write(struct tty_struct *tty, const u_char * buf, int count)
1223 total += c; 1223 total += c;
1224 } 1224 }
1225 atomic_dec(&info->xmit_lock); 1225 atomic_dec(&info->xmit_lock);
1226 if ((info->xmit_count) || (skb_queue_len(&info->xmit_queue))) { 1226 if ((info->xmit_count) || !skb_queue_empty(&info->xmit_queue)) {
1227 if (m->mdmreg[REG_DXMT] & BIT_DXMT) { 1227 if (m->mdmreg[REG_DXMT] & BIT_DXMT) {
1228 isdn_tty_senddown(info); 1228 isdn_tty_senddown(info);
1229 isdn_tty_tint(info); 1229 isdn_tty_tint(info);
@@ -1284,7 +1284,7 @@ isdn_tty_flush_chars(struct tty_struct *tty)
1284 1284
1285 if (isdn_tty_paranoia_check(info, tty->name, "isdn_tty_flush_chars")) 1285 if (isdn_tty_paranoia_check(info, tty->name, "isdn_tty_flush_chars"))
1286 return; 1286 return;
1287 if ((info->xmit_count) || (skb_queue_len(&info->xmit_queue))) 1287 if ((info->xmit_count) || !skb_queue_empty(&info->xmit_queue))
1288 isdn_timer_ctrl(ISDN_TIMER_MODEMXMIT, 1); 1288 isdn_timer_ctrl(ISDN_TIMER_MODEMXMIT, 1);
1289} 1289}
1290 1290
diff --git a/drivers/isdn/icn/icn.c b/drivers/isdn/icn/icn.c
index 9fc0c1e03732..e0d1b01cc74c 100644
--- a/drivers/isdn/icn/icn.c
+++ b/drivers/isdn/icn/icn.c
@@ -304,12 +304,12 @@ icn_pollbchan_send(int channel, icn_card * card)
304 isdn_ctrl cmd; 304 isdn_ctrl cmd;
305 305
306 if (!(card->sndcount[channel] || card->xskb[channel] || 306 if (!(card->sndcount[channel] || card->xskb[channel] ||
307 skb_queue_len(&card->spqueue[channel]))) 307 !skb_queue_empty(&card->spqueue[channel])))
308 return; 308 return;
309 if (icn_trymaplock_channel(card, mch)) { 309 if (icn_trymaplock_channel(card, mch)) {
310 while (sbfree && 310 while (sbfree &&
311 (card->sndcount[channel] || 311 (card->sndcount[channel] ||
312 skb_queue_len(&card->spqueue[channel]) || 312 !skb_queue_empty(&card->spqueue[channel]) ||
313 card->xskb[channel])) { 313 card->xskb[channel])) {
314 spin_lock_irqsave(&card->lock, flags); 314 spin_lock_irqsave(&card->lock, flags);
315 if (card->xmit_lock[channel]) { 315 if (card->xmit_lock[channel]) {