Decode flock() operation.

This commit is contained in:
John Baldwin 2017-03-18 18:26:56 +00:00
parent 857129394d
commit dd92181f60
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=315502
2 changed files with 6 additions and 1 deletions

View File

@ -45,7 +45,7 @@ enum Argtype { None = 1, Hex, Octal, Int, UInt, LongHex, Name, Ptr, Stat, Ioctl,
Pathconf, Rforkflags, ExitStatus, Waitoptions, Idtype, Procctl,
LinuxSockArgs, Umtxop, Atfd, Atflags, Timespec2, Accessmode, Long,
Sysarch, ExecArgs, ExecEnv, PipeFds, QuadHex, Utrace, IntArray, Pipe2,
CapFcntlRights, Fadvice, FileFlags,
CapFcntlRights, Fadvice, FileFlags, Flockop,
CloudABIAdvice, CloudABIClockID, ClouduABIFDSFlags,
CloudABIFDStat, CloudABIFileStat, CloudABIFileType,

View File

@ -141,6 +141,8 @@ static struct syscall decoded_syscalls[] = {
{ Atflags, 4 } } },
{ .name = "fcntl", .ret_type = 1, .nargs = 3,
.args = { { Int, 0 }, { Fcntl, 1 }, { Fcntlflag, 2 } } },
{ .name = "flock", .ret_type = 1, .nargs = 2,
.args = { { Int, 0 }, { Flockop, 1 } } },
{ .name = "fstat", .ret_type = 1, .nargs = 2,
.args = { { Int, 0 }, { Stat | OUT, 1 } } },
{ .name = "fstatat", .ret_type = 1, .nargs = 4,
@ -1882,6 +1884,9 @@ print_arg(struct syscall_args *sc, unsigned long *args, long *retval,
fprintf(fp, "|0x%x", rem);
break;
}
case Flockop:
print_mask_arg(sysdecode_flock_operation, fp, args[sc->offset]);
break;
case CloudABIAdvice:
fputs(xlookup(cloudabi_advice, args[sc->offset]), fp);