From nobody Wed May 04 10:08:08 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 2C5951AAA0E2; Wed, 4 May 2022 10:08:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KtXZw68kVz4dXV; Wed, 4 May 2022 10:08:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1651658888; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P7/w4t4j90jq5TeE9Mi6GIBV6ZlBSJgSTlHnqRvSu4I=; b=pIQfXQS2qKJ+B3djFdzsetbbg0WMxq/kB/0UkwDp1YLHKzF9dLbTiHMADtsZYoZ/UUs9iH 0uWIJHdsZGjsHD78WgnCcKe7WMXCy51wiSP97bNQlHnuWhftRjTkgqQCcQRC3XjrT0Y2Le /zTQR9AXO3T8JqhwS1lQ0MAeLq1VYGnqpfjtji78Iag8iUJLq0DaBlE+kQD3jvGGXFvfMQ lT0g6Hi5ehWKYUPMv/2+dXpP33BMtkOEtJsadm2gITbYON14bTUxovpuMdwtet3jh9Eyo8 LQ4dAv9xg06vvXLK+baV+0CDGIq0OfkFxafMA1dgRPoIfReCHoUcrwlnAdXbSQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id AD95510FD7; Wed, 4 May 2022 10:08:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 244A88ai000338; Wed, 4 May 2022 10:08:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 244A88MG000337; Wed, 4 May 2022 10:08:08 GMT (envelope-from git) Date: Wed, 4 May 2022 10:08:08 GMT Message-Id: <202205041008.244A88MG000337@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dmitry Chagin Subject: git: 1cccef6dff13 - main - linux(4): Regen for timer_gettime64 syscall. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dchagin X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1cccef6dff13f4854ac75c243c36317ccd4defc1 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1651658888; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P7/w4t4j90jq5TeE9Mi6GIBV6ZlBSJgSTlHnqRvSu4I=; b=B2/iSaWXrHFfPLCMYbDjarMa6CI832SfRRCR3GymCTL3emyiAZkNabbU5VFRciAclK/WME 9ybmWuvwcgrg4QvXP4Nm24VPtmIEJ2muh4wyzYUGDvfnsXoup/nTqApV4SMoLI0wdTaWvk isTVglQ236VP3Hs7WzL9duwoSMSkgQSBPSMnRAgP6OL+IZzGA8spt9nNVqwI5eFqMh3BJ+ 0hqBKNCCS6dlKXGOy0gX/wa2TclbG++V2y6GmPNakKJJGaaFUl8v+lFZxZogMjEOed4Jty jUyRliRvlV+dwrUzrb920jf56DYqcTO6kzzAVaRhWygWxlDOCqQw5zBUa7uh3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1651658888; a=rsa-sha256; cv=none; b=j221pqsEL4bAbgvc0fsB2CQtSDzdHmO5hbuxQQ1yVKWh/KjeCT0BtctTI0aV2yPoXaMrmD VDcbCu0SAVZuu/6f2ry33RfEUqa//qaYDNbCpg/WhfJVwbvBFVqBXxP58DkB8aX0dvfa0x S1UL1Mzbng3U0pE09g127EY4QQSvU1fwprrlFWFI4E/QruUUpVB89NhgqaWdPcGP+qdaka b5ylTiTStoy7BzUvfMmzRVMvPB1ieofsOBqrY226DDHlZ5YYjcuKWBcjEU4WOBt/UJIVU1 C/QsJv7pBq2rkg5kXE7B+H2Cul2lhTY/8uk0pyweYsLOnYpf89M43wGj3BDeFw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=1cccef6dff13f4854ac75c243c36317ccd4defc1 commit 1cccef6dff13f4854ac75c243c36317ccd4defc1 Author: Dmitry Chagin AuthorDate: 2022-05-04 10:06:48 +0000 Commit: Dmitry Chagin CommitDate: 2022-05-04 10:06:48 +0000 linux(4): Regen for timer_gettime64 syscall. MFC after: 2 weeks --- sys/amd64/linux32/linux32_proto.h | 3 ++- sys/amd64/linux32/linux32_sysent.c | 2 +- sys/amd64/linux32/linux32_systrace_args.c | 18 +++++++++++++++++- sys/i386/linux/linux_proto.h | 3 ++- sys/i386/linux/linux_sysent.c | 2 +- sys/i386/linux/linux_systrace_args.c | 18 +++++++++++++++++- 6 files changed, 40 insertions(+), 6 deletions(-) diff --git a/sys/amd64/linux32/linux32_proto.h b/sys/amd64/linux32/linux32_proto.h index 3254c33baaae..4fb67539965c 100644 --- a/sys/amd64/linux32/linux32_proto.h +++ b/sys/amd64/linux32/linux32_proto.h @@ -1548,7 +1548,8 @@ struct linux_clock_nanosleep_time64_args { char rmtp_l_[PADL_(struct l_timespec64 *)]; struct l_timespec64 * rmtp; char rmtp_r_[PADR_(struct l_timespec64 *)]; }; struct linux_timer_gettime64_args { - syscallarg_t dummy; + char timerid_l_[PADL_(l_timer_t)]; l_timer_t timerid; char timerid_r_[PADR_(l_timer_t)]; + char setting_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * setting; char setting_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timer_settime64_args { syscallarg_t dummy; diff --git a/sys/amd64/linux32/linux32_sysent.c b/sys/amd64/linux32/linux32_sysent.c index 27449f412cb8..418356a373f9 100644 --- a/sys/amd64/linux32/linux32_sysent.c +++ b/sys/amd64/linux32/linux32_sysent.c @@ -425,7 +425,7 @@ struct sysent linux32_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_clock_adjtime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 405 = linux_clock_adjtime64 */ { .sy_narg = AS(linux_clock_getres_time64_args), .sy_call = (sy_call_t *)linux_clock_getres_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 406 = linux_clock_getres_time64 */ { .sy_narg = AS(linux_clock_nanosleep_time64_args), .sy_call = (sy_call_t *)linux_clock_nanosleep_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 407 = linux_clock_nanosleep_time64 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timer_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 408 = linux_timer_gettime64 */ + { .sy_narg = AS(linux_timer_gettime64_args), .sy_call = (sy_call_t *)linux_timer_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 408 = linux_timer_gettime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timer_settime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 409 = linux_timer_settime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timerfd_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 410 = linux_timerfd_gettime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timerfd_settime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 411 = linux_timerfd_settime64 */ diff --git a/sys/amd64/linux32/linux32_systrace_args.c b/sys/amd64/linux32/linux32_systrace_args.c index 8cc88ba300dd..56593829ef7f 100644 --- a/sys/amd64/linux32/linux32_systrace_args.c +++ b/sys/amd64/linux32/linux32_systrace_args.c @@ -3007,7 +3007,10 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_timer_gettime64 */ case 408: { - *n_args = 0; + struct linux_timer_gettime64_args *p = params; + iarg[a++] = p->timerid; /* l_timer_t */ + uarg[a++] = (intptr_t)p->setting; /* struct l_itimerspec64 * */ + *n_args = 2; break; } /* linux_timer_settime64 */ @@ -8131,6 +8134,16 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_gettime64 */ case 408: + switch (ndx) { + case 0: + p = "l_timer_t"; + break; + case 1: + p = "userland struct l_itimerspec64 *"; + break; + default: + break; + }; break; /* linux_timer_settime64 */ case 409: @@ -10064,6 +10077,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_gettime64 */ case 408: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_timer_settime64 */ case 409: /* linux_timerfd_gettime64 */ diff --git a/sys/i386/linux/linux_proto.h b/sys/i386/linux/linux_proto.h index 43e8578ba0c9..4b3ce9852f5b 100644 --- a/sys/i386/linux/linux_proto.h +++ b/sys/i386/linux/linux_proto.h @@ -1541,7 +1541,8 @@ struct linux_clock_nanosleep_time64_args { char rmtp_l_[PADL_(struct l_timespec64 *)]; struct l_timespec64 * rmtp; char rmtp_r_[PADR_(struct l_timespec64 *)]; }; struct linux_timer_gettime64_args { - syscallarg_t dummy; + char timerid_l_[PADL_(l_timer_t)]; l_timer_t timerid; char timerid_r_[PADR_(l_timer_t)]; + char setting_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * setting; char setting_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timer_settime64_args { syscallarg_t dummy; diff --git a/sys/i386/linux/linux_sysent.c b/sys/i386/linux/linux_sysent.c index f2c5543d57ce..3d76b8584b05 100644 --- a/sys/i386/linux/linux_sysent.c +++ b/sys/i386/linux/linux_sysent.c @@ -425,7 +425,7 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_clock_adjtime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 405 = linux_clock_adjtime64 */ { .sy_narg = AS(linux_clock_getres_time64_args), .sy_call = (sy_call_t *)linux_clock_getres_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 406 = linux_clock_getres_time64 */ { .sy_narg = AS(linux_clock_nanosleep_time64_args), .sy_call = (sy_call_t *)linux_clock_nanosleep_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 407 = linux_clock_nanosleep_time64 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timer_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 408 = linux_timer_gettime64 */ + { .sy_narg = AS(linux_timer_gettime64_args), .sy_call = (sy_call_t *)linux_timer_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 408 = linux_timer_gettime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timer_settime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 409 = linux_timer_settime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timerfd_gettime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 410 = linux_timerfd_gettime64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_timerfd_settime64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 411 = linux_timerfd_settime64 */ diff --git a/sys/i386/linux/linux_systrace_args.c b/sys/i386/linux/linux_systrace_args.c index 660be1e8a9f4..d764167f2400 100644 --- a/sys/i386/linux/linux_systrace_args.c +++ b/sys/i386/linux/linux_systrace_args.c @@ -3046,7 +3046,10 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_timer_gettime64 */ case 408: { - *n_args = 0; + struct linux_timer_gettime64_args *p = params; + iarg[a++] = p->timerid; /* l_timer_t */ + uarg[a++] = (intptr_t)p->setting; /* struct l_itimerspec64 * */ + *n_args = 2; break; } /* linux_timer_settime64 */ @@ -8208,6 +8211,16 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_gettime64 */ case 408: + switch (ndx) { + case 0: + p = "l_timer_t"; + break; + case 1: + p = "userland struct l_itimerspec64 *"; + break; + default: + break; + }; break; /* linux_timer_settime64 */ case 409: @@ -10170,6 +10183,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_gettime64 */ case 408: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_timer_settime64 */ case 409: /* linux_timerfd_gettime64 */