Show the syscall name in "resuming interrupted call" message

When signal is received, or if we have attached to a process,
current syscall (if process is in one) gets restarted.

Some syscalls are restarted via "restart_syscall()" mechanism.
On such sycalls, we don't show _which_ syscall gets restarted.

IOW: users want to see "resuming interrupted nanosleep"
instead of "resuming interrupted call" when they attach to "sleep 999".

Kernel does expose this information. The only thing we need is
to fetch syscall# on attach, and save it.

This patch does this. It adds tcp->s_prev_ent, which is
a pointer to struct_sysent of the previous syscall of this tracee.
It can be NULL.

sys_restart_syscall() is made to use it when the message is generated.

To similarly handle restart_syscall() *after signals*, not just
on attach, on each syscall exit patch saves exited syscall's data
in the same member (tcp->s_prev_ent).

Example:

    $ sleep 3 & strace -p $!
    Process 8728 attached
    restart_syscall(<... resuming interrupted nanosleep ...>) = 0
    _exit(0)                                = ?
    +++ exited with 0 +++

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
diff --git a/signal.c b/signal.c
index 867e156..5ffd0d0 100644
--- a/signal.c
+++ b/signal.c
@@ -1056,8 +1056,13 @@
 int
 sys_restart_syscall(struct tcb *tcp)
 {
-	if (entering(tcp))
-		tprints("<... resuming interrupted call ...>");
+	if (entering(tcp)) {
+		tprintf("<... resuming interrupted %s ...>",
+			tcp->s_prev_ent
+			? tcp->s_prev_ent->sys_name
+			: "system call"
+		);
+	}
 	return 0;
 }