ptrace: introduce signal_wake_up_state() and ptrace_signal_wake_up()