Lines Matching defs:lq

544 	consms_lq_t		*lq = (consms_lq_t *)q->q_ptr;
546 ASSERT(lq != NULL);
582 if (lq->lq_ioc_reply_func != NULL) {
584 lq->lq_ioc_reply_func(lq, mp);
634 consms_lq_t *lq;
642 for (lq = consms_state.consms_lqs; lq != NULL; lq = lq->lq_next) {
643 if (lq->lq_queue == linkp->l_qbot) {
645 prev_lq->lq_next = lq->lq_next;
647 consms_state.consms_lqs = lq->lq_next;
648 kmem_free(lq, sizeof (*lq));
659 prev_lq = lq;
672 consms_lq_t *lq;
680 lq = kmem_zalloc(sizeof (*lq), KM_SLEEP);
682 lowq->q_ptr = (void *)lq;
683 OTHERQ(lowq)->q_ptr = (void *)lq;
684 lq->lq_queue = lowq;
685 lq->lq_pending_plink = mp;
686 lq->lq_pending_queue = q;
692 lq->lq_num_buttons = 3;
697 lq->lq_state = LQS_START;
698 consms_lqs_ack_complete(lq, NULL);
707 consms_lqs_ack_complete(consms_lq_t *lq, mblk_t *mp)
719 * until we reach LQS_DONE, and then add this lq
720 * into our lq list.
726 while ((lq->lq_state < LQS_DONE) && (req == NULL)) {
727 switch (lq->lq_state) {
741 lq->lq_state++;
747 lq->lq_num_buttons =
762 lq->lq_state++;
768 lq->lq_num_wheels =
786 lq->lq_state++;
808 lq->lq_state++;
827 lq->lq_state++;
849 lq->lq_state++;
854 * All jobs are done, lq->lq_state is turned into
855 * LQS_DONE, and this lq is added into our list.
857 lq->lq_state++;
858 consms_add_lq(lq);
863 if (lq->lq_state < LQS_DONE) {
864 lq->lq_ioc_reply_func = consms_lqs_ack_complete;
865 (void) putq(lq->lq_queue, req);
870 * Add this specific lq into our list, finally reply
877 consms_add_lq(consms_lq_t *lq)
883 lq->lq_ioc_reply_func = NULL;
884 iocp = (struct iocblk *)lq->lq_pending_plink->b_rptr;
888 lq->lq_pending_plink->b_datap->db_type = M_IOCACK;
891 qreply(lq->lq_pending_queue, lq->lq_pending_plink);
893 lq->lq_pending_plink = NULL;
894 lq->lq_pending_queue = NULL;
897 * Add this lq into list.
901 lq->lq_next = consms_state.consms_lqs;
902 consms_state.consms_lqs = lq;
916 consms_lq_t *lq;
925 for (lq = consms_state.consms_lqs; lq != NULL; lq = lq->lq_next) {
926 max_buttons = CONSMS_MAX(max_buttons, lq->lq_num_buttons);
927 max_wheels = CONSMS_MAX(max_wheels, lq->lq_num_wheels);
1356 consms_lq_t *lq;
1368 for (lq = consms_state.consms_lqs; lq != NULL; lq = lq->lq_next) {
1370 (void) putq(lq->lq_queue, copy_mp);
1373 * If copymsg fails, we ignore this lq and
1404 consms_lq_t *lq;
1407 for (lq = consms_state.consms_lqs; lq != NULL; lq = lq->lq_next) {
1409 (void) putq(lq->lq_queue, copy_mp);