• Home
  • Raw
  • Download

Lines Matching refs:is

34 static int isdn_ppp_set_compressor(struct ippp_struct *is, struct isdn_ppp_comp_data *);
40 struct ippp_struct *is, struct ippp_struct *master, int type);
45 static void isdn_ppp_ccp_kickup(struct ippp_struct *is);
46 static void isdn_ppp_ccp_xmit_reset(struct ippp_struct *is, int proto,
49 static struct ippp_ccp_reset *isdn_ppp_ccp_reset_alloc(struct ippp_struct *is);
50 static void isdn_ppp_ccp_reset_free(struct ippp_struct *is);
51 static void isdn_ppp_ccp_reset_free_state(struct ippp_struct *is,
54 static struct ippp_ccp_reset_state *isdn_ppp_ccp_reset_alloc_state(struct ippp_struct *is,
56 static void isdn_ppp_ccp_reset_trans(struct ippp_struct *is,
58 static void isdn_ppp_ccp_reset_ack_rcvd(struct ippp_struct *is,
110 struct ippp_struct *is; in isdn_ppp_free() local
134 is = ippp_table[lp->ppp_slot]; in isdn_ppp_free()
135 if ((is->state & IPPP_CONNECT)) in isdn_ppp_free()
137 else if (is->state & IPPP_ASSIGNED) in isdn_ppp_free()
138 is->state = IPPP_OPEN; /* fallback to 'OPEN but not ASSIGNED' state */ in isdn_ppp_free()
140 if (is->debug & 0x1) in isdn_ppp_free()
141 printk(KERN_DEBUG "isdn_ppp_free %d %lx %lx\n", lp->ppp_slot, (long) lp, (long) is->lp); in isdn_ppp_free()
143 is->lp = NULL; /* link is down .. set lp to NULL */ in isdn_ppp_free()
160 struct ippp_struct *is; in isdn_ppp_bind() local
204 is = ippp_table[i]; in isdn_ppp_bind()
205 is->lp = lp; in isdn_ppp_bind()
206 is->unit = unit; in isdn_ppp_bind()
207 is->state = IPPP_OPEN | IPPP_ASSIGNED; /* assigned to a netdevice but not connected */ in isdn_ppp_bind()
245 struct ippp_struct *is; in isdn_ppp_closewait() local
252 is = ippp_table[slot]; in isdn_ppp_closewait()
253 if (is->state) in isdn_ppp_closewait()
254 wake_up_interruptible(&is->wq); in isdn_ppp_closewait()
255 is->state = IPPP_CLOSEWAIT; in isdn_ppp_closewait()
282 struct ippp_struct *is; in isdn_ppp_open() local
291 is = file->private_data = ippp_table[slot]; in isdn_ppp_open()
294 slot, min, is->state); in isdn_ppp_open()
297 is->link_compressor = is->compressor = NULL; in isdn_ppp_open()
298 is->link_decompressor = is->decompressor = NULL; in isdn_ppp_open()
299 is->link_comp_stat = is->comp_stat = NULL; in isdn_ppp_open()
300 is->link_decomp_stat = is->decomp_stat = NULL; in isdn_ppp_open()
301 is->compflags = 0; in isdn_ppp_open()
303 is->reset = isdn_ppp_ccp_reset_alloc(is); in isdn_ppp_open()
304 if (!is->reset) in isdn_ppp_open()
307 is->lp = NULL; in isdn_ppp_open()
308 is->mp_seqno = 0; /* MP sequence number */ in isdn_ppp_open()
309 is->pppcfg = 0; /* ppp configuration */ in isdn_ppp_open()
310 is->mpppcfg = 0; /* mppp configuration */ in isdn_ppp_open()
311 is->last_link_seqno = -1; /* MP: maybe set to Bundle-MIN, when joining a bundle ?? */ in isdn_ppp_open()
312 is->unit = -1; /* set, when we have our interface */ in isdn_ppp_open()
313 is->mru = 1524; /* MRU, default 1524 */ in isdn_ppp_open()
314 is->maxcid = 16; /* VJ: maxcid */ in isdn_ppp_open()
315 is->tk = current; in isdn_ppp_open()
316 init_waitqueue_head(&is->wq); in isdn_ppp_open()
317 is->first = is->rq + NUM_RCV_BUFFS - 1; /* receive queue */ in isdn_ppp_open()
318 is->last = is->rq; in isdn_ppp_open()
319 is->minor = min; in isdn_ppp_open()
324 is->slcomp = slhc_init(16, 16); /* not necessary for 2. link in bundle */ in isdn_ppp_open()
325 if (IS_ERR(is->slcomp)) { in isdn_ppp_open()
326 isdn_ppp_ccp_reset_free(is); in isdn_ppp_open()
327 return PTR_ERR(is->slcomp); in isdn_ppp_open()
331 is->pass_filter = NULL; in isdn_ppp_open()
332 is->active_filter = NULL; in isdn_ppp_open()
334 is->state = IPPP_OPEN; in isdn_ppp_open()
346 struct ippp_struct *is; in isdn_ppp_release() local
350 is = file->private_data; in isdn_ppp_release()
352 if (!is) { in isdn_ppp_release()
356 if (is->debug & 0x1) in isdn_ppp_release()
357 printk(KERN_DEBUG "ippp: release, minor: %d %lx\n", min, (long) is->lp); in isdn_ppp_release()
359 if (is->lp) { /* a lp address says: this link is still up */ in isdn_ppp_release()
360 isdn_net_dev *p = is->lp->netdev; in isdn_ppp_release()
366 is->state &= ~IPPP_CONNECT; /* -> effect: no call of wakeup */ in isdn_ppp_release()
375 kfree(is->rq[i].buf); in isdn_ppp_release()
376 is->rq[i].buf = NULL; in isdn_ppp_release()
378 is->first = is->rq + NUM_RCV_BUFFS - 1; /* receive queue */ in isdn_ppp_release()
379 is->last = is->rq; in isdn_ppp_release()
383 slhc_free(is->slcomp); in isdn_ppp_release()
384 is->slcomp = NULL; in isdn_ppp_release()
387 if (is->pass_filter) { in isdn_ppp_release()
388 bpf_prog_destroy(is->pass_filter); in isdn_ppp_release()
389 is->pass_filter = NULL; in isdn_ppp_release()
392 if (is->active_filter) { in isdn_ppp_release()
393 bpf_prog_destroy(is->active_filter); in isdn_ppp_release()
394 is->active_filter = NULL; in isdn_ppp_release()
399 if (is->comp_stat) in isdn_ppp_release()
400 is->compressor->free(is->comp_stat); in isdn_ppp_release()
401 if (is->link_comp_stat) in isdn_ppp_release()
402 is->link_compressor->free(is->link_comp_stat); in isdn_ppp_release()
403 if (is->link_decomp_stat) in isdn_ppp_release()
404 is->link_decompressor->free(is->link_decomp_stat); in isdn_ppp_release()
405 if (is->decomp_stat) in isdn_ppp_release()
406 is->decompressor->free(is->decomp_stat); in isdn_ppp_release()
407 is->compressor = is->link_compressor = NULL; in isdn_ppp_release()
408 is->decompressor = is->link_decompressor = NULL; in isdn_ppp_release()
409 is->comp_stat = is->link_comp_stat = NULL; in isdn_ppp_release()
410 is->decomp_stat = is->link_decomp_stat = NULL; in isdn_ppp_release()
413 if (is->reset) in isdn_ppp_release()
414 isdn_ppp_ccp_reset_free(is); in isdn_ppp_release()
417 is->state = 0; in isdn_ppp_release()
480 struct ippp_struct *is; in isdn_ppp_ioctl() local
485 is = file->private_data; in isdn_ppp_ioctl()
486 lp = is->lp; in isdn_ppp_ioctl()
488 if (is->debug & 0x1) in isdn_ppp_ioctl()
489 printk(KERN_DEBUG "isdn_ppp_ioctl: minor: %d cmd: %x state: %x\n", min, cmd, is->state); in isdn_ppp_ioctl()
491 if (!(is->state & IPPP_OPEN)) in isdn_ppp_ioctl()
497 if (!(is->state & IPPP_CONNECT)) in isdn_ppp_ioctl()
502 (int) min, (int) is->unit, (int) val); in isdn_ppp_ioctl()
503 return isdn_ppp_bundle(is, val); in isdn_ppp_ioctl()
509 if ((r = set_arg(argp, &is->unit, sizeof(is->unit)))) in isdn_ppp_ioctl()
520 if ((r = set_arg(argp, &is->mpppcfg, sizeof(is->mpppcfg)))) in isdn_ppp_ioctl()
526 is->mpppcfg = val; in isdn_ppp_ioctl()
529 if ((r = set_arg(argp, &is->pppcfg, sizeof(is->pppcfg)))) in isdn_ppp_ioctl()
536 if (val & SC_ENABLE_IP && !(is->pppcfg & SC_ENABLE_IP) && (is->state & IPPP_CONNECT)) { in isdn_ppp_ioctl()
539 is->pppcfg = val; /* isdn_ppp_xmit test for SC_ENABLE_IP !!! */ in isdn_ppp_ioctl()
544 is->pppcfg = val; in isdn_ppp_ioctl()
557 is->mru = val; in isdn_ppp_ioctl()
567 if (is->maxcid != val) { in isdn_ppp_ioctl()
571 if (is->debug & 0x1) in isdn_ppp_ioctl()
573 is->maxcid = val; in isdn_ppp_ioctl()
578 if (is->slcomp) in isdn_ppp_ioctl()
579 slhc_free(is->slcomp); in isdn_ppp_ioctl()
580 is->slcomp = sltmp; in isdn_ppp_ioctl()
585 if ((r = set_arg(argp, &is->debug, sizeof(is->debug)))) in isdn_ppp_ioctl()
591 is->debug = val; in isdn_ppp_ioctl()
611 return isdn_ppp_set_compressor(is, &data); in isdn_ppp_ioctl()
645 if (is->pass_filter) { in isdn_ppp_ioctl()
646 bpf_prog_destroy(is->pass_filter); in isdn_ppp_ioctl()
647 is->pass_filter = NULL; in isdn_ppp_ioctl()
650 err = bpf_prog_create(&is->pass_filter, &fprog); in isdn_ppp_ioctl()
669 if (is->active_filter) { in isdn_ppp_ioctl()
670 bpf_prog_destroy(is->active_filter); in isdn_ppp_ioctl()
671 is->active_filter = NULL; in isdn_ppp_ioctl()
674 err = bpf_prog_create(&is->active_filter, &fprog); in isdn_ppp_ioctl()
694 struct ippp_struct *is; in isdn_ppp_poll() local
696 is = file->private_data; in isdn_ppp_poll()
698 if (is->debug & 0x2) in isdn_ppp_poll()
703 poll_wait(file, &is->wq, wait); in isdn_ppp_poll()
705 if (!(is->state & IPPP_OPEN)) { in isdn_ppp_poll()
706 if (is->state == IPPP_CLOSEWAIT) in isdn_ppp_poll()
714 spin_lock_irqsave(&is->buflock, flags); in isdn_ppp_poll()
715 bl = is->last; in isdn_ppp_poll()
716 bf = is->first; in isdn_ppp_poll()
720 if (bf->next != bl || (is->state & IPPP_NOBLOCK)) { in isdn_ppp_poll()
721 is->state &= ~IPPP_NOBLOCK; in isdn_ppp_poll()
724 spin_unlock_irqrestore(&is->buflock, flags); in isdn_ppp_poll()
738 struct ippp_struct *is; in isdn_ppp_fill_rq() local
744 is = ippp_table[slot]; in isdn_ppp_fill_rq()
746 if (!(is->state & IPPP_CONNECT)) { in isdn_ppp_fill_rq()
761 spin_lock_irqsave(&is->buflock, flags); in isdn_ppp_fill_rq()
762 bf = is->first; in isdn_ppp_fill_rq()
763 bl = is->last; in isdn_ppp_fill_rq()
769 is->first = bf; in isdn_ppp_fill_rq()
774 is->last = bl->next; in isdn_ppp_fill_rq()
775 spin_unlock_irqrestore(&is->buflock, flags); in isdn_ppp_fill_rq()
776 wake_up_interruptible(&is->wq); in isdn_ppp_fill_rq()
788 struct ippp_struct *is; in isdn_ppp_read() local
793 is = file->private_data; in isdn_ppp_read()
795 if (!(is->state & IPPP_OPEN)) in isdn_ppp_read()
801 spin_lock_irqsave(&is->buflock, flags); in isdn_ppp_read()
802 b = is->first->next; in isdn_ppp_read()
805 spin_unlock_irqrestore(&is->buflock, flags); in isdn_ppp_read()
811 is->first = b; in isdn_ppp_read()
813 spin_unlock_irqrestore(&is->buflock, flags); in isdn_ppp_read()
829 struct ippp_struct *is; in isdn_ppp_write() local
832 is = file->private_data; in isdn_ppp_write()
834 if (!(is->state & IPPP_CONNECT)) in isdn_ppp_write()
837 lp = is->lp; in isdn_ppp_write()
893 if (is->debug & 0x40) { in isdn_ppp_write()
895 isdn_ppp_frame_log("xmit", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_write()
961 static int isdn_ppp_skip_ac(struct ippp_struct *is, struct sk_buff *skb) in isdn_ppp_skip_ac() argument
976 if (is->pppcfg & SC_REJ_COMP_AC) in isdn_ppp_skip_ac()
1013 struct ippp_struct *is; in isdn_ppp_receive() local
1026 is = ippp_table[slot]; in isdn_ppp_receive()
1028 if (is->debug & 0x4) { in isdn_ppp_receive()
1030 (long)is, (long)lp, lp->ppp_slot, is->unit, (int)skb->len); in isdn_ppp_receive()
1031 isdn_ppp_frame_log("receive", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_receive()
1034 if (isdn_ppp_skip_ac(is, skb) < 0) { in isdn_ppp_receive()
1045 if (is->compflags & SC_LINK_DECOMP_ON) { in isdn_ppp_receive()
1046 skb = isdn_ppp_decompress(skb, is, NULL, &proto); in isdn_ppp_receive()
1051 if (!(is->mpppcfg & SC_REJ_MP_PROT)) { // we agreed to receive MPPP in isdn_ppp_receive()
1070 struct ippp_struct *is, *mis; in isdn_ppp_push_higher() local
1080 is = ippp_table[slot]; in isdn_ppp_push_higher()
1093 if (is->debug & 0x10) { in isdn_ppp_push_higher()
1095 isdn_ppp_frame_log("rpush", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_push_higher()
1098 skb = isdn_ppp_decompress(skb, is, mis, &proto); in isdn_ppp_push_higher()
1104 if (is->debug & 0x20) in isdn_ppp_push_higher()
1109 if (is->debug & 0x20) in isdn_ppp_push_higher()
1119 if (is->debug & 0x20) in isdn_ppp_push_higher()
1133 if (is->debug & 0x20) in isdn_ppp_push_higher()
1191 if (is->pass_filter in isdn_ppp_push_higher()
1192 && BPF_PROG_RUN(is->pass_filter, skb) == 0) { in isdn_ppp_push_higher()
1193 if (is->debug & 0x2) in isdn_ppp_push_higher()
1198 if (!(is->active_filter in isdn_ppp_push_higher()
1199 && BPF_PROG_RUN(is->active_filter, skb) == 0)) { in isdn_ppp_push_higher()
1200 if (is->debug & 0x2) in isdn_ppp_push_higher()
1503 struct ippp_struct *is = ippp_table[lp->ppp_slot]; in isdn_ppp_autodial_filter() local
1534 drop |= is->pass_filter in isdn_ppp_autodial_filter()
1535 && BPF_PROG_RUN(is->pass_filter, skb) == 0; in isdn_ppp_autodial_filter()
1536 drop |= is->active_filter in isdn_ppp_autodial_filter()
1537 && BPF_PROG_RUN(is->active_filter, skb) == 0; in isdn_ppp_autodial_filter()
1590 struct ippp_struct *is; in isdn_ppp_mp_init() local
1598 is = ippp_table[lp->ppp_slot]; in isdn_ppp_mp_init()
1604 is->mp_seqno = 0; in isdn_ppp_mp_init()
1614 is->last_link_seqno = 0; in isdn_ppp_mp_init()
1630 struct ippp_struct *is; in isdn_ppp_mp_receive() local
1651 is = ippp_table[slot]; in isdn_ppp_mp_receive()
1655 if (is->debug & 0x8) in isdn_ppp_mp_receive()
1658 newseq = isdn_ppp_mp_get_seq(is->mpppcfg & SC_IN_SHORT_SEQ, in isdn_ppp_mp_receive()
1659 skb, is->last_link_seqno); in isdn_ppp_mp_receive()
1677 is->last_link_seqno = minseq = newseq; in isdn_ppp_mp_receive()
1974 isdn_ppp_bundle(struct ippp_struct *is, int unit) in isdn_ppp_bundle() argument
1991 nlp = is->lp; in isdn_ppp_bundle()
2195 static void isdn_ppp_ccp_kickup(struct ippp_struct *is) in isdn_ppp_ccp_kickup() argument
2197 isdn_ppp_fill_rq(NULL, 0, PPP_COMP, is->lp->ppp_slot); in isdn_ppp_ccp_kickup()
2235 static void isdn_ppp_ccp_xmit_reset(struct ippp_struct *is, int proto, in isdn_ppp_ccp_xmit_reset() argument
2243 isdn_net_local *lp = is->lp; in isdn_ppp_ccp_xmit_reset()
2256 if (!(is->pppcfg & SC_COMP_AC)) { in isdn_ppp_ccp_xmit_reset()
2280 isdn_ppp_frame_log("ccp-xmit", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_ccp_xmit_reset()
2286 static struct ippp_ccp_reset *isdn_ppp_ccp_reset_alloc(struct ippp_struct *is) in isdn_ppp_ccp_reset_alloc() argument
2296 is->reset = r; in isdn_ppp_ccp_reset_alloc()
2301 static void isdn_ppp_ccp_reset_free(struct ippp_struct *is) in isdn_ppp_ccp_reset_free() argument
2306 is->reset); in isdn_ppp_ccp_reset_free()
2308 if (is->reset->rs[id]) { in isdn_ppp_ccp_reset_free()
2309 isdn_ppp_ccp_reset_free_state(is, (unsigned char)id); in isdn_ppp_ccp_reset_free()
2312 kfree(is->reset); in isdn_ppp_ccp_reset_free()
2313 is->reset = NULL; in isdn_ppp_ccp_reset_free()
2317 static void isdn_ppp_ccp_reset_free_state(struct ippp_struct *is, in isdn_ppp_ccp_reset_free_state() argument
2322 if (is->reset->rs[id]) { in isdn_ppp_ccp_reset_free_state()
2324 rs = is->reset->rs[id]; in isdn_ppp_ccp_reset_free_state()
2328 is->reset->rs[id] = NULL; in isdn_ppp_ccp_reset_free_state()
2353 isdn_ppp_ccp_reset_free_state(rs->is, rs->id); in isdn_ppp_ccp_timer_callback()
2359 isdn_ppp_ccp_xmit_reset(rs->is, PPP_CCP, CCP_RESETREQ, rs->id, in isdn_ppp_ccp_timer_callback()
2371 static struct ippp_ccp_reset_state *isdn_ppp_ccp_reset_alloc_state(struct ippp_struct *is, in isdn_ppp_ccp_reset_alloc_state() argument
2375 if (is->reset->rs[id]) { in isdn_ppp_ccp_reset_alloc_state()
2384 rs->is = is; in isdn_ppp_ccp_reset_alloc_state()
2389 is->reset->rs[id] = rs; in isdn_ppp_ccp_reset_alloc_state()
2397 static void isdn_ppp_ccp_reset_trans(struct ippp_struct *is, in isdn_ppp_ccp_reset_trans() argument
2411 if (is->reset->rs[rp->id]) { in isdn_ppp_ccp_reset_trans()
2415 rs = is->reset->rs[rp->id]; in isdn_ppp_ccp_reset_trans()
2429 rs = isdn_ppp_ccp_reset_alloc_state(is, rp->id); in isdn_ppp_ccp_reset_trans()
2442 isdn_ppp_ccp_xmit_reset(is, PPP_CCP, in isdn_ppp_ccp_reset_trans()
2458 if (is->reset->rs[is->reset->lastid]) { in isdn_ppp_ccp_reset_trans()
2462 rs = is->reset->rs[is->reset->lastid]; in isdn_ppp_ccp_reset_trans()
2474 " %d to be started\n", is->reset->lastid); in isdn_ppp_ccp_reset_trans()
2475 rs = isdn_ppp_ccp_reset_alloc_state(is, in isdn_ppp_ccp_reset_trans()
2476 is->reset->lastid); in isdn_ppp_ccp_reset_trans()
2488 isdn_ppp_ccp_xmit_reset(is, PPP_CCP, CCP_RESETREQ, in isdn_ppp_ccp_reset_trans()
2500 static void isdn_ppp_ccp_reset_ack_rcvd(struct ippp_struct *is, in isdn_ppp_ccp_reset_ack_rcvd() argument
2503 struct ippp_ccp_reset_state *rs = is->reset->rs[id]; in isdn_ppp_ccp_reset_ack_rcvd()
2519 isdn_ppp_ccp_reset_free_state(is, id); in isdn_ppp_ccp_reset_ack_rcvd()
2525 is->reset->lastid++; in isdn_ppp_ccp_reset_ack_rcvd()
2540 static struct sk_buff *isdn_ppp_decompress(struct sk_buff *skb, struct ippp_struct *is, struct ippp… in isdn_ppp_decompress() argument
2553 stat = is->link_decomp_stat; in isdn_ppp_decompress()
2554 ipc = is->link_decompressor; in isdn_ppp_decompress()
2555 ri = is; in isdn_ppp_decompress()
2577 skb_out = dev_alloc_skb(is->mru + PPP_HDRLEN); in isdn_ppp_decompress()
2624 struct ippp_struct *is, struct ippp_struct *master, int type) in isdn_ppp_compress() argument
2642 compressor = is->compressor; in isdn_ppp_compress()
2643 stat = is->comp_stat; in isdn_ppp_compress()
2686 struct ippp_struct *is; in isdn_ppp_receive_ccp() local
2699 is = ippp_table[lp->ppp_slot]; in isdn_ppp_receive_ccp()
2700 isdn_ppp_frame_log("ccp-rcv", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_receive_ccp()
2711 mis = is; in isdn_ppp_receive_ccp()
2715 if (is->debug & 0x10) in isdn_ppp_receive_ccp()
2720 is->compflags &= ~SC_LINK_COMP_ON; in isdn_ppp_receive_ccp()
2724 if (is->debug & 0x10) in isdn_ppp_receive_ccp()
2729 is->compflags &= ~(SC_LINK_DECOMP_ON | SC_LINK_COMP_ON); in isdn_ppp_receive_ccp()
2733 if (is->debug & 0x10) in isdn_ppp_receive_ccp()
2740 if (!is->decompressor) in isdn_ppp_receive_ccp()
2742 is->compflags |= SC_LINK_DECOMP_ON; in isdn_ppp_receive_ccp()
2766 isdn_ppp_ccp_reset_ack_rcvd(is, skb->data[1]); in isdn_ppp_receive_ccp()
2767 if (is->link_decompressor && is->link_decomp_stat) in isdn_ppp_receive_ccp()
2768 is->link_decompressor-> in isdn_ppp_receive_ccp()
2769 reset(is->link_decomp_stat, in isdn_ppp_receive_ccp()
2775 is->compflags &= ~SC_LINK_DECOMP_DISCARD; in isdn_ppp_receive_ccp()
2799 if (is->link_compressor && is->link_comp_stat) in isdn_ppp_receive_ccp()
2800 is->link_compressor-> in isdn_ppp_receive_ccp()
2801 reset(is->link_comp_stat, in isdn_ppp_receive_ccp()
2812 isdn_ppp_ccp_xmit_reset(is, proto, CCP_RESETACK, in isdn_ppp_receive_ccp()
2824 isdn_ppp_ccp_xmit_reset(is, proto, CCP_RESETACK, in isdn_ppp_receive_ccp()
2862 struct ippp_struct *mis, *is; in isdn_ppp_send_ccp() local
2873 is = ippp_table[slot]; in isdn_ppp_send_ccp()
2876 if (!(is->pppcfg & SC_COMP_AC) && data[0] == 0xff && data[1] == 0x03) { in isdn_ppp_send_ccp()
2887 isdn_ppp_frame_log("ccp-xmit", skb->data, skb->len, 32, is->unit, lp->ppp_slot); in isdn_ppp_send_ccp()
2898 mis = is; in isdn_ppp_send_ccp()
2899 if (mis != is) in isdn_ppp_send_ccp()
2904 if (is->debug & 0x10) in isdn_ppp_send_ccp()
2907 is->compflags &= ~SC_DECOMP_ON; in isdn_ppp_send_ccp()
2909 is->compflags &= ~SC_LINK_DECOMP_ON; in isdn_ppp_send_ccp()
2913 if (is->debug & 0x10) in isdn_ppp_send_ccp()
2916 is->compflags &= ~(SC_DECOMP_ON | SC_COMP_ON); in isdn_ppp_send_ccp()
2918 is->compflags &= ~(SC_LINK_DECOMP_ON | SC_LINK_COMP_ON); in isdn_ppp_send_ccp()
2922 if (is->debug & 0x10) in isdn_ppp_send_ccp()
2925 if (!is->compressor) in isdn_ppp_send_ccp()
2927 is->compflags |= SC_COMP_ON; in isdn_ppp_send_ccp()
2929 if (!is->compressor) in isdn_ppp_send_ccp()
2931 is->compflags |= SC_LINK_COMP_ON; in isdn_ppp_send_ccp()
2936 if (is->debug & 0x10) in isdn_ppp_send_ccp()
2941 if (is->compressor && is->comp_stat) in isdn_ppp_send_ccp()
2942 is->compressor->reset(is->comp_stat, 0, 0, in isdn_ppp_send_ccp()
2944 is->compflags &= ~SC_COMP_DISCARD; in isdn_ppp_send_ccp()
2947 if (is->link_compressor && is->link_comp_stat) in isdn_ppp_send_ccp()
2948 is->link_compressor->reset(is->link_comp_stat, in isdn_ppp_send_ccp()
2950 is->compflags &= ~SC_LINK_COMP_DISCARD; in isdn_ppp_send_ccp()
2983 static int isdn_ppp_set_compressor(struct ippp_struct *is, struct isdn_ppp_comp_data *data) in isdn_ppp_set_compressor() argument
2990 if (is->debug & 0x10) in isdn_ppp_set_compressor()
2991 printk(KERN_DEBUG "[%d] Set %s type %d\n", is->unit, in isdn_ppp_set_compressor()
2998 if (!(data->flags & IPPP_COMP_FLAG_XMIT) && !is->reset) { in isdn_ppp_set_compressor()
3008 ret = ipc->init(stat, data, is->unit, 0); in isdn_ppp_set_compressor()
3023 if (is->link_comp_stat) in isdn_ppp_set_compressor()
3024 is->link_compressor->free(is->link_comp_stat); in isdn_ppp_set_compressor()
3025 is->link_comp_stat = stat; in isdn_ppp_set_compressor()
3026 is->link_compressor = ipc; in isdn_ppp_set_compressor()
3029 if (is->comp_stat) in isdn_ppp_set_compressor()
3030 is->compressor->free(is->comp_stat); in isdn_ppp_set_compressor()
3031 is->comp_stat = stat; in isdn_ppp_set_compressor()
3032 is->compressor = ipc; in isdn_ppp_set_compressor()
3037 if (is->link_decomp_stat) in isdn_ppp_set_compressor()
3038 is->link_decompressor->free(is->link_decomp_stat); in isdn_ppp_set_compressor()
3039 is->link_decomp_stat = stat; in isdn_ppp_set_compressor()
3040 is->link_decompressor = ipc; in isdn_ppp_set_compressor()
3043 if (is->decomp_stat) in isdn_ppp_set_compressor()
3044 is->decompressor->free(is->decomp_stat); in isdn_ppp_set_compressor()
3045 is->decomp_stat = stat; in isdn_ppp_set_compressor()
3046 is->decompressor = ipc; in isdn_ppp_set_compressor()