diff options
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/akaros/gen/amd64.go | 5 | ||||
| -rw-r--r-- | sys/akaros/sys.txt | 2 | ||||
| -rw-r--r-- | sys/freebsd/gen/amd64.go | 5 | ||||
| -rw-r--r-- | sys/freebsd/sys.txt | 2 | ||||
| -rw-r--r-- | sys/fuchsia/gen/amd64.go | 13 | ||||
| -rw-r--r-- | sys/fuchsia/gen/arm64.go | 13 | ||||
| -rw-r--r-- | sys/fuchsia/processes.txt | 2 | ||||
| -rw-r--r-- | sys/fuchsia/sys.txt | 2 | ||||
| -rw-r--r-- | sys/fuchsia/threads.txt | 2 | ||||
| -rw-r--r-- | sys/linux/gen/386.go | 23 | ||||
| -rw-r--r-- | sys/linux/gen/amd64.go | 23 | ||||
| -rw-r--r-- | sys/linux/gen/arm.go | 23 | ||||
| -rw-r--r-- | sys/linux/gen/arm64.go | 23 | ||||
| -rw-r--r-- | sys/linux/gen/ppc64le.go | 23 | ||||
| -rw-r--r-- | sys/linux/sys.txt | 7 | ||||
| -rw-r--r-- | sys/netbsd/gen/amd64.go | 5 | ||||
| -rw-r--r-- | sys/netbsd/sys.txt | 2 | ||||
| -rw-r--r-- | sys/openbsd/gen/amd64.go | 5 | ||||
| -rw-r--r-- | sys/openbsd/sys.txt | 2 | ||||
| -rw-r--r-- | sys/test/gen/32_fork_shmem.go | 5 | ||||
| -rw-r--r-- | sys/test/gen/32_shmem.go | 5 | ||||
| -rw-r--r-- | sys/test/gen/64.go | 13 | ||||
| -rw-r--r-- | sys/test/gen/64_fork.go | 5 | ||||
| -rw-r--r-- | sys/test/test.txt | 2 | ||||
| -rw-r--r-- | sys/windows/gen/amd64.go | 5 | ||||
| -rw-r--r-- | sys/windows/sys.txt | 2 |
26 files changed, 141 insertions, 78 deletions
diff --git a/sys/akaros/gen/amd64.go b/sys/akaros/gen/amd64.go index 52089bc66..36f528698 100644 --- a/sys/akaros/gen/amd64.go +++ b/sys/akaros/gen/amd64.go @@ -1305,6 +1305,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "new_l", TypeSize: 8}}, Buf: "new"}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {NR: 126, Name: "tap_fds", CallName: "tap_fds", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "tap_reqs", TypeSize: 8}, Type: &ArrayType{TypeCommon: TypeCommon{TypeName: "array", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "fd_tap_req"}}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nr_reqs", TypeSize: 8}}, Buf: "tap_reqs"}, @@ -1526,4 +1529,4 @@ var consts_amd64 = []ConstValue{ {Name: "WUNTRACED", Value: 2}, } -const revision_amd64 = "44785e2dac3e0f922841ab905a8c4e7838585083" +const revision_amd64 = "f9824f5b26bc0ee36bc1e6debd6e8a8d6eee33ab" diff --git a/sys/akaros/sys.txt b/sys/akaros/sys.txt index 07fe3609d..c7a02faab 100644 --- a/sys/akaros/sys.txt +++ b/sys/akaros/sys.txt @@ -16,6 +16,8 @@ include <termios.h> resource fd[int32]: 0xffffffffffffffff, AT_FDCWD resource pid[int32]: 0, 0xffffffffffffffff +syz_execute_func(text ptr[in, text[target]]) + openat(fromfd fd[opt], path ptr[in, filename], path_l len[path], oflag flags[open_flags], mode flags[open_mode]) fd read(fd fd, buf buffer[out], count len[buf]) write(fd fd, buf buffer[in], count len[buf]) diff --git a/sys/freebsd/gen/amd64.go b/sys/freebsd/gen/amd64.go index 192053c73..5de2ea7bd 100644 --- a/sys/freebsd/gen/amd64.go +++ b/sys/freebsd/gen/amd64.go @@ -1876,6 +1876,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, }}, {NR: 36, Name: "sync", CallName: "sync"}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {NR: 479, Name: "truncate", CallName: "truncate", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "file", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "len", TypeSize: 8}}}, @@ -2443,4 +2446,4 @@ var consts_amd64 = []ConstValue{ {Name: "WUNTRACED", Value: 2}, } -const revision_amd64 = "89eac40a68a14ffc0af9fc9b181147236b82d00b" +const revision_amd64 = "06d50288c46275b56218cab0097fcb71a7f0f80e" diff --git a/sys/freebsd/sys.txt b/sys/freebsd/sys.txt index 28b486dcd..cf1dd960e 100644 --- a/sys/freebsd/sys.txt +++ b/sys/freebsd/sys.txt @@ -19,6 +19,8 @@ include <sys/wait.h> include <linux/linux.h> include <compat/linux/linux_event.h> +syz_execute_func(text ptr[in, text[target]]) + pipe(pipefd ptr[out, pipefd]) sendfile(fdout fd, fdin fd, off ptr[inout, fileoff[int64], opt], count int64) diff --git a/sys/fuchsia/gen/amd64.go b/sys/fuchsia/gen/amd64.go index d489c9238..421955818 100644 --- a/sys/fuchsia/gen/amd64.go +++ b/sys/fuchsia/gen/amd64.go @@ -1647,6 +1647,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, }}, {Name: "sync", CallName: "sync"}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_future_time", CallName: "syz_future_time", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "when", TypeSize: 8}}, Kind: 2, RangeEnd: 1}, }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_time", FldName: "ret", TypeSize: 8, ArgDir: 1}}}, @@ -2571,8 +2574,8 @@ var syscalls_amd64 = []*Syscall{ {Name: "zx_process_start", CallName: "zx_process_start", Args: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_process", FldName: "process", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_thread", FldName: "thread", TypeSize: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "entry", TypeSize: 8}}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "stack", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "entry", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "stack", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg1", TypeSize: 8}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg2", TypeSize: 8}}}, }}, @@ -2643,8 +2646,8 @@ var syscalls_amd64 = []*Syscall{ }}, {Name: "zx_thread_start", CallName: "zx_thread_start", Args: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_thread", FldName: "handle", TypeSize: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "entry", TypeSize: 8}}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "stack", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "entry", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "stack", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg1", TypeSize: 8}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg2", TypeSize: 8}}}, }}, @@ -2985,4 +2988,4 @@ var consts_amd64 = []ConstValue{ {Name: "fuchsia_io_SeekOrigin_Start"}, } -const revision_amd64 = "2a5cb64c987696cb8bdf1d6d9561c04993cf3299" +const revision_amd64 = "ee62749ce0e69fd29de1864a220e909a18613438" diff --git a/sys/fuchsia/gen/arm64.go b/sys/fuchsia/gen/arm64.go index 460544bab..e6eb6fdb6 100644 --- a/sys/fuchsia/gen/arm64.go +++ b/sys/fuchsia/gen/arm64.go @@ -1647,6 +1647,9 @@ var syscalls_arm64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, }}, {Name: "sync", CallName: "sync"}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_future_time", CallName: "syz_future_time", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "when", TypeSize: 8}}, Kind: 2, RangeEnd: 1}, }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_time", FldName: "ret", TypeSize: 8, ArgDir: 1}}}, @@ -2571,8 +2574,8 @@ var syscalls_arm64 = []*Syscall{ {Name: "zx_process_start", CallName: "zx_process_start", Args: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_process", FldName: "process", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_thread", FldName: "thread", TypeSize: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "entry", TypeSize: 8}}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "stack", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "entry", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "stack", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg1", TypeSize: 8}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg2", TypeSize: 8}}}, }}, @@ -2643,8 +2646,8 @@ var syscalls_arm64 = []*Syscall{ }}, {Name: "zx_thread_start", CallName: "zx_thread_start", Args: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_thread", FldName: "handle", TypeSize: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "entry", TypeSize: 8}}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "stack", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "entry", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "stack", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg1", TypeSize: 8}}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "arg2", TypeSize: 8}}}, }}, @@ -2985,4 +2988,4 @@ var consts_arm64 = []ConstValue{ {Name: "fuchsia_io_SeekOrigin_Start"}, } -const revision_arm64 = "974ef513ae535d2b92308edd342169a59b596cd4" +const revision_arm64 = "80d5b2ce01d8c9deca31efaa1a61da313eaa44e6" diff --git a/sys/fuchsia/processes.txt b/sys/fuchsia/processes.txt index c6f51c3d2..835edbb1e 100644 --- a/sys/fuchsia/processes.txt +++ b/sys/fuchsia/processes.txt @@ -6,7 +6,7 @@ include <zircon/syscalls.h> resource zx_process[zx_task] zx_process_create(job zx_job, name ptr[in, string], name_len len[name], options const[0], proc_handle ptr[out, zx_process], vmar_handle ptr[out, zx_vmar]) -zx_process_start(process zx_process, thread zx_thread, entry intptr, stack intptr, arg1 const[0], arg2 const[0]) +zx_process_start(process zx_process, thread zx_thread, entry ptr[in, text[target]], stack ptr[out, array[int8]], arg1 const[0], arg2 const[0]) zx_process_read_memory(process zx_process, vaddr ptr[out, int8], buffer ptr[out, array[int8]], len len[buffer], actual ptr[out, intptr]) # TODO: temporary disabled as it crashes kernel left and right. # zx_process_write_memory(process zx_process, vaddr ptr[out, int8], buffer ptr[in, array[int8]], len len[buffer], actual ptr[out, intptr]) diff --git a/sys/fuchsia/sys.txt b/sys/fuchsia/sys.txt index 3ed323799..1fb885f03 100644 --- a/sys/fuchsia/sys.txt +++ b/sys/fuchsia/sys.txt @@ -6,6 +6,8 @@ include <zircon/syscalls.h> include <ddk/driver.h> +syz_execute_func(text ptr[in, text[target]]) + # Provided by sysroot (include/ddk/driver.h) resource zx_root_resource[zx_handle] get_root_resource() zx_root_resource diff --git a/sys/fuchsia/threads.txt b/sys/fuchsia/threads.txt index ef4831e03..7947703d9 100644 --- a/sys/fuchsia/threads.txt +++ b/sys/fuchsia/threads.txt @@ -7,7 +7,7 @@ include <zircon/syscalls/debug.h> resource zx_thread[zx_task] zx_thread_create(process zx_process, name ptr[in, string], name_len len[name], options const[0], out ptr[out, zx_thread]) -zx_thread_start(handle zx_thread, entry intptr, stack intptr, arg1 const[0], arg2 const[0]) +zx_thread_start(handle zx_thread, entry ptr[in, text[target]], stack ptr[out, array[int8]], arg1 const[0], arg2 const[0]) zx_thread_exit() # Note: kind corresponds to ZX_THREAD_STATE_REGSET0..9 constants. zx_thread_read_state(handle zx_thread, kind int32[0:9], buffer ptr[out, array[int64]], len bytesize[buffer], actual ptr[out, int32]) diff --git a/sys/linux/gen/386.go b/sys/linux/gen/386.go index c9b1148c4..56fc496f4 100644 --- a/sys/linux/gen/386.go +++ b/sys/linux/gen/386.go @@ -8026,7 +8026,7 @@ var structDescs_386 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_arm64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_arm64", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 5}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86", TypeSize: 12}, Fields: []Type{ @@ -8037,22 +8037,22 @@ var structDescs_386 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_x86_16"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_16", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 16}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_32"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_32", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 32}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_64", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 64}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_real"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_real", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 8}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_tpr_access_ctl"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_tpr_access_ctl", TypeSize: 40}, Fields: []Type{ @@ -16399,18 +16399,18 @@ var structDescs_386 = []*KeyedStruct{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dxferp", TypeSize: 4}, Type: &ArrayType{TypeCommon: TypeCommon{TypeName: "array", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "iovec[out, array[int8]]"}}}}, }}}, {Key: StructKey{Name: "sigaction"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 24}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 4}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, &StructType{Key: StructKey{Name: "sigset"}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 4}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigaction", Dir: 1}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 24, ArgDir: 1}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 4, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, &StructType{Key: StructKey{Name: "sigset", Dir: 1}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 4, ArgDir: 1}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 4, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigevent"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigevent", TypeSize: 64}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "val", TypeSize: 4}}}, @@ -32865,6 +32865,9 @@ var syscalls_386 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "packet", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "eth_packet"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "frags", TypeSize: 4, IsOptional: true}, Type: &StructType{Key: StructKey{Name: "vnet_fragmentation"}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_extract_tcp_res", CallName: "syz_extract_tcp_res", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "res", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "tcp_resources", Dir: 1}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "seq_inc", TypeSize: 4}}}, @@ -40480,4 +40483,4 @@ var consts_386 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_386 = "73c32691841967fea34cade58340298a0a6e34a3" +const revision_386 = "cf409e12bbb8bef7899f39295b0b6d69d318af8d" diff --git a/sys/linux/gen/amd64.go b/sys/linux/gen/amd64.go index a2f69b322..89311786a 100644 --- a/sys/linux/gen/amd64.go +++ b/sys/linux/gen/amd64.go @@ -8141,7 +8141,7 @@ var structDescs_amd64 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_arm64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_arm64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 5}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86", TypeSize: 24}, Fields: []Type{ @@ -8152,22 +8152,22 @@ var structDescs_amd64 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_x86_16"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_16", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 16}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_32"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_32", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 32}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 64}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_real"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_real", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 8}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_tpr_access_ctl"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_tpr_access_ctl", TypeSize: 40}, Fields: []Type{ @@ -16663,16 +16663,16 @@ var structDescs_amd64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "unused2", TypeSize: 8}}}, }}}, {Key: StructKey{Name: "sigaction"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset"}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigaction", Dir: 1}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32, ArgDir: 1}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset", Dir: 1}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8, ArgDir: 1}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigevent"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigevent", TypeSize: 64}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "val", TypeSize: 8}}}, @@ -33534,6 +33534,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "packet", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "eth_packet"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "frags", TypeSize: 8, IsOptional: true}, Type: &StructType{Key: StructKey{Name: "vnet_fragmentation"}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_extract_tcp_res", CallName: "syz_extract_tcp_res", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "res", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "tcp_resources", Dir: 1}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "seq_inc", TypeSize: 4}}}, @@ -41174,4 +41177,4 @@ var consts_amd64 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_amd64 = "26712f7e003ed8690f47cf5edb70bd3eb94766c1" +const revision_amd64 = "3efd822501eed7b0536ca7f8ba2b7720b9f6bab3" diff --git a/sys/linux/gen/arm.go b/sys/linux/gen/arm.go index 154b05117..270ec0ceb 100644 --- a/sys/linux/gen/arm.go +++ b/sys/linux/gen/arm.go @@ -7901,7 +7901,7 @@ var structDescs_arm = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_arm64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_arm64", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 5}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86", TypeSize: 12}, Fields: []Type{ @@ -7912,22 +7912,22 @@ var structDescs_arm = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_x86_16"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_16", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 16}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_32"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_32", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 32}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_64", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 64}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_real"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_real", TypeSize: 12}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 4}}, Val: 8}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 4}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_tpr_access_ctl"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_tpr_access_ctl", TypeSize: 40}, Fields: []Type{ @@ -16280,18 +16280,18 @@ var structDescs_arm = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "unused2", TypeSize: 4}}}, }}}, {Key: StructKey{Name: "sigaction"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 24}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 4}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, &StructType{Key: StructKey{Name: "sigset"}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 4}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigaction", Dir: 1}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 24, ArgDir: 1}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 4, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, &StructType{Key: StructKey{Name: "sigset", Dir: 1}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 4, ArgDir: 1}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 4, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigevent"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigevent", TypeSize: 64}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "val", TypeSize: 4}}}, @@ -32792,6 +32792,9 @@ var syscalls_arm = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "packet", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "eth_packet"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "frags", TypeSize: 4, IsOptional: true}, Type: &StructType{Key: StructKey{Name: "vnet_fragmentation"}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_extract_tcp_res", CallName: "syz_extract_tcp_res", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "res", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "tcp_resources", Dir: 1}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "seq_inc", TypeSize: 4}}}, @@ -40346,4 +40349,4 @@ var consts_arm = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_arm = "f155a0335de7dec3226189d25e230ba9889ff0ef" +const revision_arm = "d64ccba4ff5f75614cce9e04b971a39e735578b2" diff --git a/sys/linux/gen/arm64.go b/sys/linux/gen/arm64.go index 1cb4587bb..d37ef5ba9 100644 --- a/sys/linux/gen/arm64.go +++ b/sys/linux/gen/arm64.go @@ -7999,7 +7999,7 @@ var structDescs_arm64 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_arm64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_arm64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 5}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86", TypeSize: 24}, Fields: []Type{ @@ -8010,22 +8010,22 @@ var structDescs_arm64 = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_x86_16"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_16", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 16}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_32"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_32", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 32}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 64}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_real"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_real", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 8}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_tpr_access_ctl"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_tpr_access_ctl", TypeSize: 40}, Fields: []Type{ @@ -16480,16 +16480,16 @@ var structDescs_arm64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "unused2", TypeSize: 8}}}, }}}, {Key: StructKey{Name: "sigaction"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset"}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigaction", Dir: 1}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32, ArgDir: 1}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset", Dir: 1}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8, ArgDir: 1}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigevent"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigevent", TypeSize: 64}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "val", TypeSize: 8}}}, @@ -33037,6 +33037,9 @@ var syscalls_arm64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "packet", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "eth_packet"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "frags", TypeSize: 8, IsOptional: true}, Type: &StructType{Key: StructKey{Name: "vnet_fragmentation"}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_extract_tcp_res", CallName: "syz_extract_tcp_res", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "res", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "tcp_resources", Dir: 1}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "seq_inc", TypeSize: 4}}}, @@ -40568,4 +40571,4 @@ var consts_arm64 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_arm64 = "1fd22f27ba905dec42b576344dd6c58c011de140" +const revision_arm64 = "33b760e03637540176d75bef5357cc5b147afabe" diff --git a/sys/linux/gen/ppc64le.go b/sys/linux/gen/ppc64le.go index cbfc8f3ec..384002896 100644 --- a/sys/linux/gen/ppc64le.go +++ b/sys/linux/gen/ppc64le.go @@ -7977,7 +7977,7 @@ var structDescs_ppc64le = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_arm64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_arm64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 5}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86", TypeSize: 24}, Fields: []Type{ @@ -7988,22 +7988,22 @@ var structDescs_ppc64le = []*KeyedStruct{ }}}, {Key: StructKey{Name: "kvm_text_x86_16"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_16", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 16}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_32"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_32", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 32}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_64"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_64", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 64}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_text_x86_real"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_text_x86_real", TypeSize: 24}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ", TypeSize: 8}}, Val: 8}, - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "size", TypeSize: 8}}, Buf: "text"}, }}}, {Key: StructKey{Name: "kvm_tpr_access_ctl"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "kvm_tpr_access_ctl", TypeSize: 40}, Fields: []Type{ @@ -16362,16 +16362,16 @@ var structDescs_ppc64le = []*KeyedStruct{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dxferp", TypeSize: 8}, Type: &ArrayType{TypeCommon: TypeCommon{TypeName: "array", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "iovec[out, array[int8]]"}}}}, }}}, {Key: StructKey{Name: "sigaction"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset"}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigaction", Dir: 1}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigaction", TypeSize: 32, ArgDir: 1}, Fields: []Type{ - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "handler", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "handler", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, &StructType{Key: StructKey{Name: "sigset", Dir: 1}, FldName: "mask"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "sigaction_flags", FldName: "flags", TypeSize: 8, ArgDir: 1}}, Vals: []uint64{1, 2, 1073741824, 134217728, 2147483648, 268435456, 4}, BitMask: true}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "restor", TypeSize: 8, ArgDir: 1}}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "restor", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, }}}, {Key: StructKey{Name: "sigevent"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "sigevent", TypeSize: 64}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "val", TypeSize: 8}}}, @@ -31411,6 +31411,9 @@ var syscalls_ppc64le = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "packet", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "eth_packet"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "frags", TypeSize: 8, IsOptional: true}, Type: &StructType{Key: StructKey{Name: "vnet_fragmentation"}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_extract_tcp_res", CallName: "syz_extract_tcp_res", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "res", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "tcp_resources", Dir: 1}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "seq_inc", TypeSize: 4}}}, @@ -37924,4 +37927,4 @@ var consts_ppc64le = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_ppc64le = "cfee5c1892c53b104910906c54ef416def23581b" +const revision_ppc64le = "17f888e873bc99a49d971c80b87ddad7d8291e82" diff --git a/sys/linux/sys.txt b/sys/linux/sys.txt index def19a7bd..cbb9ecbc5 100644 --- a/sys/linux/sys.txt +++ b/sys/linux/sys.txt @@ -60,6 +60,8 @@ resource fd_dir[fd] type signalno int32[0:65] +syz_execute_func(text ptr[in, text[target]]) + open(file ptr[in, filename], flags flags[open_flags], mode flags[open_mode]) fd # Just so that we have something that creates fd_dir resources. open$dir(file ptr[in, filename], flags flags[open_flags], mode flags[open_mode]) fd_dir @@ -734,11 +736,10 @@ rlimit { } sigaction { -# TODO: function pointers need special support - handler intptr + handler ptr[in, text[target]] mask sigset flags flags[sigaction_flags, intptr] - restor intptr + restor ptr[in, text[target]] } tms { diff --git a/sys/netbsd/gen/amd64.go b/sys/netbsd/gen/amd64.go index cd7cdcd03..ece51bee1 100644 --- a/sys/netbsd/gen/amd64.go +++ b/sys/netbsd/gen/amd64.go @@ -1251,6 +1251,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, }}, {NR: 36, Name: "sync", CallName: "sync"}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {NR: 200, Name: "truncate", CallName: "truncate", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "file", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "len", TypeSize: 8}}}, @@ -1677,4 +1680,4 @@ var consts_amd64 = []ConstValue{ {Name: "WUNTRACED", Value: 2}, } -const revision_amd64 = "c05720ceb16e651f6ae9addd1f5be83497d861e3" +const revision_amd64 = "741d8f94955b7b371dee88f03db02ab85d5a9384" diff --git a/sys/netbsd/sys.txt b/sys/netbsd/sys.txt index fd02a09e8..aff757d26 100644 --- a/sys/netbsd/sys.txt +++ b/sys/netbsd/sys.txt @@ -16,6 +16,8 @@ include <time.h> include <signal.h> include <sys/wait.h> +syz_execute_func(text ptr[in, text[target]]) + pipe(pipefd ptr[out, pipefd]) stat(file ptr[in, filename], statbuf ptr[out, stat]) diff --git a/sys/openbsd/gen/amd64.go b/sys/openbsd/gen/amd64.go index 3ecb31c0a..4e7acb920 100644 --- a/sys/openbsd/gen/amd64.go +++ b/sys/openbsd/gen/amd64.go @@ -1456,6 +1456,9 @@ var syscalls_amd64 = []*Syscall{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "new", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, }}, {NR: 36, Name: "sync", CallName: "sync"}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_open_pts", CallName: "syz_open_pts", Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_tty", FldName: "ret", TypeSize: 4, ArgDir: 1}}}, {NR: 200, Name: "truncate", CallName: "truncate", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "file", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "filename", IsVarlen: true}, Kind: 3}}, @@ -1877,4 +1880,4 @@ var consts_amd64 = []ConstValue{ {Name: "WUNTRACED", Value: 2}, } -const revision_amd64 = "f1bde02bbb60bf849ed61dda9a552900891199ef" +const revision_amd64 = "b7a0cb1d6df43d07bd4ab11d2c4b1a2e1c046ac1" diff --git a/sys/openbsd/sys.txt b/sys/openbsd/sys.txt index e071ea9c4..c05a17acf 100644 --- a/sys/openbsd/sys.txt +++ b/sys/openbsd/sys.txt @@ -16,6 +16,8 @@ include <time.h> include <signal.h> include <sys/wait.h> +syz_execute_func(text ptr[in, text[target]]) + pipe(pipefd ptr[out, pipefd]) stat(file ptr[in, filename], statbuf ptr[out, stat]) diff --git a/sys/test/gen/32_fork_shmem.go b/sys/test/gen/32_fork_shmem.go index 4b6fd369e..55a629b00 100644 --- a/sys/test/gen/32_fork_shmem.go +++ b/sys/test/gen/32_fork_shmem.go @@ -38,6 +38,9 @@ var syscalls_32_fork_shmem = []*Syscall{ {Name: "syz_errno", CallName: "syz_errno", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "v", TypeSize: 4}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_mmap", CallName: "syz_mmap", Args: []Type{ &VmaType{TypeCommon: TypeCommon{TypeName: "vma", FldName: "addr", TypeSize: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Buf: "addr"}, @@ -51,4 +54,4 @@ var consts_32_fork_shmem = []ConstValue{ {Name: "ONLY_32BITS_CONST", Value: 1}, } -const revision_32_fork_shmem = "d09983a8bb4f2ccd0e303191862d170b5b636bd8" +const revision_32_fork_shmem = "4225c1e93671306efa6a41958a6d553aed7e8cf7" diff --git a/sys/test/gen/32_shmem.go b/sys/test/gen/32_shmem.go index 2e26dbb58..dfa8a8398 100644 --- a/sys/test/gen/32_shmem.go +++ b/sys/test/gen/32_shmem.go @@ -38,6 +38,9 @@ var syscalls_32_shmem = []*Syscall{ {Name: "syz_errno", CallName: "syz_errno", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "v", TypeSize: 4}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_mmap", CallName: "syz_mmap", Args: []Type{ &VmaType{TypeCommon: TypeCommon{TypeName: "vma", FldName: "addr", TypeSize: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Buf: "addr"}, @@ -51,4 +54,4 @@ var consts_32_shmem = []ConstValue{ {Name: "ONLY_32BITS_CONST", Value: 1}, } -const revision_32_shmem = "8d0f255b4d310c70d0e7d65ac8e5c6c3032a9e14" +const revision_32_shmem = "ae161a1d8e44b101412b6f8d8fdde3a6ce553e55" diff --git a/sys/test/gen/64.go b/sys/test/gen/64.go index 017ad5bda..08fcdd966 100644 --- a/sys/test/gen/64.go +++ b/sys/test/gen/64.go @@ -601,6 +601,9 @@ var syscalls_64 = []*Syscall{ {Name: "syz_errno", CallName: "syz_errno", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "v", TypeSize: 4}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_mmap", CallName: "syz_mmap", Args: []Type{ &VmaType{TypeCommon: TypeCommon{TypeName: "vma", FldName: "addr", TypeSize: 8}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 8}}, Buf: "addr"}, @@ -843,19 +846,19 @@ var syscalls_64 = []*Syscall{ &UnionType{Key: StructKey{Name: "union_arg"}, FldName: "a0"}, }}, {Name: "test$text_x86_16", CallName: "test", Args: []Type{ - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "a1", TypeSize: 8}}, Buf: "a0"}, }}, {Name: "test$text_x86_32", CallName: "test", Args: []Type{ - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 2}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "a1", TypeSize: 8}}, Buf: "a0"}, }}, {Name: "test$text_x86_64", CallName: "test", Args: []Type{ - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 3}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 4}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "a1", TypeSize: 8}}, Buf: "a0"}, }}, {Name: "test$text_x86_real", CallName: "test", Args: []Type{ - &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "a0", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4, Text: 1}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "a1", TypeSize: 8}}, Buf: "a0"}, }}, {Name: "test$type_confusion1", CallName: "test", Args: []Type{ @@ -908,4 +911,4 @@ var consts_64 = []ConstValue{ {Name: "SYS_unsupported"}, } -const revision_64 = "3a71e90e1d9f2ae8b0cbfa9e76a429a74ca2ce90" +const revision_64 = "6ffded136a7c445ee912402759cc9f71c3add37a" diff --git a/sys/test/gen/64_fork.go b/sys/test/gen/64_fork.go index 95171623b..cf1b5beb9 100644 --- a/sys/test/gen/64_fork.go +++ b/sys/test/gen/64_fork.go @@ -38,6 +38,9 @@ var syscalls_64_fork = []*Syscall{ {Name: "syz_errno", CallName: "syz_errno", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "v", TypeSize: 4}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "syz_mmap", CallName: "syz_mmap", Args: []Type{ &VmaType{TypeCommon: TypeCommon{TypeName: "vma", FldName: "addr", TypeSize: 8}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 8}}, Buf: "addr"}, @@ -50,4 +53,4 @@ var consts_64_fork = []ConstValue{ {Name: "IPPROTO_UDP", Value: 17}, } -const revision_64_fork = "39c2288dd1c825ce7a587f946cfc91e0e453cf5e" +const revision_64_fork = "ef850b63cd75f943301e586db069812cc63ac259" diff --git a/sys/test/test.txt b/sys/test/test.txt index 2fef80acb..8a79d5935 100644 --- a/sys/test/test.txt +++ b/sys/test/test.txt @@ -3,6 +3,8 @@ # Syscalls used in syzkaller tests. +syz_execute_func(text ptr[in, text[target]]) + test() # Integer types. diff --git a/sys/windows/gen/amd64.go b/sys/windows/gen/amd64.go index 445fc3d01..04f6ba6bf 100644 --- a/sys/windows/gen/amd64.go +++ b/sys/windows/gen/amd64.go @@ -14272,6 +14272,9 @@ var syscalls_amd64 = []*Syscall{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "type", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "protocol", TypeSize: 4}}}, }}, + {Name: "syz_execute_func", CallName: "syz_execute_func", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "text", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "text", IsVarlen: true}, Kind: 4}}, + }}, {Name: "timeBeginPeriod", CallName: "timeBeginPeriod", Args: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "uPeriod", TypeSize: 4}}}, }}, @@ -14615,4 +14618,4 @@ var consts_amd64 = []ConstValue{ {Name: "WRITE_OWNER", Value: 524288}, } -const revision_amd64 = "f2b48fb82a68b0cb24b2ab9638add66deb9542dd" +const revision_amd64 = "7f58e6832b5d8674b8a77505e6eb0fa213781c23" diff --git a/sys/windows/sys.txt b/sys/windows/sys.txt index 2bbb492ad..a25b3b9c3 100644 --- a/sys/windows/sys.txt +++ b/sys/windows/sys.txt @@ -6,6 +6,8 @@ include <windows.h> resource HANDLE[intptr]: INVALID_HANDLE_VALUE resource hFile[HANDLE] +syz_execute_func(text ptr[in, text[target]]) + CloseHandle(hObject HANDLE) CreateFileA(lpFileName ptr[in, filename], dwDesiredAccess flags[file_access_rights], dwShareMode flags[file_share_mode], lpSecurityAttributes ptr[in, SECURITY_ATTRIBUTES, opt], dwCreationDisposition flags[file_create_disposition], dwFlagsAndAttributes flags[file_attributes], hTemplateFile HANDLE[opt]) hFile VirtualAlloc(lpAddress vma, dwSize len[lpAddress], flAllocationType flags[allocation_type], flProtect flags[protect_flags]) |
