Lines Matching refs:pq
708 struct xfrm_policy_queue *pq = &old->polq; in xfrm_policy_requeue() local
713 spin_lock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
714 skb_queue_splice_init(&pq->hold_queue, &list); in xfrm_policy_requeue()
715 if (del_timer(&pq->hold_timer)) in xfrm_policy_requeue()
717 spin_unlock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
722 pq = &new->polq; in xfrm_policy_requeue()
724 spin_lock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
725 skb_queue_splice(&list, &pq->hold_queue); in xfrm_policy_requeue()
726 pq->timeout = XFRM_QUEUE_TMO_MIN; in xfrm_policy_requeue()
727 if (!mod_timer(&pq->hold_timer, jiffies)) in xfrm_policy_requeue()
729 spin_unlock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
1891 struct xfrm_policy_queue *pq = &pol->polq; in xfrm_policy_queue_process() local
1895 spin_lock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
1896 skb = skb_peek(&pq->hold_queue); in xfrm_policy_queue_process()
1898 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
1904 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
1915 if (pq->timeout >= XFRM_QUEUE_TMO_MAX) in xfrm_policy_queue_process()
1918 pq->timeout = pq->timeout << 1; in xfrm_policy_queue_process()
1919 if (!mod_timer(&pq->hold_timer, jiffies + pq->timeout)) in xfrm_policy_queue_process()
1928 spin_lock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
1929 pq->timeout = 0; in xfrm_policy_queue_process()
1930 skb_queue_splice_init(&pq->hold_queue, &list); in xfrm_policy_queue_process()
1931 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
1957 pq->timeout = 0; in xfrm_policy_queue_process()
1958 xfrm_queue_purge(&pq->hold_queue); in xfrm_policy_queue_process()
1968 struct xfrm_policy_queue *pq = &pol->polq; in xdst_queue_output() local
1975 if (pq->hold_queue.qlen > XFRM_MAX_QUEUE_LEN) { in xdst_queue_output()
1982 spin_lock_bh(&pq->hold_queue.lock); in xdst_queue_output()
1984 if (!pq->timeout) in xdst_queue_output()
1985 pq->timeout = XFRM_QUEUE_TMO_MIN; in xdst_queue_output()
1987 sched_next = jiffies + pq->timeout; in xdst_queue_output()
1989 if (del_timer(&pq->hold_timer)) { in xdst_queue_output()
1990 if (time_before(pq->hold_timer.expires, sched_next)) in xdst_queue_output()
1991 sched_next = pq->hold_timer.expires; in xdst_queue_output()
1995 __skb_queue_tail(&pq->hold_queue, skb); in xdst_queue_output()
1996 if (!mod_timer(&pq->hold_timer, sched_next)) in xdst_queue_output()
1999 spin_unlock_bh(&pq->hold_queue.lock); in xdst_queue_output()