• Home
  • Raw
  • Download

Lines Matching refs:ret

118 	bool ret;  in trace_kprobe_module_exist()  local
127 ret = !!find_module(tk->symbol); in trace_kprobe_module_exist()
131 return ret; in trace_kprobe_module_exist()
265 int ret = -ENOMEM; in alloc_trace_kprobe() local
269 return ERR_PTR(ret); in alloc_trace_kprobe()
293 ret = trace_probe_init(&tk->tp, event, group, 0); in alloc_trace_kprobe()
294 if (ret < 0) in alloc_trace_kprobe()
301 return ERR_PTR(ret); in alloc_trace_kprobe()
319 int ret = 0; in __enable_trace_kprobe() local
323 ret = enable_kretprobe(&tk->rp); in __enable_trace_kprobe()
325 ret = enable_kprobe(&tk->rp.kp); in __enable_trace_kprobe()
328 return ret; in __enable_trace_kprobe()
357 int ret = 0; in enable_trace_kprobe() local
366 ret = trace_probe_add_file(tp, file); in enable_trace_kprobe()
367 if (ret) in enable_trace_kprobe()
368 return ret; in enable_trace_kprobe()
379 ret = __enable_trace_kprobe(tk); in enable_trace_kprobe()
380 if (ret) in enable_trace_kprobe()
385 if (ret) { in enable_trace_kprobe()
395 return ret; in enable_trace_kprobe()
483 int i, ret; in __register_trace_kprobe() local
485 ret = security_locked_down(LOCKDOWN_KPROBES); in __register_trace_kprobe()
486 if (ret) in __register_trace_kprobe()
487 return ret; in __register_trace_kprobe()
499 ret = traceprobe_update_arg(&tk->tp.args[i]); in __register_trace_kprobe()
500 if (ret) in __register_trace_kprobe()
501 return ret; in __register_trace_kprobe()
511 ret = register_kretprobe(&tk->rp); in __register_trace_kprobe()
513 ret = register_kprobe(&tk->rp.kp); in __register_trace_kprobe()
515 return ret; in __register_trace_kprobe()
590 int ret; in append_trace_kprobe() local
592 ret = trace_probe_compare_arg_type(&tk->tp, &to->tp); in append_trace_kprobe()
593 if (ret) { in append_trace_kprobe()
595 trace_probe_log_set_index(ret + 1); in append_trace_kprobe()
606 ret = trace_probe_append(&tk->tp, &to->tp); in append_trace_kprobe()
607 if (ret) in append_trace_kprobe()
608 return ret; in append_trace_kprobe()
611 ret = __register_trace_kprobe(tk); in append_trace_kprobe()
612 if (ret == -ENOENT && !trace_kprobe_module_exist(tk)) { in append_trace_kprobe()
614 ret = 0; in append_trace_kprobe()
617 if (ret) in append_trace_kprobe()
622 return ret; in append_trace_kprobe()
629 int ret; in register_trace_kprobe() local
639 ret = -EEXIST; in register_trace_kprobe()
641 ret = append_trace_kprobe(tk, old_tk); in register_trace_kprobe()
647 ret = register_kprobe_event(tk); in register_trace_kprobe()
648 if (ret) { in register_trace_kprobe()
649 pr_warn("Failed to register probe event(%d)\n", ret); in register_trace_kprobe()
654 ret = __register_trace_kprobe(tk); in register_trace_kprobe()
655 if (ret == -ENOENT && !trace_kprobe_module_exist(tk)) { in register_trace_kprobe()
657 ret = 0; in register_trace_kprobe()
660 if (ret < 0) in register_trace_kprobe()
667 return ret; in register_trace_kprobe()
677 int ret; in trace_kprobe_module_callback() local
688 ret = __register_trace_kprobe(tk); in trace_kprobe_module_callback()
689 if (ret) in trace_kprobe_module_callback()
692 mod->name, ret); in trace_kprobe_module_callback()
737 int i, len, ret = 0; in trace_kprobe_create() local
781 ret = kstrtouint(buf, 0, &maxactive); in trace_kprobe_create()
782 if (ret || !maxactive) { in trace_kprobe_create()
801 ret = -ECANCELED; in trace_kprobe_create()
809 ret = traceprobe_split_symbol_offset(symbol, &offset); in trace_kprobe_create()
810 if (ret || offset < 0 || offset > UINT_MAX) { in trace_kprobe_create()
824 ret = traceprobe_parse_event_name(&event, &group, buf, in trace_kprobe_create()
826 if (ret) in trace_kprobe_create()
844 ret = PTR_ERR(tk); in trace_kprobe_create()
846 WARN_ON_ONCE(ret != -ENOMEM); in trace_kprobe_create()
855 ret = -ENOMEM; in trace_kprobe_create()
860 ret = traceprobe_parse_probe_arg(&tk->tp, i, tmp, flags); in trace_kprobe_create()
862 if (ret) in trace_kprobe_create()
866 ret = traceprobe_set_print_fmt(&tk->tp, is_return); in trace_kprobe_create()
867 if (ret < 0) in trace_kprobe_create()
870 ret = register_trace_kprobe(tk); in trace_kprobe_create()
871 if (ret) { in trace_kprobe_create()
873 if (ret == -EILSEQ) in trace_kprobe_create()
875 else if (ret == -ENOENT) in trace_kprobe_create()
877 else if (ret != -ENOMEM && ret != -EEXIST) in trace_kprobe_create()
885 return ret; in trace_kprobe_create()
888 ret = -EINVAL; in trace_kprobe_create()
896 int ret; in create_or_delete_trace_kprobe() local
901 ret = trace_kprobe_create(argc, (const char **)argv); in create_or_delete_trace_kprobe()
902 return ret == -ECANCELED ? -EINVAL : ret; in create_or_delete_trace_kprobe()
908 int ret = unregister_trace_kprobe(tk); in trace_kprobe_release() local
910 if (!ret) in trace_kprobe_release()
912 return ret; in trace_kprobe_release()
958 int ret; in probes_open() local
960 ret = security_locked_down(LOCKDOWN_TRACEFS); in probes_open()
961 if (ret) in probes_open()
962 return ret; in probes_open()
965 ret = dyn_events_release_all(&trace_kprobe_ops); in probes_open()
966 if (ret < 0) in probes_open()
967 return ret; in probes_open()
1016 int ret; in profile_open() local
1018 ret = security_locked_down(LOCKDOWN_TRACEFS); in profile_open()
1019 if (ret) in profile_open()
1020 return ret; in profile_open()
1039 int ret, len = 0; in fetch_store_strlen() local
1043 ret = probe_kernel_read(&c, (u8 *)addr + len, 1); in fetch_store_strlen()
1045 } while (c && ret == 0 && len < MAX_STRING_SIZE); in fetch_store_strlen()
1047 return (ret < 0) ? ret : len; in fetch_store_strlen()
1068 long ret; in fetch_store_string() local
1079 ret = strncpy_from_unsafe(__dest, (void *)addr, maxlen); in fetch_store_string()
1080 if (ret >= 0) in fetch_store_string()
1081 *(u32 *)dest = make_data_loc(ret, __dest - base); in fetch_store_string()
1083 return ret; in fetch_store_string()
1096 long ret; in fetch_store_string_user() local
1103 ret = strncpy_from_unsafe_user(__dest, uaddr, maxlen); in fetch_store_string_user()
1104 if (ret >= 0) in fetch_store_string_user()
1105 *(u32 *)dest = make_data_loc(ret, __dest - base); in fetch_store_string_user()
1107 return ret; in fetch_store_string_user()
1339 int ret; in kprobe_event_define_fields() local
1354 int ret; in kretprobe_event_define_fields() local
1382 int ret; in kprobe_perf_func() local
1384 ret = trace_call_bpf(call, regs); in kprobe_perf_func()
1393 if (!ret) in kprobe_perf_func()
1519 int ret = 0; in kprobe_dispatcher() local
1527 ret = kprobe_perf_func(tk, regs); in kprobe_dispatcher()
1529 return ret; in kprobe_dispatcher()
1593 int ret; in create_local_trace_kprobe() local
1616 ret = -ENOMEM; in create_local_trace_kprobe()
1620 ret = __register_trace_kprobe(tk); in create_local_trace_kprobe()
1621 if (ret < 0) in create_local_trace_kprobe()
1627 return ERR_PTR(ret); in create_local_trace_kprobe()
1668 int ret; in setup_boot_kprobe_events() local
1677 ret = trace_run_command(cmd, create_or_delete_trace_kprobe); in setup_boot_kprobe_events()
1678 if (ret) in setup_boot_kprobe_events()
1679 pr_warn("Failed to add event(%d): %s\n", ret, cmd); in setup_boot_kprobe_events()
1694 int ret; in init_kprobe_trace() local
1696 ret = dyn_event_register(&trace_kprobe_ops); in init_kprobe_trace()
1697 if (ret) in init_kprobe_trace()
1698 return ret; in init_kprobe_trace()
1747 int ret, warn = 0; in kprobe_trace_self_tests_init() local
1764 ret = trace_run_command("p:testprobe kprobe_trace_selftest_target $stack $stack0 +0($stack)", in kprobe_trace_self_tests_init()
1766 if (WARN_ON_ONCE(ret)) { in kprobe_trace_self_tests_init()
1786 ret = trace_run_command("r:testprobe2 kprobe_trace_selftest_target $retval", in kprobe_trace_self_tests_init()
1788 if (WARN_ON_ONCE(ret)) { in kprobe_trace_self_tests_init()
1811 ret = target(1, 2, 3, 4, 5, 6); in kprobe_trace_self_tests_init()
1818 if (ret != 21) in kprobe_trace_self_tests_init()
1860 ret = trace_run_command("-:testprobe", create_or_delete_trace_kprobe); in kprobe_trace_self_tests_init()
1861 if (WARN_ON_ONCE(ret)) { in kprobe_trace_self_tests_init()
1866 ret = trace_run_command("-:testprobe2", create_or_delete_trace_kprobe); in kprobe_trace_self_tests_init()
1867 if (WARN_ON_ONCE(ret)) { in kprobe_trace_self_tests_init()
1873 ret = dyn_events_release_all(&trace_kprobe_ops); in kprobe_trace_self_tests_init()
1874 if (WARN_ON_ONCE(ret)) { in kprobe_trace_self_tests_init()