diff options
author | Dmitry Chagin <dchagin@FreeBSD.org> | 2023-04-04 20:23:37 +0000 |
---|---|---|
committer | Dmitry Chagin <dchagin@FreeBSD.org> | 2023-04-04 20:23:37 +0000 |
commit | 50111714f5a46add66264d48456c32b7d3d0036a (patch) | |
tree | 9b9d5d95472ab694054024f7d4842cacd1a79ff6 | |
parent | 1c27dce1f8979e7bbe3ca51f4f2db38b202042a0 (diff) | |
download | src-50111714f5a46add66264d48456c32b7d3d0036a.tar.gz src-50111714f5a46add66264d48456c32b7d3d0036a.zip |
linux(4): Regen for close_range syscall
MFC after: 2 weeks
-rw-r--r-- | sys/amd64/linux/linux_proto.h | 6 | ||||
-rw-r--r-- | sys/amd64/linux/linux_sysent.c | 2 | ||||
-rw-r--r-- | sys/amd64/linux/linux_systrace_args.c | 22 | ||||
-rw-r--r-- | sys/amd64/linux32/linux32_proto.h | 6 | ||||
-rw-r--r-- | sys/amd64/linux32/linux32_sysent.c | 2 | ||||
-rw-r--r-- | sys/amd64/linux32/linux32_systrace_args.c | 22 | ||||
-rw-r--r-- | sys/arm64/linux/linux_proto.h | 6 | ||||
-rw-r--r-- | sys/arm64/linux/linux_sysent.c | 2 | ||||
-rw-r--r-- | sys/arm64/linux/linux_systrace_args.c | 22 | ||||
-rw-r--r-- | sys/i386/linux/linux_proto.h | 6 | ||||
-rw-r--r-- | sys/i386/linux/linux_sysent.c | 2 | ||||
-rw-r--r-- | sys/i386/linux/linux_systrace_args.c | 22 |
12 files changed, 104 insertions, 16 deletions
diff --git a/sys/amd64/linux/linux_proto.h b/sys/amd64/linux/linux_proto.h index 8b4ea2bb42fc..3695bc077225 100644 --- a/sys/amd64/linux/linux_proto.h +++ b/sys/amd64/linux/linux_proto.h @@ -1363,7 +1363,9 @@ struct linux_clone3_args { char usize_l_[PADL_(l_size_t)]; l_size_t usize; char usize_r_[PADR_(l_size_t)]; }; struct linux_close_range_args { - syscallarg_t dummy; + char first_l_[PADL_(l_uint)]; l_uint first; char first_r_[PADR_(l_uint)]; + char last_l_[PADL_(l_uint)]; l_uint last; char last_r_[PADR_(l_uint)]; + char flags_l_[PADL_(l_uint)]; l_uint flags; char flags_r_[PADR_(l_uint)]; }; struct linux_openat2_args { syscallarg_t dummy; @@ -1979,7 +1981,7 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_fspick AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_open AUE_NULL #define LINUX_SYS_AUE_linux_clone3 AUE_NULL -#define LINUX_SYS_AUE_linux_close_range AUE_NULL +#define LINUX_SYS_AUE_linux_close_range AUE_CLOSERANGE #define LINUX_SYS_AUE_linux_openat2 AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_getfd AUE_NULL #define LINUX_SYS_AUE_linux_faccessat2 AUE_NULL diff --git a/sys/amd64/linux/linux_sysent.c b/sys/amd64/linux/linux_sysent.c index 7716c34305d8..8a8b6ecc105a 100644 --- a/sys/amd64/linux/linux_sysent.c +++ b/sys/amd64/linux/linux_sysent.c @@ -453,7 +453,7 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fspick, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 433 = linux_fspick */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_open, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 434 = linux_pidfd_open */ { .sy_narg = AS(linux_clone3_args), .sy_call = (sy_call_t *)linux_clone3, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 435 = linux_clone3 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ + { .sy_narg = AS(linux_close_range_args), .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_CLOSERANGE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_openat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 437 = linux_openat2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_getfd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 438 = linux_pidfd_getfd */ { .sy_narg = AS(linux_faccessat2_args), .sy_call = (sy_call_t *)linux_faccessat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 439 = linux_faccessat2 */ diff --git a/sys/amd64/linux/linux_systrace_args.c b/sys/amd64/linux/linux_systrace_args.c index c0d079200f62..d2f95d8dfc48 100644 --- a/sys/amd64/linux/linux_systrace_args.c +++ b/sys/amd64/linux/linux_systrace_args.c @@ -2696,7 +2696,11 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_close_range */ case 436: { - *n_args = 0; + struct linux_close_range_args *p = params; + iarg[a++] = p->first; /* l_uint */ + iarg[a++] = p->last; /* l_uint */ + iarg[a++] = p->flags; /* l_uint */ + *n_args = 3; break; } /* linux_openat2 */ @@ -7078,6 +7082,19 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + switch (ndx) { + case 0: + p = "l_uint"; + break; + case 1: + p = "l_uint"; + break; + case 2: + p = "l_uint"; + break; + default: + break; + }; break; /* linux_openat2 */ case 437: @@ -8608,6 +8625,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_openat2 */ case 437: /* linux_pidfd_getfd */ diff --git a/sys/amd64/linux32/linux32_proto.h b/sys/amd64/linux32/linux32_proto.h index 219f0f09f8c9..22867031a422 100644 --- a/sys/amd64/linux32/linux32_proto.h +++ b/sys/amd64/linux32/linux32_proto.h @@ -1669,7 +1669,9 @@ struct linux_clone3_args { char usize_l_[PADL_(l_size_t)]; l_size_t usize; char usize_r_[PADR_(l_size_t)]; }; struct linux_close_range_args { - syscallarg_t dummy; + char first_l_[PADL_(l_uint)]; l_uint first; char first_r_[PADR_(l_uint)]; + char last_l_[PADL_(l_uint)]; l_uint last; char last_r_[PADR_(l_uint)]; + char flags_l_[PADL_(l_uint)]; l_uint flags; char flags_r_[PADR_(l_uint)]; }; struct linux_openat2_args { syscallarg_t dummy; @@ -2417,7 +2419,7 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX32_SYS_AUE_linux_fspick AUE_NULL #define LINUX32_SYS_AUE_linux_pidfd_open AUE_NULL #define LINUX32_SYS_AUE_linux_clone3 AUE_NULL -#define LINUX32_SYS_AUE_linux_close_range AUE_NULL +#define LINUX32_SYS_AUE_linux_close_range AUE_CLOSERANGE #define LINUX32_SYS_AUE_linux_openat2 AUE_NULL #define LINUX32_SYS_AUE_linux_pidfd_getfd AUE_NULL #define LINUX32_SYS_AUE_linux_faccessat2 AUE_NULL diff --git a/sys/amd64/linux32/linux32_sysent.c b/sys/amd64/linux32/linux32_sysent.c index 54a1c50807f2..9527a225da09 100644 --- a/sys/amd64/linux32/linux32_sysent.c +++ b/sys/amd64/linux32/linux32_sysent.c @@ -453,7 +453,7 @@ struct sysent linux32_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fspick, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 433 = linux_fspick */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_open, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 434 = linux_pidfd_open */ { .sy_narg = AS(linux_clone3_args), .sy_call = (sy_call_t *)linux_clone3, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 435 = linux_clone3 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ + { .sy_narg = AS(linux_close_range_args), .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_CLOSERANGE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_openat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 437 = linux_openat2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_getfd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 438 = linux_pidfd_getfd */ { .sy_narg = AS(linux_faccessat2_args), .sy_call = (sy_call_t *)linux_faccessat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 439 = linux_faccessat2 */ diff --git a/sys/amd64/linux32/linux32_systrace_args.c b/sys/amd64/linux32/linux32_systrace_args.c index fee5cf2c2e2d..9ee2fadf0fe1 100644 --- a/sys/amd64/linux32/linux32_systrace_args.c +++ b/sys/amd64/linux32/linux32_systrace_args.c @@ -3210,7 +3210,11 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_close_range */ case 436: { - *n_args = 0; + struct linux_close_range_args *p = params; + iarg[a++] = p->first; /* l_uint */ + iarg[a++] = p->last; /* l_uint */ + iarg[a++] = p->flags; /* l_uint */ + *n_args = 3; break; } /* linux_openat2 */ @@ -8457,6 +8461,19 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + switch (ndx) { + case 0: + p = "l_uint"; + break; + case 1: + p = "l_uint"; + break; + case 2: + p = "l_uint"; + break; + default: + break; + }; break; /* linux_openat2 */ case 437: @@ -10274,6 +10291,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_openat2 */ case 437: /* linux_pidfd_getfd */ diff --git a/sys/arm64/linux/linux_proto.h b/sys/arm64/linux/linux_proto.h index ef5be3bce6bf..dd335a6b92ea 100644 --- a/sys/arm64/linux/linux_proto.h +++ b/sys/arm64/linux/linux_proto.h @@ -1173,7 +1173,9 @@ struct linux_clone3_args { char usize_l_[PADL_(l_size_t)]; l_size_t usize; char usize_r_[PADR_(l_size_t)]; }; struct linux_close_range_args { - syscallarg_t dummy; + char first_l_[PADL_(l_uint)]; l_uint first; char first_r_[PADR_(l_uint)]; + char last_l_[PADL_(l_uint)]; l_uint last; char last_r_[PADR_(l_uint)]; + char flags_l_[PADL_(l_uint)]; l_uint flags; char flags_r_[PADR_(l_uint)]; }; struct linux_openat2_args { syscallarg_t dummy; @@ -1691,7 +1693,7 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_fspick AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_open AUE_NULL #define LINUX_SYS_AUE_linux_clone3 AUE_NULL -#define LINUX_SYS_AUE_linux_close_range AUE_NULL +#define LINUX_SYS_AUE_linux_close_range AUE_CLOSERANGE #define LINUX_SYS_AUE_linux_openat2 AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_getfd AUE_NULL #define LINUX_SYS_AUE_linux_faccessat2 AUE_NULL diff --git a/sys/arm64/linux/linux_sysent.c b/sys/arm64/linux/linux_sysent.c index 51bf3fe8cc07..0155bf80f738 100644 --- a/sys/arm64/linux/linux_sysent.c +++ b/sys/arm64/linux/linux_sysent.c @@ -453,7 +453,7 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fspick, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 433 = linux_fspick */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_open, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 434 = linux_pidfd_open */ { .sy_narg = AS(linux_clone3_args), .sy_call = (sy_call_t *)linux_clone3, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 435 = linux_clone3 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ + { .sy_narg = AS(linux_close_range_args), .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_CLOSERANGE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_openat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 437 = linux_openat2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_getfd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 438 = linux_pidfd_getfd */ { .sy_narg = AS(linux_faccessat2_args), .sy_call = (sy_call_t *)linux_faccessat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 439 = linux_faccessat2 */ diff --git a/sys/arm64/linux/linux_systrace_args.c b/sys/arm64/linux/linux_systrace_args.c index 88083ca7fa92..eec92ed1a379 100644 --- a/sys/arm64/linux/linux_systrace_args.c +++ b/sys/arm64/linux/linux_systrace_args.c @@ -2318,7 +2318,11 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_close_range */ case 436: { - *n_args = 0; + struct linux_close_range_args *p = params; + iarg[a++] = p->first; /* l_uint */ + iarg[a++] = p->last; /* l_uint */ + iarg[a++] = p->flags; /* l_uint */ + *n_args = 3; break; } /* linux_openat2 */ @@ -6153,6 +6157,19 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + switch (ndx) { + case 0: + p = "l_uint"; + break; + case 1: + p = "l_uint"; + break; + case 2: + p = "l_uint"; + break; + default: + break; + }; break; /* linux_openat2 */ case 437: @@ -7468,6 +7485,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_openat2 */ case 437: /* linux_pidfd_getfd */ diff --git a/sys/i386/linux/linux_proto.h b/sys/i386/linux/linux_proto.h index 2e243d463a13..8b603f2de1ca 100644 --- a/sys/i386/linux/linux_proto.h +++ b/sys/i386/linux/linux_proto.h @@ -1662,7 +1662,9 @@ struct linux_clone3_args { char usize_l_[PADL_(l_size_t)]; l_size_t usize; char usize_r_[PADR_(l_size_t)]; }; struct linux_close_range_args { - syscallarg_t dummy; + char first_l_[PADL_(l_uint)]; l_uint first; char first_r_[PADR_(l_uint)]; + char last_l_[PADL_(l_uint)]; l_uint last; char last_r_[PADR_(l_uint)]; + char flags_l_[PADL_(l_uint)]; l_uint flags; char flags_r_[PADR_(l_uint)]; }; struct linux_openat2_args { syscallarg_t dummy; @@ -2414,7 +2416,7 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_fspick AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_open AUE_NULL #define LINUX_SYS_AUE_linux_clone3 AUE_NULL -#define LINUX_SYS_AUE_linux_close_range AUE_NULL +#define LINUX_SYS_AUE_linux_close_range AUE_CLOSERANGE #define LINUX_SYS_AUE_linux_openat2 AUE_NULL #define LINUX_SYS_AUE_linux_pidfd_getfd AUE_NULL #define LINUX_SYS_AUE_linux_faccessat2 AUE_NULL diff --git a/sys/i386/linux/linux_sysent.c b/sys/i386/linux/linux_sysent.c index 5a39c9369a7d..6aa759f22f90 100644 --- a/sys/i386/linux/linux_sysent.c +++ b/sys/i386/linux/linux_sysent.c @@ -453,7 +453,7 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fspick, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 433 = linux_fspick */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_open, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 434 = linux_pidfd_open */ { .sy_narg = AS(linux_clone3_args), .sy_call = (sy_call_t *)linux_clone3, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 435 = linux_clone3 */ - { .sy_narg = 0, .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ + { .sy_narg = AS(linux_close_range_args), .sy_call = (sy_call_t *)linux_close_range, .sy_auevent = AUE_CLOSERANGE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 436 = linux_close_range */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_openat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 437 = linux_openat2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_pidfd_getfd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 438 = linux_pidfd_getfd */ { .sy_narg = AS(linux_faccessat2_args), .sy_call = (sy_call_t *)linux_faccessat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 439 = linux_faccessat2 */ diff --git a/sys/i386/linux/linux_systrace_args.c b/sys/i386/linux/linux_systrace_args.c index 613d1ada1b3f..e773e8f58064 100644 --- a/sys/i386/linux/linux_systrace_args.c +++ b/sys/i386/linux/linux_systrace_args.c @@ -3249,7 +3249,11 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) } /* linux_close_range */ case 436: { - *n_args = 0; + struct linux_close_range_args *p = params; + iarg[a++] = p->first; /* l_uint */ + iarg[a++] = p->last; /* l_uint */ + iarg[a++] = p->flags; /* l_uint */ + *n_args = 3; break; } /* linux_openat2 */ @@ -8534,6 +8538,19 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + switch (ndx) { + case 0: + p = "l_uint"; + break; + case 1: + p = "l_uint"; + break; + case 2: + p = "l_uint"; + break; + default: + break; + }; break; /* linux_openat2 */ case 437: @@ -10380,6 +10397,9 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_close_range */ case 436: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_openat2 */ case 437: /* linux_pidfd_getfd */ |