• Home
  • Raw
  • Download

Lines Matching refs:mbox_cmsg

118 	return skb_queue_is_first(&nn->mbox_cmsg.queue, skb);  in nfp_ccm_mbox_is_first()
133 skb = skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_mark_next_runner()
140 queue_work(nn->mbox_cmsg.workq, &nn->mbox_cmsg.runq_work); in nfp_ccm_mbox_mark_next_runner()
159 skb = __skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_copy_in()
192 skb = skb_queue_next(&nn->mbox_cmsg.queue, skb); in nfp_ccm_mbox_copy_in()
203 skb = __skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_find_req()
210 skb = skb_queue_next(&nn->mbox_cmsg.queue, skb); in nfp_ccm_mbox_find_req()
330 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_copy_out()
332 skb = __skb_dequeue(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_copy_out()
351 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_copy_out()
360 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_mark_all_err()
362 skb = __skb_dequeue(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_mark_all_err()
371 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_mark_all_err()
375 __releases(&nn->mbox_cmsg.queue.lock) in nfp_ccm_mbox_run_queue_unlock()
385 last = skb = __skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_run_queue_unlock()
388 while (!skb_queue_is_last(&nn->mbox_cmsg.queue, last)) { in nfp_ccm_mbox_run_queue_unlock()
389 skb = skb_queue_next(&nn->mbox_cmsg.queue, last); in nfp_ccm_mbox_run_queue_unlock()
399 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_run_queue_unlock()
417 wake_up_all(&nn->mbox_cmsg.wq); in nfp_ccm_mbox_run_queue_unlock()
436 __releases(&nn->mbox_cmsg.queue.lock) in nfp_ccm_mbox_unlink_unlock()
441 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_unlink_unlock()
443 wait_event(nn->mbox_cmsg.wq, nfp_ccm_mbox_done(skb)); in nfp_ccm_mbox_unlink_unlock()
449 __skb_unlink(skb, &nn->mbox_cmsg.queue); in nfp_ccm_mbox_unlink_unlock()
453 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_unlink_unlock()
456 wake_up_all(&nn->mbox_cmsg.wq); in nfp_ccm_mbox_unlink_unlock()
522 assert_spin_locked(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_msg_enqueue()
524 if (!critical && nn->mbox_cmsg.queue.qlen >= NFP_CCM_MAX_QLEN) { in nfp_ccm_mbox_msg_enqueue()
532 hdr->tag = cpu_to_be16(nn->mbox_cmsg.tag++); in nfp_ccm_mbox_msg_enqueue()
534 __skb_queue_tail(&nn->mbox_cmsg.queue, skb); in nfp_ccm_mbox_msg_enqueue()
551 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in __nfp_ccm_mbox_communicate()
561 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in __nfp_ccm_mbox_communicate()
563 to = !wait_event_timeout(nn->mbox_cmsg.wq, in __nfp_ccm_mbox_communicate()
574 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in __nfp_ccm_mbox_communicate()
591 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in __nfp_ccm_mbox_communicate()
611 nn = container_of(work, struct nfp_net, mbox_cmsg.runq_work); in nfp_ccm_mbox_post_runq_work()
613 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_post_runq_work()
615 skb = __skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_post_runq_work()
618 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_post_runq_work()
631 nn = container_of(work, struct nfp_net, mbox_cmsg.wait_work); in nfp_ccm_mbox_post_wait_work()
633 skb = skb_peek(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_post_wait_work()
645 wake_up_all(&nn->mbox_cmsg.wq); in nfp_ccm_mbox_post_wait_work()
660 spin_lock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_post()
671 queue_work(nn->mbox_cmsg.workq, in nfp_ccm_mbox_post()
672 &nn->mbox_cmsg.wait_work); in nfp_ccm_mbox_post()
678 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_post()
683 spin_unlock_bh(&nn->mbox_cmsg.queue.lock); in nfp_ccm_mbox_post()
723 drain_workqueue(nn->mbox_cmsg.workq); in nfp_ccm_mbox_clean()
728 skb_queue_head_init(&nn->mbox_cmsg.queue); in nfp_ccm_mbox_alloc()
729 init_waitqueue_head(&nn->mbox_cmsg.wq); in nfp_ccm_mbox_alloc()
730 INIT_WORK(&nn->mbox_cmsg.wait_work, nfp_ccm_mbox_post_wait_work); in nfp_ccm_mbox_alloc()
731 INIT_WORK(&nn->mbox_cmsg.runq_work, nfp_ccm_mbox_post_runq_work); in nfp_ccm_mbox_alloc()
733 nn->mbox_cmsg.workq = alloc_workqueue("nfp-ccm-mbox", WQ_UNBOUND, 0); in nfp_ccm_mbox_alloc()
734 if (!nn->mbox_cmsg.workq) in nfp_ccm_mbox_alloc()
741 destroy_workqueue(nn->mbox_cmsg.workq); in nfp_ccm_mbox_free()
742 WARN_ON(!skb_queue_empty(&nn->mbox_cmsg.queue)); in nfp_ccm_mbox_free()