do_wait-wakeup-optimization: simplify task_pid_type()