From nobody Fri Jun 17 19:39:40 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 12B5585C3C4; Fri, 17 Jun 2022 19:39:41 +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 4LPqB45Hdkz3RC8; Fri, 17 Jun 2022 19:39:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655494780; 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=BLKlh76OUdu5Le6kLQnq3xLxJJZ+HlHqHFLEtGY4bIc=; b=Nbxp6Gr7HL8/LEVz7agHnFw3kr0dN5HUa0fsYdpBfn1mEHaXFmX72meRfRPlfPGgO14VoL Ovlc87mthd8RS+AqOs/0myRX893SUM0XryRVgEDCi1CTNsRcBv6bQRcpGMzvjPCeejU7rW i26Md4xTcd6DfRXwXBwoUaX5G4L4X5tPIX8wvuSNNN9a5exO89ToUykMMaEpNXwTcmeUTf CcKWVSYwEtMoayA0XEpNZ+DLxuAXkvUPaMKudP0YlsxlAxETVriZ/OHJLi/DfOjVCGTxhK VQXoo1A3uIiMBn01yk2iC4k61qnzg+2gJLMYhiUaHylBzviPxU22wc/TS6qMgg== 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 511F625D0F; Fri, 17 Jun 2022 19:39:40 +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 25HJded6016315; Fri, 17 Jun 2022 19:39:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 25HJdeBc016313; Fri, 17 Jun 2022 19:39:40 GMT (envelope-from git) Date: Fri, 17 Jun 2022 19:39:40 GMT Message-Id: <202206171939.25HJdeBc016313@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dmitry Chagin Subject: git: 62787d1535b2 - stable/13 - linux(4): Regen for timer_settime64 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/stable/13 X-Git-Reftype: branch X-Git-Commit: 62787d1535b2056b3f3089a0f4eae969012d3952 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655494780; 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=BLKlh76OUdu5Le6kLQnq3xLxJJZ+HlHqHFLEtGY4bIc=; b=ynxZPKIzsJgzXq5AJaOkh7VQ7NogIaC2h1CA7z6S75MIpEvIlNdf+r1Y3vaqtf1CGeqkPY eh7zSkoHDy20v0nQhp78XAkWo4Q8e+i6ubIL2GsoDTZafBc0sFkOLcdwRNEaDA/myavXvz WY0gXOPSLAnIeE661anAu5Y2VSAaGVnfgl2GSxKKdCKLjp/vz59nOM7FzlPk195QVZKJ1X 96qdkvItMkwt/0jPiXn7dMekNABMTliJZPTTgtNNv0awfWuzJFzqoiULuKDv1ioXU6SLBY EZCkhcCaGtJTWCxrSC4zYM7e2Px1UBjo+LFJ0yIWFDNnD6rJdOTEAe1UY/Hv4A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1655494780; a=rsa-sha256; cv=none; b=UCqCastPMbtNHfUwfWqi/axMVmMQR0w1bJkQ8mJbMV+ewbUU+/SPMTU4AhDDPL3ReAsp1l 2o/fI5EF+PltSw4+PFwa3MTYWUfaH3DQhtmpp1S/CkdcQ3Atr3wV7znuEph/qqMICH2Lrr 2LgfG2dOKZEOL24m17AFVjv+50owLuA/udNsfUrMfYVw5/IZKkul7l7Mnk/KAwLR6pOkMn lAKea7RY+RS4GQOHaPKze5w8+tyJ7GSNTbl/rlnK6R3HMCDDqf6QZQZVVPo646dWHUxbSk rKlUlK9Q9AkjbVjoRHNQGt2AutZjgnX4lWjQk4v432PAkB78OfGbD8ZiKsx5eA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=62787d1535b2056b3f3089a0f4eae969012d3952 commit 62787d1535b2056b3f3089a0f4eae969012d3952 Author: Dmitry Chagin AuthorDate: 2022-06-17 19:34:26 +0000 Commit: Dmitry Chagin CommitDate: 2022-06-17 19:34:26 +0000 linux(4): Regen for timer_settime64 syscall. MFC after: 2 weeks (cherry picked from commit 9038a0b74cf74c73cea635ae2fff51706cc9ab33) --- sys/amd64/linux32/linux32_proto.h | 5 ++++- sys/amd64/linux32/linux32_sysent.c | 2 +- sys/amd64/linux32/linux32_systrace_args.c | 26 +++++++++++++++++++++++++- sys/i386/linux/linux_proto.h | 5 ++++- sys/i386/linux/linux_sysent.c | 2 +- sys/i386/linux/linux_systrace_args.c | 26 +++++++++++++++++++++++++- 6 files changed, 60 insertions(+), 6 deletions(-) diff --git a/sys/amd64/linux32/linux32_proto.h b/sys/amd64/linux32/linux32_proto.h index 72b98223fbf3..1416b339cc6f 100644 --- a/sys/amd64/linux32/linux32_proto.h +++ b/sys/amd64/linux32/linux32_proto.h @@ -1552,7 +1552,10 @@ struct linux_timer_gettime64_args { char setting_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * setting; char setting_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timer_settime64_args { - register_t dummy; + char timerid_l_[PADL_(l_timer_t)]; l_timer_t timerid; char timerid_r_[PADR_(l_timer_t)]; + char flags_l_[PADL_(l_int)]; l_int flags; char flags_r_[PADR_(l_int)]; + char new_l_[PADL_(const struct l_itimerspec64 *)]; const struct l_itimerspec64 * new; char new_r_[PADR_(const struct l_itimerspec64 *)]; + char old_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * old; char old_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timerfd_gettime64_args { register_t dummy; diff --git a/sys/amd64/linux32/linux32_sysent.c b/sys/amd64/linux32/linux32_sysent.c index 47b93ee4fd9d..b7ca6a5a29f1 100644 --- a/sys/amd64/linux32/linux32_sysent.c +++ b/sys/amd64/linux32/linux32_sysent.c @@ -426,7 +426,7 @@ struct sysent linux32_sysent[] = { { .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 = 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 = AS(linux_timer_settime64_args), .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 */ { .sy_narg = AS(linux_utimensat_time64_args), .sy_call = (sy_call_t *)linux_utimensat_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 412 = linux_utimensat_time64 */ diff --git a/sys/amd64/linux32/linux32_systrace_args.c b/sys/amd64/linux32/linux32_systrace_args.c index d9bee0f0499b..05d88c7a13b3 100644 --- a/sys/amd64/linux32/linux32_systrace_args.c +++ b/sys/amd64/linux32/linux32_systrace_args.c @@ -3014,7 +3014,12 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_timer_settime64 */ case 409: { - *n_args = 0; + struct linux_timer_settime64_args *p = params; + iarg[0] = p->timerid; /* l_timer_t */ + iarg[1] = p->flags; /* l_int */ + uarg[2] = (intptr_t)p->new; /* const struct l_itimerspec64 * */ + uarg[3] = (intptr_t)p->old; /* struct l_itimerspec64 * */ + *n_args = 4; break; } /* linux_timerfd_gettime64 */ @@ -8146,6 +8151,22 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_settime64 */ case 409: + switch (ndx) { + case 0: + p = "l_timer_t"; + break; + case 1: + p = "l_int"; + break; + case 2: + p = "userland const struct l_itimerspec64 *"; + break; + case 3: + p = "userland struct l_itimerspec64 *"; + break; + default: + break; + }; break; /* linux_timerfd_gettime64 */ case 410: @@ -10081,6 +10102,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_settime64 */ case 409: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_timerfd_gettime64 */ case 410: /* linux_timerfd_settime64 */ diff --git a/sys/i386/linux/linux_proto.h b/sys/i386/linux/linux_proto.h index 2a99b10415c9..3f60a49ef629 100644 --- a/sys/i386/linux/linux_proto.h +++ b/sys/i386/linux/linux_proto.h @@ -1545,7 +1545,10 @@ struct linux_timer_gettime64_args { char setting_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * setting; char setting_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timer_settime64_args { - register_t dummy; + char timerid_l_[PADL_(l_timer_t)]; l_timer_t timerid; char timerid_r_[PADR_(l_timer_t)]; + char flags_l_[PADL_(l_int)]; l_int flags; char flags_r_[PADR_(l_int)]; + char new_l_[PADL_(const struct l_itimerspec64 *)]; const struct l_itimerspec64 * new; char new_r_[PADR_(const struct l_itimerspec64 *)]; + char old_l_[PADL_(struct l_itimerspec64 *)]; struct l_itimerspec64 * old; char old_r_[PADR_(struct l_itimerspec64 *)]; }; struct linux_timerfd_gettime64_args { register_t dummy; diff --git a/sys/i386/linux/linux_sysent.c b/sys/i386/linux/linux_sysent.c index 8c31ca748475..412cd53b5ed9 100644 --- a/sys/i386/linux/linux_sysent.c +++ b/sys/i386/linux/linux_sysent.c @@ -426,7 +426,7 @@ struct sysent linux_sysent[] = { { .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 = 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 = AS(linux_timer_settime64_args), .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 */ { .sy_narg = AS(linux_utimensat_time64_args), .sy_call = (sy_call_t *)linux_utimensat_time64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 412 = linux_utimensat_time64 */ diff --git a/sys/i386/linux/linux_systrace_args.c b/sys/i386/linux/linux_systrace_args.c index 3473806f9b9c..74e705cccc62 100644 --- a/sys/i386/linux/linux_systrace_args.c +++ b/sys/i386/linux/linux_systrace_args.c @@ -3053,7 +3053,12 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_timer_settime64 */ case 409: { - *n_args = 0; + struct linux_timer_settime64_args *p = params; + iarg[0] = p->timerid; /* l_timer_t */ + iarg[1] = p->flags; /* l_int */ + uarg[2] = (intptr_t)p->new; /* const struct l_itimerspec64 * */ + uarg[3] = (intptr_t)p->old; /* struct l_itimerspec64 * */ + *n_args = 4; break; } /* linux_timerfd_gettime64 */ @@ -8223,6 +8228,22 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_settime64 */ case 409: + switch (ndx) { + case 0: + p = "l_timer_t"; + break; + case 1: + p = "l_int"; + break; + case 2: + p = "userland const struct l_itimerspec64 *"; + break; + case 3: + p = "userland struct l_itimerspec64 *"; + break; + default: + break; + }; break; /* linux_timerfd_gettime64 */ case 410: @@ -10187,6 +10208,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_timer_settime64 */ case 409: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_timerfd_gettime64 */ case 410: /* linux_timerfd_settime64 */