[PATCH 5.10.y] kprobes: Fix possible use-after-free issue on kprobe registration