]> granicus.if.org Git - strace/commitdiff
alpha: rename sys_sigprocmask to sys_osf_sigprocmask
authorDmitry V. Levin <ldv@altlinux.org>
Sun, 28 May 2017 00:09:32 +0000 (00:09 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Sun, 28 May 2017 00:09:32 +0000 (00:09 +0000)
Parsers of sigprocmask and osf_sigprocmask syscalls are different
anyway, so rename the function to match the syscall name.

* signal.c [ALPHA] (SYS_FUNC(sigprocmask)): Rename
to SYS_FUNC(osf_sigprocmask).
* linux/alpha/syscallent.h: Update sys_func.

linux/alpha/syscallent.h
signal.c

index 848c3230b6a9d21c80e3865553f4b5306af74fcb..ae7821f88ada5ab58c2f2a7452307844d2dbc13f 100644 (file)
@@ -75,7 +75,7 @@
 [ 45] = { 3,   TD|TF,          SEN(open),                      "open"                  },
 [ 46] = { 5,   0,              SEN(printargs),                 "osf_old_sigaction"     }, /* not implemented */
 [ 47] = { 0,   NF,             SEN(getxgid),                   "getxgid"               },
-[ 48] = { 2,   TS,             SEN(sigprocmask),               "osf_sigprocmask"       },
+[ 48] = { 2,   TS,             SEN(osf_sigprocmask),           "osf_sigprocmask"       },
 [ 49] = { 5,   0,              SEN(printargs),                 "osf_getlogin"          }, /* not implemented */
 [ 50] = { 5,   0,              SEN(printargs),                 "osf_setlogin"          }, /* not implemented */
 [ 51] = { 1,   TF,             SEN(acct),                      "acct"                  },
index f333397502f89a27ef11f87b2f98b1cdf4d08d83..c8b0a5f595649474aea2f4d981d0b320a50e16c6 100644 (file)
--- a/signal.c
+++ b/signal.c
@@ -415,22 +415,21 @@ SYS_FUNC(sigsuspend)
        return RVAL_DECODED;
 }
 
-/* "Old" sigprocmask, which operates with word-sized signal masks */
-SYS_FUNC(sigprocmask)
+#ifdef ALPHA
+/*
+ * The OSF/1 sigprocmask is different: it doesn't pass in two pointers,
+ * but rather passes in the new bitmask as an argument and then returns
+ * the old bitmask.  This "works" because we only have 64 signals to worry
+ * about.  If you want more, use of the rt_sigprocmask syscall is required.
+ *
+ * Alpha:
+ *     old = osf_sigprocmask(how, new);
+ * Everyone else:
+ *     ret = sigprocmask(how, &new, &old, ...);
+ */
+SYS_FUNC(osf_sigprocmask)
 {
-# ifdef ALPHA
        if (entering(tcp)) {
-               /*
-                * Alpha/OSF is different: it doesn't pass in two pointers,
-                * but rather passes in the new bitmask as an argument and
-                * then returns the old bitmask.  This "works" because we
-                * only have 64 signals to worry about.  If you want more,
-                * use of the rt_sigprocmask syscall is required.
-                * Alpha:
-                *      old = osf_sigprocmask(how, new);
-                * Everyone else:
-                *      ret = sigprocmask(how, &new, &old, ...);
-                */
                printxval(sigprocmaskcmds, tcp->u_arg[0], "SIG_???");
                tprintsigmask_val(", ", tcp->u_arg[1]);
        }
@@ -438,7 +437,14 @@ SYS_FUNC(sigprocmask)
                tcp->auxstr = sprintsigmask_val("old mask ", tcp->u_rval);
                return RVAL_HEX | RVAL_STR;
        }
-# else /* !ALPHA */
+       return 0;
+}
+
+#else /* !ALPHA */
+
+/* "Old" sigprocmask, which operates with word-sized signal masks */
+SYS_FUNC(sigprocmask)
+{
        if (entering(tcp)) {
                printxval(sigprocmaskcmds, tcp->u_arg[0], "SIG_???");
                tprints(", ");
@@ -448,9 +454,9 @@ SYS_FUNC(sigprocmask)
        else {
                print_sigset_addr_len(tcp, tcp->u_arg[2], current_wordsize);
        }
-# endif /* !ALPHA */
        return 0;
 }
+#endif /* !ALPHA */
 
 SYS_FUNC(kill)
 {