Lines Matching refs:pq
1425 struct xfrm_policy_queue *pq = &old->polq; in xfrm_policy_requeue() local
1428 if (skb_queue_empty(&pq->hold_queue)) in xfrm_policy_requeue()
1433 spin_lock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
1434 skb_queue_splice_init(&pq->hold_queue, &list); in xfrm_policy_requeue()
1435 if (del_timer(&pq->hold_timer)) in xfrm_policy_requeue()
1437 spin_unlock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
1439 pq = &new->polq; in xfrm_policy_requeue()
1441 spin_lock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
1442 skb_queue_splice(&list, &pq->hold_queue); in xfrm_policy_requeue()
1443 pq->timeout = XFRM_QUEUE_TMO_MIN; in xfrm_policy_requeue()
1444 if (!mod_timer(&pq->hold_timer, jiffies)) in xfrm_policy_requeue()
1446 spin_unlock_bh(&pq->hold_queue.lock); in xfrm_policy_requeue()
2844 struct xfrm_policy_queue *pq = &pol->polq; in xfrm_policy_queue_process() local
2849 spin_lock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
2850 skb = skb_peek(&pq->hold_queue); in xfrm_policy_queue_process()
2852 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
2863 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
2873 if (pq->timeout >= XFRM_QUEUE_TMO_MAX) in xfrm_policy_queue_process()
2876 pq->timeout = pq->timeout << 1; in xfrm_policy_queue_process()
2877 if (!mod_timer(&pq->hold_timer, jiffies + pq->timeout)) in xfrm_policy_queue_process()
2886 spin_lock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
2887 pq->timeout = 0; in xfrm_policy_queue_process()
2888 skb_queue_splice_init(&pq->hold_queue, &list); in xfrm_policy_queue_process()
2889 spin_unlock(&pq->hold_queue.lock); in xfrm_policy_queue_process()
2919 pq->timeout = 0; in xfrm_policy_queue_process()
2920 skb_queue_purge(&pq->hold_queue); in xfrm_policy_queue_process()
2930 struct xfrm_policy_queue *pq = &pol->polq; in xdst_queue_output() local
2937 if (pq->hold_queue.qlen > XFRM_MAX_QUEUE_LEN) { in xdst_queue_output()
2944 spin_lock_bh(&pq->hold_queue.lock); in xdst_queue_output()
2946 if (!pq->timeout) in xdst_queue_output()
2947 pq->timeout = XFRM_QUEUE_TMO_MIN; in xdst_queue_output()
2949 sched_next = jiffies + pq->timeout; in xdst_queue_output()
2951 if (del_timer(&pq->hold_timer)) { in xdst_queue_output()
2952 if (time_before(pq->hold_timer.expires, sched_next)) in xdst_queue_output()
2953 sched_next = pq->hold_timer.expires; in xdst_queue_output()
2957 __skb_queue_tail(&pq->hold_queue, skb); in xdst_queue_output()
2958 if (!mod_timer(&pq->hold_timer, sched_next)) in xdst_queue_output()
2961 spin_unlock_bh(&pq->hold_queue.lock); in xdst_queue_output()