Lines Matching refs:this
81 ENTITY *this = NULL; in pr_out() local
108 this = entity_ptr(a, e_no); in pr_out()
110 if (!this) in pr_out()
119 DBG_TRC((">A%d Id=0x%x Req=0x%x", ((ISDN_ADAPTER *)a->io)->ANum, this->Id, this->Req)) in pr_out()
122 dbug(dprintf("out:Req=%x,Id=%x,Ch=%x", this->Req, this->Id, this->ReqCh)); in pr_out()
127 if (!(a->tx_stream[this->Id] && in pr_out()
128 this->Req == N_DATA)) { in pr_out()
133 i = this->XCurrent; in pr_out()
134 X = PTR_X(a, this); in pr_out()
135 while (i < this->XNum && length < 270) { in pr_out()
136 clength = min((word)(270 - length), (word)(X[i].PLength-this->XOffset)); in pr_out()
139 PTR_P(a, this, &X[i].P[this->XOffset]), in pr_out()
142 this->XOffset += clength; in pr_out()
143 if (this->XOffset == X[i].PLength) { in pr_out()
144 this->XCurrent = (byte)++i; in pr_out()
145 this->XOffset = 0; in pr_out()
150 i = this->XCurrent; in pr_out()
151 X = PTR_X(a, this); in pr_out()
152 while (i < this->XNum) { in pr_out()
154 this->Id, in pr_out()
155 PTR_P(a, this, &X[i].P[0]), in pr_out()
157 ((i + 1) == this->XNum), in pr_out()
159 this->XCurrent = (byte)++i; in pr_out()
165 a->ram_out(a, &ReqOut->ReqId, this->Id); in pr_out()
166 a->ram_out(a, &ReqOut->ReqCh, this->ReqCh); in pr_out()
168 if (this->Id & 0x1f) { in pr_out()
171 this->More++; in pr_out()
172 if (i < this->XNum && this->MInd) { in pr_out()
173 xdi_xlog_request(XDI_A_NR(a), this->Id, this->ReqCh, this->MInd, in pr_out()
174 a->IdTypeTable[this->No]); in pr_out()
175 a->ram_out(a, &ReqOut->Req, this->MInd); in pr_out()
179 xdi_xlog_request(XDI_A_NR(a), this->Id, this->ReqCh, this->Req, in pr_out()
180 a->IdTypeTable[this->No]); in pr_out()
181 this->More |= XMOREF; in pr_out()
182 a->ram_out(a, &ReqOut->Req, this->Req); in pr_out()
184 if (a->FlowControlIdTable[this->ReqCh] == this->Id) in pr_out()
185 a->FlowControlSkipTable[this->ReqCh] = true; in pr_out()
189 if (this->Req == REMOVE) { in pr_out()
196 req_queue(a, this->No); in pr_out()
202 this->MInd = 0; in pr_out()
203 if (this->Id == BLLC_ID) this->MInd = LL_MDATA; in pr_out()
204 if (this->Id == NL_ID || in pr_out()
205 this->Id == TASK_ID || in pr_out()
206 this->Id == MAN_ID in pr_out()
207 ) this->MInd = N_MDATA; in pr_out()
209 a->IdTypeTable[this->No] = this->Id; in pr_out()
210 xdi_xlog_request(XDI_A_NR(a), this->Id, this->ReqCh, this->Req, this->Id); in pr_out()
211 this->More |= XMOREF; in pr_out()
212 a->ram_out(a, &ReqOut->Req, this->Req); in pr_out()
214 assign_queue(a, this->No, a->ram_inw(a, &ReqOut->Reference)); in pr_out()
226 if (this && (this->Req == UREMOVE) && this->Id) { in pr_out()
227 Id = this->Id; in pr_out()
236 this->Id = 0; in pr_out()
364 ENTITY *this; in isdn_rc() local
387 this = entity_ptr(a, e_no); in isdn_rc()
388 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 0, a->IdTypeTable[this->No]); in isdn_rc()
389 this->RcCh = Ch; in isdn_rc()
413 this->Id = 0; in isdn_rc()
422 if ((this->More & XMOREC) > 1) { in isdn_rc()
423 this->More &= ~XMOREC; in isdn_rc()
424 this->More |= 1; in isdn_rc()
432 this->Rc = Rc; in isdn_rc()
433 this->More &= ~(XBUSY | XMOREC); in isdn_rc()
434 this->complete = 0xff; in isdn_rc()
435 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 1, a->IdTypeTable[this->No]); in isdn_rc()
436 CALLBACK(a, this); in isdn_rc()
451 this->Rc = Rc; in isdn_rc()
452 this->complete = 0xff; in isdn_rc()
453 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 1, a->IdTypeTable[this->No]); in isdn_rc()
456 CALLBACK(a, this); in isdn_rc()
465 this->Rc = Rc; in isdn_rc()
466 if (Ch == this->ReqCh) in isdn_rc()
468 this->More &= ~(XBUSY | XMOREC); in isdn_rc()
469 this->complete = 0xff; in isdn_rc()
471 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 1, a->IdTypeTable[this->No]); in isdn_rc()
472 CALLBACK(a, this); in isdn_rc()
476 if (this->More & XMOREC) in isdn_rc()
477 this->More--; in isdn_rc()
479 if (((!cancel_rc) || (this->More & XMOREF)) && !(this->More & XMOREC)) { in isdn_rc()
480 this->Rc = Rc; in isdn_rc()
481 this->More &= ~XBUSY; in isdn_rc()
482 this->complete = 0xff; in isdn_rc()
483 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 1, a->IdTypeTable[this->No]); in isdn_rc()
484 CALLBACK(a, this); in isdn_rc()
493 this = entity_ptr(a, e_no); in isdn_rc()
494 this->Id = Id; in isdn_rc()
495 xdi_xlog_rc_event(XDI_A_NR(a), Id, Ch, Rc, 2, a->IdTypeTable[this->No]); in isdn_rc()
497 this->Rc = Rc; in isdn_rc()
498 this->More &= ~XBUSY; in isdn_rc()
499 this->complete = 0xff; in isdn_rc()
502 (a->IdTypeTable[this->No] == NL_ID) && in isdn_rc()
519 a->misc_flags_table[this->No] |= DIVA_MISC_FLAGS_RX_DMA; in isdn_rc()
523 a->misc_flags_table[this->No] &= ~DIVA_MISC_FLAGS_RX_DMA; in isdn_rc()
532 a->misc_flags_table[this->No] &= ~DIVA_MISC_FLAGS_RX_DMA; in isdn_rc()
535 CALLBACK(a, this); in isdn_rc()
548 this->Id = 0; in isdn_rc()
566 ENTITY *this; in isdn_ind() local
579 this = entity_ptr(a, a->IdTable[Id]); in isdn_ind()
580 this->IndCh = Ch; in isdn_ind()
582 0/* rnr_valid */, 0 /* rnr */, a->IdTypeTable[this->No]); in isdn_ind()
585 if (this->RCurrent == 0xff) { in isdn_ind()
587 if (Ind == this->MInd) { in isdn_ind()
588 this->complete = 0; in isdn_ind()
589 this->Ind = MInd; in isdn_ind()
592 this->complete = 1; in isdn_ind()
593 this->Ind = Ind; in isdn_ind()
597 this->RLength = MLength; in isdn_ind()
599 if ((a->rx_stream[this->Id] || in isdn_ind()
600 (a->misc_flags_table[this->No] & DIVA_MISC_FLAGS_RX_DMA)) && in isdn_ind()
604 if (a->misc_flags_table[this->No] & DIVA_MISC_FLAGS_RX_DMA) { in isdn_ind()
609 (int)a->rx_stream[this->Id], (void **)&cma, &d); in isdn_ind()
614 this->RLength = MLength = (word)*(dword *)cma; in isdn_ind()
619 this->RLength = MLength = (word)diva_istream_read(a, in isdn_ind()
627 this->complete = 0; in isdn_ind()
629 this->complete = 1; in isdn_ind()
632 this->RBuffer = (DBUFFER *)&IoAdapter->RBuffer; in isdn_ind()
636 a->ram_look_ahead(a, RBuffer, this); in isdn_ind()
638 this->RNum = 0; in isdn_ind()
639 CALLBACK(a, this); in isdn_ind()
642 this = entity_ptr(a, a->IdTable[Id]); in isdn_ind()
644 1/* rnr_valid */, this->RNR/* rnr */, a->IdTypeTable[this->No]); in isdn_ind()
646 if (this->RNR == 1) { in isdn_ind()
647 this->RNR = 0; in isdn_ind()
653 if (!this->RNR && !this->RNum) { in isdn_ind()
655 2/* rnr_valid */, 0/* rnr */, a->IdTypeTable[this->No]); in isdn_ind()
659 this->RCurrent = 0; in isdn_ind()
660 this->ROffset = 0; in isdn_ind()
662 if (this->RNR == 2) { in isdn_ind()
663 if (Ind != this->MInd) { in isdn_ind()
664 this->RCurrent = 0xff; in isdn_ind()
665 this->RNR = 0; in isdn_ind()
672 R = PTR_R(a, this); in isdn_ind()
674 if (this->ROffset == R[this->RCurrent].PLength) { in isdn_ind()
675 this->ROffset = 0; in isdn_ind()
676 this->RCurrent++; in isdn_ind()
679 clength = min(MLength, (word)(R[this->RCurrent].PLength-this->ROffset)); in isdn_ind()
682 R[this->RCurrent].PLength-this->ROffset); in isdn_ind()
684 if (R[this->RCurrent].P) { in isdn_ind()
686 memcpy(PTR_P(a, this, &R[this->RCurrent].P[this->ROffset]), in isdn_ind()
692 PTR_P(a, this, &R[this->RCurrent].P[this->ROffset]), in isdn_ind()
697 this->ROffset += clength; in isdn_ind()
708 if (Ind != this->MInd) { in isdn_ind()
709 R[this->RCurrent].PLength = this->ROffset; in isdn_ind()
710 if (this->ROffset) this->RCurrent++; in isdn_ind()
711 this->RNum = this->RCurrent; in isdn_ind()
712 this->RCurrent = 0xff; in isdn_ind()
713 this->Ind = Ind; in isdn_ind()
714 this->complete = 2; in isdn_ind()
716 3/* rnr_valid */, 0/* rnr */, a->IdTypeTable[this->No]); in isdn_ind()
717 CALLBACK(a, this); in isdn_ind()