Lines Matching refs:pending
132 spin_lock(&rtl->pending.lock); in ssh_rtl_pending_remove()
135 spin_unlock(&rtl->pending.lock); in ssh_rtl_pending_remove()
139 atomic_dec(&rtl->pending.count); in ssh_rtl_pending_remove()
142 spin_unlock(&rtl->pending.lock); in ssh_rtl_pending_remove()
151 spin_lock(&rtl->pending.lock); in ssh_rtl_tx_pending_push()
154 spin_unlock(&rtl->pending.lock); in ssh_rtl_tx_pending_push()
159 spin_unlock(&rtl->pending.lock); in ssh_rtl_tx_pending_push()
163 atomic_inc(&rtl->pending.count); in ssh_rtl_tx_pending_push()
164 list_add_tail(&ssh_request_get(rqst)->node, &rtl->pending.head); in ssh_rtl_tx_pending_push()
166 spin_unlock(&rtl->pending.lock); in ssh_rtl_tx_pending_push()
202 return !atomic_read(&rtl->pending.count); in ssh_rtl_tx_can_process()
204 return atomic_read(&rtl->pending.count) < SSH_RTL_MAX_PENDING; in ssh_rtl_tx_can_process()
307 if (atomic_read(&rtl->pending.count) >= SSH_RTL_MAX_PENDING) in ssh_rtl_tx_schedule()
481 spin_lock(&rtl->pending.lock); in ssh_rtl_complete()
482 list_for_each_entry_safe(p, n, &rtl->pending.head, node) { in ssh_rtl_complete()
489 spin_unlock(&rtl->pending.lock); in ssh_rtl_complete()
507 atomic_dec(&rtl->pending.count); in ssh_rtl_complete()
513 spin_unlock(&rtl->pending.lock); in ssh_rtl_complete()
728 bool ssh_rtl_cancel(struct ssh_request *rqst, bool pending) in ssh_rtl_cancel() argument
738 if (pending) in ssh_rtl_cancel()
829 trace_ssam_rtl_timeout_reap(atomic_read(&rtl->pending.count)); in ssh_rtl_timeout_reap()
839 spin_lock(&rtl->pending.lock); in ssh_rtl_timeout_reap()
840 list_for_each_entry_safe(r, n, &rtl->pending.head, node) { in ssh_rtl_timeout_reap()
865 atomic_dec(&rtl->pending.count); in ssh_rtl_timeout_reap()
868 spin_unlock(&rtl->pending.lock); in ssh_rtl_timeout_reap()
1040 spin_lock_init(&rtl->pending.lock); in ssh_rtl_init()
1041 INIT_LIST_HEAD(&rtl->pending.head); in ssh_rtl_init()
1042 atomic_set_release(&rtl->pending.count, 0); in ssh_rtl_init()
1201 int pending; in ssh_rtl_shutdown() local
1244 pending = atomic_read(&rtl->pending.count); in ssh_rtl_shutdown()
1245 if (WARN_ON(pending)) { in ssh_rtl_shutdown()
1246 spin_lock(&rtl->pending.lock); in ssh_rtl_shutdown()
1247 list_for_each_entry_safe(r, n, &rtl->pending.head, node) { in ssh_rtl_shutdown()
1255 spin_unlock(&rtl->pending.lock); in ssh_rtl_shutdown()