The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=4d08e7815d6c71c620f19a8abdf0caa26f9c5c57
commit 4d08e7815d6c71c620f19a8abdf0caa26f9c5c57 Author: Mark Johnston <ma...@freebsd.org> AuthorDate: 2025-07-03 19:52:56 +0000 Commit: Mark Johnston <ma...@freebsd.org> CommitDate: 2025-07-04 14:42:33 +0000 truss: Add a decoder for inotify_add_watch_at(2) MFC after: 3 months Sponsored by: Klara, Inc. --- usr.bin/truss/syscall.h | 1 + usr.bin/truss/syscalls.c | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.bin/truss/syscall.h b/usr.bin/truss/syscall.h index d79ef882cff0..47d973326dfb 100644 --- a/usr.bin/truss/syscall.h +++ b/usr.bin/truss/syscall.h @@ -99,6 +99,7 @@ enum Argtype { Getfsstatmode, Idtype, Ioctl, + Inotifyflags, Itimerwhich, Kldsymcmd, Kldunloadflags, diff --git a/usr.bin/truss/syscalls.c b/usr.bin/truss/syscalls.c index 47d6aef8f6ff..656d642e1f19 100644 --- a/usr.bin/truss/syscalls.c +++ b/usr.bin/truss/syscalls.c @@ -31,7 +31,6 @@ * SUCH DAMAGE. */ -#include <sys/cdefs.h> /* * This file has routines used to print out system calls and their * arguments. @@ -316,6 +315,9 @@ static const struct syscall_decode decoded_syscalls[] = { { Ptr | OUT, 3 }, { Ptr | OUT, 4 } } }, { .name = "gettimeofday", .ret_type = 1, .nargs = 2, .args = { { Timeval | OUT, 0 }, { Ptr, 1 } } }, + { .name = "inotify_add_watch_at", .ret_type = 1, .nargs = 4, + .args = { { Int, 0 }, { Atfd, 1 }, { Name | IN, 2 }, + { Inotifyflags, 3 } } }, { .name = "ioctl", .ret_type = 1, .nargs = 3, .args = { { Int, 0 }, { Ioctl, 1 }, { Ptr, 2 } } }, { .name = "kevent", .ret_type = 1, .nargs = 6, @@ -2447,6 +2449,9 @@ print_arg(struct syscall_arg *sc, syscallarg_t *args, syscallarg_t *retval, print_integer_arg(sysdecode_getfsstat_mode, fp, args[sc->offset]); break; + case Inotifyflags: + print_mask_arg(sysdecode_inotifyflags, fp, args[sc->offset]); + break; case Itimerwhich: print_integer_arg(sysdecode_itimer, fp, args[sc->offset]); break;