Decode arguments to madvise().

This commit is contained in:
John Baldwin 2017-03-19 00:31:21 +00:00
parent e261fb2a5b
commit 98fdbeec47
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=315524
2 changed files with 6 additions and 1 deletions

View File

@ -46,7 +46,7 @@ enum Argtype { None = 1, Hex, Octal, Int, UInt, LongHex, Name, Ptr, Stat, Ioctl,
LinuxSockArgs, Umtxop, Atfd, Atflags, Timespec2, Accessmode, Long,
Sysarch, ExecArgs, ExecEnv, PipeFds, QuadHex, Utrace, IntArray, Pipe2,
CapFcntlRights, Fadvice, FileFlags, Flockop, Getfsstatmode, Kldsymcmd,
Kldunloadflags, Sizet,
Kldunloadflags, Sizet, Madvice,
CloudABIAdvice, CloudABIClockID, ClouduABIFDSFlags,
CloudABIFDStat, CloudABIFileStat, CloudABIFileType,

View File

@ -218,6 +218,8 @@ static struct syscall decoded_syscalls[] = {
.args = { { Name | IN, 0 }, { Stat | OUT, 1 } } },
{ .name = "lutimes", .ret_type = 1, .nargs = 2,
.args = { { Name | IN, 0 }, { Timeval2 | IN, 1 } } },
{ .name = "madvise", .ret_type = 1, .nargs = 3,
.args = { { Ptr, 0 }, { Sizet, 1 }, { Madvice, 2 } } },
{ .name = "mkdir", .ret_type = 1, .nargs = 2,
.args = { { Name, 0 }, { Octal, 1 } } },
{ .name = "mkdirat", .ret_type = 1, .nargs = 3,
@ -1907,6 +1909,9 @@ print_arg(struct syscall_args *sc, unsigned long *args, long *retval,
print_integer_arg(sysdecode_kldunload_flags, fp,
args[sc->offset]);
break;
case Madvice:
print_integer_arg(sysdecode_madvice, fp, args[sc->offset]);
break;
case CloudABIAdvice:
fputs(xlookup(cloudabi_advice, args[sc->offset]), fp);