# Re: \[PATCH v3\] PowerPC: Replace kretprobe with rethook

- From: Masami Hiramatsu (Google) \<mhiramat@kernel.org\>
- Date: 2024-07-01 23:53:53 
- List: linuxppc-dev
- Page: https://ratatoskr.run/linuxppc-dev/2024/07/9534339
- Thread: https://ratatoskr.run/linuxppc-dev/2024/06/9534318/t.md

```text
On Thu, 27 Jun 2024 09:21:01 -0400
Abhishek Dubey [ref] wrote:

> +/* rethook initializer */
> +int __init arch_init_kprobes(void)
> +{
> +	return register_kprobe(&trampoline_p);
> +}

No, please don't use arch_init_kprobes() for initializing rethook, since
rethook is used from fprobe too (at this moment).

If you want to make it relays on kprobes, you have to make a dependency
in powerpc's kconfig, e.g.

select HAVE_RETHOOK if KPROBES

But I don't recommend it.

Thank you,

-- 
Masami Hiramatsu (Google) [ref]
```
