• Home
  • Raw
  • Download

Lines Matching full:strong

283  * @internal_strong_refs: used to take strong references when
290 * @local_strong_refs: strong user refs from local process
303 * @has_strong_ref: userspace notified of strong ref
306 * @pending_strong_ref: userspace has acked notification of strong ref
380 * @strong: strong ref count (debugging only if not locked)
391 int strong; member
1226 static int binder_inc_node_nilocked(struct binder_node *node, int strong, in binder_inc_node_nilocked() argument
1235 if (strong) { in binder_inc_node_nilocked()
1242 pr_err("invalid inc strong node for %d\n", in binder_inc_node_nilocked()
1275 static int binder_inc_node(struct binder_node *node, int strong, int internal, in binder_inc_node() argument
1281 ret = binder_inc_node_nilocked(node, strong, internal, target_list); in binder_inc_node()
1288 int strong, int internal) in binder_dec_node_nilocked() argument
1295 if (strong) { in binder_dec_node_nilocked()
1347 static void binder_dec_node(struct binder_node *node, int strong, int internal) in binder_dec_node() argument
1352 free_node = binder_dec_node_nilocked(node, strong, internal); in binder_dec_node()
1419 * and cleanup is needed. Calling with strong=0 and internal=1 in binder_dec_node_tmpref()
1447 } else if (need_strong_ref && !ref->data.strong) { in binder_get_ref_olocked()
1448 binder_user_error("tried to use weak ref as strong ref\n"); in binder_get_ref_olocked()
1554 if (ref->data.strong) in binder_cleanup_ref_olocked()
1586 * @strong: if true, strong increment, else weak
1593 static int binder_inc_ref_olocked(struct binder_ref *ref, int strong, in binder_inc_ref_olocked() argument
1598 if (strong) { in binder_inc_ref_olocked()
1599 if (ref->data.strong == 0) { in binder_inc_ref_olocked()
1604 ref->data.strong++; in binder_inc_ref_olocked()
1619 * @strong: if true, strong decrement, else weak
1625 static bool binder_dec_ref_olocked(struct binder_ref *ref, int strong) in binder_dec_ref_olocked() argument
1627 if (strong) { in binder_dec_ref_olocked()
1628 if (ref->data.strong == 0) { in binder_dec_ref_olocked()
1629 binder_user_error("%d invalid dec strong, ref %d desc %d s %d w %d\n", in binder_dec_ref_olocked()
1631 ref->data.desc, ref->data.strong, in binder_dec_ref_olocked()
1635 ref->data.strong--; in binder_dec_ref_olocked()
1636 if (ref->data.strong == 0) in binder_dec_ref_olocked()
1637 binder_dec_node(ref->node, strong, 1); in binder_dec_ref_olocked()
1642 ref->data.desc, ref->data.strong, in binder_dec_ref_olocked()
1648 if (ref->data.strong == 0 && ref->data.weak == 0) { in binder_dec_ref_olocked()
1659 * @need_strong_ref: if true, only return node if ref is strong
1664 * Return: a binder_node or NULL if not found or not strong when strong required
1715 * @strong: true=strong reference, false=weak reference
1724 uint32_t desc, bool increment, bool strong, in binder_update_ref_for_handle() argument
1732 ref = binder_get_ref_olocked(proc, desc, strong); in binder_update_ref_for_handle()
1738 ret = binder_inc_ref_olocked(ref, strong, NULL); in binder_update_ref_for_handle()
1740 delete_ref = binder_dec_ref_olocked(ref, strong); in binder_update_ref_for_handle()
1759 * @strong: true=strong reference, false=weak reference
1767 uint32_t desc, bool strong, struct binder_ref_data *rdata) in binder_dec_ref_for_handle() argument
1769 return binder_update_ref_for_handle(proc, desc, false, strong, rdata); in binder_dec_ref_for_handle()
1777 * @strong: true=strong reference, false=weak reference
1788 bool strong, in binder_inc_ref_for_node() argument
1806 ret = binder_inc_ref_olocked(ref, strong, target_list); in binder_inc_ref_for_node()
1813 * with strong=0 and a tmp_refs will not decrement in binder_inc_ref_for_node()
3143 * since it has a reference to the target. The local strong ref keeps it
3146 * counting bug, relying on the local strong ref can fail.
3148 * Since user-space can cause the local strong ref to go away, we also take
3284 * There must already be a strong ref in binder_transaction()
3285 * on this node. If so, do a strong in binder_transaction()
4063 bool strong = cmd == BC_ACQUIRE || cmd == BC_RELEASE; in binder_thread_write() local
4085 strong, NULL, &rdata); in binder_thread_write()
4091 proc, target, increment, strong, in binder_thread_write()
4116 strong, target, ret); in binder_thread_write()
4122 rdata.debug_id, rdata.desc, rdata.strong, in binder_thread_write()
4349 ref->data.desc, ref->data.strong, in binder_thread_write()
4737 int strong, weak; in binder_thread_read() local
4746 strong = node->internal_strong_refs || in binder_thread_read()
4750 node->tmp_refs || strong; in binder_thread_read()
4759 if (strong && !has_strong_ref) { in binder_thread_read()
4764 if (!strong && has_strong_ref) in binder_thread_read()
4768 if (!weak && !strong) { in binder_thread_read()
4797 if (!ret && strong && !has_strong_ref) in binder_thread_read()
4802 if (!ret && !strong && has_strong_ref) in binder_thread_read()
6229 ref->node->debug_id, ref->data.strong, in print_binder_ref_olocked()
6403 int count, strong, weak, ready_threads; in print_binder_proc_stats() local
6431 strong = 0; in print_binder_proc_stats()
6438 strong += ref->data.strong; in print_binder_proc_stats()
6442 seq_printf(m, " refs: %d s %d w %d\n", count, strong, weak); in print_binder_proc_stats()