]> granicus.if.org Git - strace/commitdiff
Implement and use new parsers of semtimedop syscall
authorDmitry V. Levin <ldv@altlinux.org>
Sun, 12 May 2019 22:45:45 +0000 (22:45 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Sun, 12 May 2019 22:45:45 +0000 (22:45 +0000)
* ipc_sem.c (SYS_FUNC(semtimedop)): Remove.
[HAVE_ARCH_TIME32_SYSCALLS] (SYS_FUNC(semtimedop_time32)): New function.
* linux/subcall32.h (sys_semtimedop): Redirect to sys_semtimedop_time32.
* linux/subcall64.h (sys_semtimedop): Redirect to sys_semtimedop_time64.
* linux/64/syscallent.h: Replace SEN(semtimedop) with
SEN(semtimedop_time64).
* linux/alpha/syscallent.h: Likewise.
* linux/ia64/syscallent.h: Likewise.
* linux/mips/syscallent-n64.h: Likewise.
* linux/powerpc64/syscallent.h: Likewise.
* linux/s390x/syscallent.h: Likewise.
* linux/sparc64/syscallent.h: Likewise.
* linux/x32/syscallent.h: Likewise.
* linux/x86_64/syscallent.h: Likewise.
* linux/32/syscallent.h: Replace SEN(semtimedop) with
SEN(semtimedop_time32).
* linux/arm/syscallent.h: Likewise.
* linux/avr32/syscallent.h: Likewise.
* linux/bfin/syscallent.h: Likewise.
* linux/hppa/syscallent.h: Likewise.
* linux/microblaze/syscallent.h: Likewise.
* linux/mips/syscallent-n32.h: Likewise.
* linux/xtensa/syscallent.h: Likewise.

20 files changed:
ipc_sem.c
linux/32/syscallent.h
linux/64/syscallent.h
linux/alpha/syscallent.h
linux/arm/syscallent.h
linux/avr32/syscallent.h
linux/bfin/syscallent.h
linux/hppa/syscallent.h
linux/ia64/syscallent.h
linux/microblaze/syscallent.h
linux/mips/syscallent-n32.h
linux/mips/syscallent-n64.h
linux/powerpc64/syscallent.h
linux/s390x/syscallent.h
linux/sparc64/syscallent.h
linux/subcall32.h
linux/subcall64.h
linux/x32/syscallent.h
linux/x86_64/syscallent.h
linux/xtensa/syscallent.h

index 908a58c42b9415a231e9e8d5ea0a91d933c06bcb..5c8be6ae95c92e6c775d460ca3e8f18ee2076205 100644 (file)
--- a/ipc_sem.c
+++ b/ipc_sem.c
@@ -82,10 +82,12 @@ do_semtimedop(struct tcb *const tcp, const print_obj_by_addr_fn print_ts)
        return RVAL_DECODED;
 }
 
-SYS_FUNC(semtimedop)
+#if HAVE_ARCH_TIME32_SYSCALLS
+SYS_FUNC(semtimedop_time32)
 {
-       return do_semtimedop(tcp, print_timespec);
+       return do_semtimedop(tcp, print_timespec32);
 }
+#endif
 
 SYS_FUNC(semtimedop_time64)
 {
index 9ee228223b878438bf76b0c9590c049eda0dcd78..efd5b26457d6806080fa035bed66631c73981efd 100644 (file)
 [189] = { 4,   TI,             SEN(msgsnd),                    "msgsnd"                },
 [190] = { 3,   TI,             SEN(semget),                    "semget"                },
 [191] = { 4,   TI,             SEN(semctl),                    "semctl"                },
-[192] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[192] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [193] = { 3,   TI,             SEN(semop),                     "semop"                 },
 [194] = { 3,   TI,             SEN(shmget),                    "shmget"                },
 [195] = { 3,   TI,             SEN(shmctl),                    "shmctl"                },
index 6106a95b87180360c78b206fa87f1b92bf6106a1..4d2c3ee51e74adf0b036c8daa76f32e79a6d8648 100644 (file)
 [189] = { 4,   TI,             SEN(msgsnd),                    "msgsnd"                },
 [190] = { 3,   TI,             SEN(semget),                    "semget"                },
 [191] = { 4,   TI,             SEN(semctl),                    "semctl"                },
-[192] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[192] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [193] = { 3,   TI,             SEN(semop),                     "semop"                 },
 [194] = { 3,   TI,             SEN(shmget),                    "shmget"                },
 [195] = { 3,   TI,             SEN(shmctl),                    "shmctl"                },
index d001a97a3610021150327dc52e576d10e4ac0df7..9cfcc58899e4496ce6260575bba1433d60823353 100644 (file)
 [420] = { 2,   0,              SEN(clock_gettime),             "clock_gettime"         },
 [421] = { 2,   0,              SEN(clock_getres),              "clock_getres"          },
 [422] = { 4,   0,              SEN(clock_nanosleep),           "clock_nanosleep"       },
-[423] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[423] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [424] = { 3,   TS,             SEN(tgkill),                    "tgkill"                },
 [425] = { 2,   TF|TST|TSTA,    SEN(stat64),                    "stat64"                },
 [426] = { 2,   TF|TLST|TSTA,   SEN(lstat64),                   "lstat64"               },
index 7bc4ac58235da06c10c9702ece0a729a1fcd9e49..dadcccd3e3c2ef813abdf914c33d8bb02c3e396a 100644 (file)
 [309] = { 5,   0,              SEN(add_key),                   "add_key"               },
 [310] = { 4,   0,              SEN(request_key),               "request_key"           },
 [311] = { 5,   0,              SEN(keyctl),                    "keyctl"                },
-[312] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[312] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [313] = { 5,   0,              SEN(vserver),                   "vserver"               },
 [314] = { 3,   0,              SEN(ioprio_set),                "ioprio_set"            },
 [315] = { 2,   0,              SEN(ioprio_get),                "ioprio_get"            },
index 30082d69033a13cddb4c8cb4cc10958b2f36b231..d6cc1b0840e17c76e45f5b9dc8ba57ecd716d21c 100644 (file)
 [270] = { 3,   TI,             SEN(semget),                    "semget"                },
 [271] = { 3,   TI,             SEN(semop),                     "semop"                 },
 [272] = { 4,   TI,             SEN(semctl),                    "semctl"                },
-[273] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[273] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [274] = { 3,   TI|TM|SI,       SEN(shmat),                     "shmat"                 },
 [275] = { 3,   TI,             SEN(shmget),                    "shmget"                },
 [276] = { 1,   TI|TM|SI,       SEN(shmdt),                     "shmdt"                 },
index 21fe89bd2445a35c75b251403c087fad174ce8fa..e124fd3d3db8db2e4a54cdd753b71b4d9e867cb8 100644 (file)
 [354] = { 2,   0,              SEN(set_robust_list),           "set_robust_list"       },
 [355] = { 3,   0,              SEN(get_robust_list),           "get_robust_list"       },
 [356] = { 6,   TD,             SEN(fallocate),                 "fallocate"             },
-[357] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[357] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [358] = { 4,   TD,             SEN(timerfd_settime),           "timerfd_settime"       },
 [359] = { 2,   TD,             SEN(timerfd_gettime),           "timerfd_gettime"       },
 [360] = { 4,   TD|TS,          SEN(signalfd4),                 "signalfd4"             },
index ebbceaa27dcf51bbea53d181484a347677e97081..7c280c84214f6d91aa8aceea5bbb2f8f965295da 100644 (file)
 [225] = { 4,   TD,             SEN(epoll_ctl),                 "epoll_ctl"             },
 [226] = { 4,   TD,             SEN(epoll_wait),                "epoll_wait"            },
 [227] = { 5,   TM|SI,          SEN(remap_file_pages),          "remap_file_pages"      },
-[228] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[228] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [229] = { 4,   TD,             SEN(mq_open),                   "mq_open"               },
 [230] = { 1,   0,              SEN(mq_unlink),                 "mq_unlink"             },
 [231] = { 5,   TD,             SEN(mq_timedsend),              "mq_timedsend"          },
index f86a4c059dc7ab3218df278992e86c6806d6cf58..4edb07a24c4a95a4fe882cc01d0b5ed09774109e 100644 (file)
 [1024 + 220] = { 4,    TD,             SEN(epoll_ctl),                 "epoll_ctl"             },
 [1024 + 221] = { 4,    TD,             SEN(epoll_wait),                "epoll_wait"            },
 [1024 + 222] = { 0,    0,              SEN(restart_syscall),           "restart_syscall"       },
-[1024 + 223] = { 4,    TI,             SEN(semtimedop),                "semtimedop"            },
+[1024 + 223] = { 4,    TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [1024 + 224] = { 3,    0,              SEN(timer_create),              "timer_create"          },
 [1024 + 225] = { 4,    0,              SEN(timer_settime),             "timer_settime"         },
 [1024 + 226] = { 2,    0,              SEN(timer_gettime),             "timer_gettime"         },
index 7e9eaa64396d64ba2cd52463d1505100deb599dd..c6f76478487c4274e7864dcf25d29d1ccbfaaad7 100644 (file)
 [322] = { 2,   TD,             SEN(timerfd_create),            "timerfd_create"        },
 [323] = { 1,   TD,             SEN(eventfd),                   "eventfd"               },
 [324] = { 6,   TD,             SEN(fallocate),                 "fallocate"             },
-[325] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[325] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [326] = { 4,   TD,             SEN(timerfd_settime),           "timerfd_settime"       },
 [327] = { 2,   TD,             SEN(timerfd_gettime),           "timerfd_gettime"       },
 [328] = { 4,   TI,             SEN(semctl),                    "semctl"                },
index 31fd1af14cf9437fcdf7dc082b2cc04a57f781a0..d3b8bbbe504d6bbbe54239ec85ac8b6f09068eb2 100644 (file)
 [6212] = { 3,  TD,             SEN(fcntl64),                   "fcntl64"               },
 [6213] = { 1,  0,              SEN(set_tid_address),           "set_tid_address"       },
 [6214] = { 0,  0,              SEN(restart_syscall),           "restart_syscall"       },
-[6215] = { 4,  TI,             SEN(semtimedop),                "semtimedop"            },
+[6215] = { 4,  TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [6216] = { 4,  TD,             SEN(fadvise64_64),              "fadvise64"             },
 [6217] = { 3,  TF|TSF|TSFA,    SEN(statfs64),                  "statfs64"              },
 [6218] = { 3,  TD|TFSF|TSFA,   SEN(fstatfs64),                 "fstatfs64"             },
index f63ed0e13c72dccbd01e8dca8cbeb3fc914eca6d..353d96019839acd01d12eaa6dc93a6c3849e4321 100644 (file)
 [5211] = { 0,  TS,             SEN(rt_sigreturn),              "rt_sigreturn"          },
 [5212] = { 1,  0,              SEN(set_tid_address),           "set_tid_address"       },
 [5213] = { 0,  0,              SEN(restart_syscall),           "restart_syscall"       },
-[5214] = { 4,  TI,             SEN(semtimedop),                "semtimedop"            },
+[5214] = { 4,  TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [5215] = { 4,  TD,             SEN(fadvise64),                 "fadvise64"             },
 [5216] = { 3,  0,              SEN(timer_create),              "timer_create"          },
 [5217] = { 4,  0,              SEN(timer_settime),             "timer_settime"         },
index 9f9c0af6227c10231e20f00f4876a16178410697..b1ed72c6e1cdfdefceed2ce9d55e99988c24b349 100644 (file)
 [387] = { 4,   0,              SEN(rseq),                      "rseq"                  },
 [388] = { 6,   0,              SEN(io_pgetevents_time64),      "io_pgetevents"         },
 /* room for arch specific syscalls */
-[392] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[392] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [393] = { 3,   TI,             SEN(semget),                    "semget"                },
 [394] = { 4,   TI,             SEN(semctl),                    "semctl"                },
 [395] = { 3,   TI,             SEN(shmget),                    "shmget"                },
index db695cfe808ad663625d4a5e7e5cececaac33d10..1e897112442313ea36e6c0a0d49724953e6cd003 100644 (file)
 [385] = { 2,   0,              SEN(pkey_alloc),                "pkey_alloc"            },
 [386] = { 1,   0,              SEN(pkey_free),                 "pkey_free"             },
 /* room for arch specific calls */
-[392] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[392] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [393] = { 3,   TI,             SEN(semget),                    "semget"                },
 [394] = { 4,   TI,             SEN(semctl),                    "semctl"                },
 [395] = { 3,   TI,             SEN(shmget),                    "shmget"                },
index d276fb63b92c7755510e18cec9c261d28077331e..a6947a8bce59eed1bad8b81a3e6a5e3800af88f5 100644 (file)
 [364] = { 1,   0,              SEN(pkey_free),                 "pkey_free"             },
 [365] = { 4,   0,              SEN(rseq),                      "rseq"                  },
 /* room for arch specific calls */
-[392] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[392] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [393] = { 3,   TI,             SEN(semget),                    "semget"                },
 [394] = { 4,   TI,             SEN(semctl),                    "semctl"                },
 [395] = { 3,   TI,             SEN(shmget),                    "shmget"                },
index 84781af37c41be844e4280430a06b1fa13d33d27..4331faa874d65ed2e20e2db8e06c26b024beced8 100644 (file)
@@ -1 +1,3 @@
+#define sys_semtimedop sys_semtimedop_time32
 #include "subcall.h"
+#undef sys_semtimedop
index 84781af37c41be844e4280430a06b1fa13d33d27..fea7e60d5c79c64b81da4f0f72077b9eef8046e5 100644 (file)
@@ -1 +1,3 @@
+#define sys_semtimedop sys_semtimedop_time64
 #include "subcall.h"
+#undef sys_semtimedop
index 1a1b376114f3c86ab79e68fe16d0705e8ea6ad89..994d80b98539eb5b6df1c7b9ec122f03f8e1c5db 100644 (file)
 [217] = { 3,   TD,             SEN(getdents64),                "getdents64"            },
 [218] = { 1,   0,              SEN(set_tid_address),           "set_tid_address"       },
 [219] = { 0,   0,              SEN(restart_syscall),           "restart_syscall"       },
-[220] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[220] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [221] = { 4,   TD,             SEN(fadvise64),                 "fadvise64"             },
 [222] = { 3,   0,              SEN(printargs),                 "timer_create#64"       },
 [223] = { 4,   0,              SEN(timer_settime),             "timer_settime"         },
index e46d500fbcf1b2c0c6eeefb2ffee789c35c55e92..5852498db4ab740e484ad3f99f23ad4f5f53ecfe 100644 (file)
 [217] = { 3,   TD,             SEN(getdents64),                "getdents64"            },
 [218] = { 1,   0,              SEN(set_tid_address),           "set_tid_address"       },
 [219] = { 0,   0,              SEN(restart_syscall),           "restart_syscall"       },
-[220] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[220] = { 4,   TI,             SEN(semtimedop_time64),         "semtimedop"            },
 [221] = { 4,   TD,             SEN(fadvise64),                 "fadvise64"             },
 [222] = { 3,   0,              SEN(timer_create),              "timer_create"          },
 [223] = { 4,   0,              SEN(timer_settime),             "timer_settime"         },
index 9a0967257a20d8296afdd4c62702eb70be4765c4..de2f508b86a8540b1f55a4f3d0b45a2d8584ad94 100644 (file)
 [158] = { 2,   0,              SEN(capget),                    "capget"                },
 [159] = { 2,   0,              SEN(capset),                    "capset"                },
 [160] = { 4,   0,              SEN(ptrace),                    "ptrace"                },
-[161] = { 4,   TI,             SEN(semtimedop),                "semtimedop"            },
+[161] = { 4,   TI,             SEN(semtimedop_time32),         "semtimedop"            },
 [162] = { 3,   TI,             SEN(semget),                    "semget"                },
 [163] = { 3,   TI,             SEN(semop),                     "semop"                 },
 [164] = { 4,   TI,             SEN(semctl),                    "semctl"                },