Lines Matching refs:rma_info
109 mutex_lock(&ep->rma_info.rma_lock); in scif_reserve_dma_chan()
110 ep->rma_info.dma_chan = chan; in scif_reserve_dma_chan()
111 mutex_unlock(&ep->rma_info.rma_lock); in scif_reserve_dma_chan()
153 spin_lock(&ep->rma_info.tc_lock); in scif_rma_destroy_tcw()
155 spin_unlock(&ep->rma_info.tc_lock); in scif_rma_destroy_tcw()
163 list_for_each_safe(item, tmp, &ep->rma_info.mmn_list) { in scif_rma_destroy_tcw_ep()
174 spin_lock(&ep->rma_info.tc_lock); in __scif_rma_destroy_tcw_ep()
175 list_for_each_safe(item, tmp, &ep->rma_info.mmn_list) { in __scif_rma_destroy_tcw_ep()
179 spin_unlock(&ep->rma_info.tc_lock); in __scif_rma_destroy_tcw_ep()
186 if ((atomic_read(&ep->rma_info.tcw_total_pages) in scif_rma_tc_can_cache()
192 atomic_read(&ep->rma_info.tcw_total_pages), in scif_rma_tc_can_cache()
251 struct scif_endpt_rma_info *rma = &ep->rma_info; in scif_ep_unregister_mmu_notifier()
255 mutex_lock(&ep->rma_info.mmn_lock); in scif_ep_unregister_mmu_notifier()
262 mutex_unlock(&ep->rma_info.mmn_lock); in scif_ep_unregister_mmu_notifier()
304 list_add(&mmn->list, &ep->rma_info.mmn_list); in scif_add_mmu_notifier()
614 chan = ep->rma_info.dma_chan; in scif_rma_destroy_windows()
620 ep->rma_info.dma_chan)) in scif_rma_destroy_windows()
631 atomic_dec(&ep->rma_info.tw_refcount); in scif_rma_destroy_windows()
657 chan = ep->rma_info.dma_chan; in scif_rma_destroy_tcw_invalid()
660 mutex_lock(&ep->rma_info.rma_lock); in scif_rma_destroy_tcw_invalid()
663 ep->rma_info.dma_chan)) { in scif_rma_destroy_tcw_invalid()
665 &ep->rma_info.tcw_total_pages); in scif_rma_destroy_tcw_invalid()
667 atomic_dec(&ep->rma_info.tcw_refcount); in scif_rma_destroy_tcw_invalid()
672 mutex_unlock(&ep->rma_info.rma_lock); in scif_rma_destroy_tcw_invalid()
1721 remote_req.head = &ep->rma_info.remote_reg_list; in scif_rma_copy()
1730 mutex_lock(&ep->rma_info.mmn_lock); in scif_rma_copy()
1731 mmn = scif_find_mmu_notifier(current->mm, &ep->rma_info); in scif_rma_copy()
1734 mutex_unlock(&ep->rma_info.mmn_lock); in scif_rma_copy()
1741 mutex_lock(&ep->rma_info.rma_lock); in scif_rma_copy()
1751 spin_lock(&ep->rma_info.tc_lock); in scif_rma_copy()
1754 spin_unlock(&ep->rma_info.tc_lock); in scif_rma_copy()
1761 mutex_unlock(&ep->rma_info.rma_lock); in scif_rma_copy()
1766 atomic_inc(&ep->rma_info.tcw_refcount); in scif_rma_copy()
1768 &ep->rma_info.tcw_total_pages); in scif_rma_copy()
1770 spin_lock(&ep->rma_info.tc_lock); in scif_rma_copy()
1773 spin_unlock(&ep->rma_info.tc_lock); in scif_rma_copy()
1789 req.head = &ep->rma_info.reg_list; in scif_rma_copy()
1793 mutex_unlock(&ep->rma_info.rma_lock); in scif_rma_copy()
1801 mutex_unlock(&ep->rma_info.rma_lock); in scif_rma_copy()
1827 chan = ep->rma_info.dma_chan; in scif_rma_copy()
1832 atomic_inc(&ep->rma_info.tw_refcount); in scif_rma_copy()
1834 mutex_unlock(&ep->rma_info.rma_lock); in scif_rma_copy()
1841 ep->rma_info.dma_chan); in scif_rma_copy()
1844 ep->rma_info.dma_chan); in scif_rma_copy()