Lines Matching refs:qrp
507 queue_root_t *qrp;
517 for (cnt = 0, qrp = qp->qh_hlist; qrp != NULL; qrp = qrp->qr_next) {
519 ASSERT((qrp->qr_head != NULL && qrp->qr_tail != NULL) ||
520 (qrp->qr_head == NULL && qrp->qr_tail == NULL));
528 for (cnt = 0, qrp = qp->qh_hlist; qrp != NULL; qrp = qrp->qr_next) {
529 for (prev = NULL, ulwp = qrp->qr_head; ulwp != NULL;
538 ASSERT(qrp->qr_wchan == wchan);
542 ASSERT(qrp->qr_tail == prev);
561 queue_root_t *qrp;
575 for (qrp = qp->qh_hlist; qrp != NULL; qrp = qrp->qr_next)
576 if (qrp->qr_wchan == wchan)
578 if (qrp == NULL && qp->qh_def_root.qr_head == NULL) {
580 qrp = &qp->qh_def_root;
581 qrp->qr_wchan = wchan;
582 ASSERT(qrp->qr_next == NULL);
583 ASSERT(qrp->qr_tail == NULL &&
584 qrp->qr_rtcount == 0 && qrp->qr_qlen == 0);
587 qp->qh_root = qrp; /* valid until queue_unlock() is called */
613 queue_root_t *qrp;
621 if ((qrp = qp->qh_root) == NULL) {
623 qrp = &ulwp->ul_queue_root;
624 qrp->qr_next = qp->qh_hlist;
625 qrp->qr_prev = NULL;
626 qrp->qr_head = NULL;
627 qrp->qr_tail = NULL;
628 qrp->qr_wchan = qp->qh_wchan;
629 qrp->qr_rtcount = 0;
630 qrp->qr_qlen = 0;
631 qrp->qr_qmax = 0;
632 qp->qh_hlist->qr_prev = qrp;
633 qp->qh_hlist = qrp;
634 qp->qh_root = qrp;
661 if (qrp->qr_head == NULL) {
665 ASSERT(qrp->qr_tail == NULL);
666 ulwpp = &qrp->qr_head;
674 if (pri <= CMP_PRIO(qrp->qr_tail))
675 ulwpp = &qrp->qr_tail->ul_link;
677 for (ulwpp = &qrp->qr_head; (next = *ulwpp) != NULL;
688 for (ulwpp = &qrp->qr_head; (next = *ulwpp) != NULL;
694 qrp->qr_tail = ulwp;
704 qrp->qr_rtcount++;
706 MAXINCR(qrp->qr_qmax, qrp->qr_qlen);
782 queue_root_t *qrp;
789 if ((qrp = qp->qh_root) == NULL || (ulwp = qrp->qr_head) == NULL) {
793 rt = (qrp->qr_rtcount != 0);
798 return (&qrp->qr_head);
803 return (queue_slot_rt(&qrp->qr_head, prevp));
809 (ulwpp = queue_slot_runnable(&qrp->qr_head, prevp, 0)) != NULL) {
818 return (&qrp->qr_head);
827 queue_root_t *qrp = qp->qh_root;
836 DECR(qrp->qr_qlen);
839 qrp->qr_rtcount--;
844 if (qrp->qr_tail == ulwp)
845 qrp->qr_tail = prev;
846 if (qrp == &ulwp->ul_queue_root) {
851 queue_root_t *qr_next = qrp->qr_next;
852 queue_root_t *qr_prev = qrp->qr_prev;
854 if (qrp->qr_tail) {
856 ASSERT(qrp->qr_qlen != 0);
857 nqrp = &qrp->qr_tail->ul_queue_root;
858 *nqrp = *qrp;
868 ASSERT(qrp->qr_qlen == 0);
916 queue_root_t *qrp;
925 if ((qrp = qp->qh_root) != NULL) {
926 for (prev = NULL, ulwpp = &qrp->qr_head;
943 return ((qrp = qp->qh_root) != NULL && qrp->qr_head != NULL);
1642 queue_root_t *qrp;
1667 if ((qrp = qp->qh_root) == NULL ||
1668 (ulwp = qrp->qr_head) == NULL)
1671 queue_unlink(qp, &qrp->qr_head, NULL);
3833 queue_root_t *qrp;
3874 if ((qrp = qp->qh_root) == NULL ||
3875 (ulwp = qrp->qr_head) == NULL)
3878 queue_unlink(qp, &qrp->qr_head, NULL);