aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarco Vanotti <mvanotti@google.com>2018-11-28 15:39:02 -0800
committerDmitry Vyukov <dvyukov@google.com>2018-11-29 21:27:15 +0000
commit66071e276fc06bc4482a4844c0596ede600d0ba3 (patch)
treeefc6c087b0ac642996649e39c605df3ffef09761
parent4b6d14f266bcae8f1856f987c2194f36eadef83b (diff)
sys/fuchsia: fix task syscalls.
This commit fixes two issues related to the task syscalls. The zx_task_resume syscall has been recently removed from zircon[0]. It has been deprecated for some time already. This commit removes the syscall. The `ZX_EXCEPTION_PORT_UNBIND_QUIETLY` option for the syscall `zx_task_bind_exception_port` has been removed recently as well[1]. This commit removes that option from tasks.txt. To test this change, I followed the procedure for building syzkaller for fuchsia: ```shell $ make extract TARGETOS=fuchsia SOURCEDIR=${FUCHSIADIR} $ make generate $ make TARGETOS=fuchsia TARGETARCH=amd64 SOURCEDIR=${FUCHSIADIR} ``` I excluded the changes from make extract. This commit only has the generated files from make generate. [0]: https://fuchsia-review.googlesource.com/c/zircon/+/228712 [1]: https://fuchsia-review.googlesource.com/c/zircon/+/228658
-rw-r--r--executor/defs.h4
-rw-r--r--executor/syscalls.h2
-rw-r--r--sys/fuchsia/gen/amd64.go8
-rw-r--r--sys/fuchsia/gen/arm64.go8
-rw-r--r--sys/fuchsia/tasks.txt4
5 files changed, 7 insertions, 19 deletions
diff --git a/executor/defs.h b/executor/defs.h
index f49920018..a4e90c930 100644
--- a/executor/defs.h
+++ b/executor/defs.h
@@ -35,7 +35,7 @@
#if GOARCH_amd64
#define GOARCH "amd64"
-#define SYZ_REVISION "dd1c90b2481bcb2c9dfb4a2b84b671cb2bf0d196"
+#define SYZ_REVISION "bd572b59fe6577d24e22a364873c5666c1c84b7e"
#define SYZ_EXECUTOR_USES_FORK_SERVER 0
#define SYZ_EXECUTOR_USES_SHMEM 0
#define SYZ_PAGE_SIZE 4096
@@ -45,7 +45,7 @@
#if GOARCH_arm64
#define GOARCH "arm64"
-#define SYZ_REVISION "e947153b4adcbaea981564a646566a4efa8fdffd"
+#define SYZ_REVISION "43822deeef9cd6ecfb711378d529dca12ec20614"
#define SYZ_EXECUTOR_USES_FORK_SERVER 0
#define SYZ_EXECUTOR_USES_SHMEM 0
#define SYZ_PAGE_SIZE 4096
diff --git a/executor/syscalls.h b/executor/syscalls.h
index 63facd3a0..da4128612 100644
--- a/executor/syscalls.h
+++ b/executor/syscalls.h
@@ -867,7 +867,6 @@ const call_t syscalls[] = {
{"zx_system_get_physmem", 0, (syscall_t)zx_system_get_physmem},
{"zx_system_get_version", 0, (syscall_t)zx_system_get_version},
{"zx_task_bind_exception_port", 0, (syscall_t)zx_task_bind_exception_port},
- {"zx_task_resume", 0, (syscall_t)zx_task_resume},
{"zx_thread_create", 0, (syscall_t)zx_thread_create},
{"zx_thread_exit", 0, (syscall_t)zx_thread_exit},
{"zx_thread_read_state", 0, (syscall_t)zx_thread_read_state},
@@ -1286,7 +1285,6 @@ const call_t syscalls[] = {
{"zx_system_get_physmem", 0, (syscall_t)zx_system_get_physmem},
{"zx_system_get_version", 0, (syscall_t)zx_system_get_version},
{"zx_task_bind_exception_port", 0, (syscall_t)zx_task_bind_exception_port},
- {"zx_task_resume", 0, (syscall_t)zx_task_resume},
{"zx_thread_create", 0, (syscall_t)zx_thread_create},
{"zx_thread_exit", 0, (syscall_t)zx_thread_exit},
{"zx_thread_read_state", 0, (syscall_t)zx_thread_read_state},
diff --git a/sys/fuchsia/gen/amd64.go b/sys/fuchsia/gen/amd64.go
index 1291e8cc2..382c5a25c 100644
--- a/sys/fuchsia/gen/amd64.go
+++ b/sys/fuchsia/gen/amd64.go
@@ -6865,11 +6865,7 @@ var syscalls_amd64 = []*Syscall{
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_task", FldName: "task", TypeSize: 4}},
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_port", FldName: "eport", TypeSize: 4}},
&ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "key", TypeSize: 8}}, ValuesStart: 1000, ValuesPerProc: 4},
- &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "exception_port_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{2, 1}, BitMask: true},
- }},
- {Name: "zx_task_resume", CallName: "zx_task_resume", Args: []Type{
- &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_task", FldName: "task", TypeSize: 4}},
- &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "task_resume_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{1, 2}, BitMask: true},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "exception_port_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{1}, BitMask: true},
}},
{Name: "zx_thread_create", CallName: "zx_thread_create", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_process", FldName: "process", TypeSize: 4}},
@@ -7285,4 +7281,4 @@ var consts_amd64 = []ConstValue{
{Name: "fuchsia_power_Status_OK"},
}
-const revision_amd64 = "dd1c90b2481bcb2c9dfb4a2b84b671cb2bf0d196"
+const revision_amd64 = "bd572b59fe6577d24e22a364873c5666c1c84b7e"
diff --git a/sys/fuchsia/gen/arm64.go b/sys/fuchsia/gen/arm64.go
index 162ca7544..139ac5e9a 100644
--- a/sys/fuchsia/gen/arm64.go
+++ b/sys/fuchsia/gen/arm64.go
@@ -6865,11 +6865,7 @@ var syscalls_arm64 = []*Syscall{
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_task", FldName: "task", TypeSize: 4}},
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_port", FldName: "eport", TypeSize: 4}},
&ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "key", TypeSize: 8}}, ValuesStart: 1000, ValuesPerProc: 4},
- &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "exception_port_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{2, 1}, BitMask: true},
- }},
- {Name: "zx_task_resume", CallName: "zx_task_resume", Args: []Type{
- &ResourceType{TypeCommon: TypeCommon{TypeName: "zx_task", FldName: "task", TypeSize: 4}},
- &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "task_resume_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{1, 2}, BitMask: true},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "exception_port_options", FldName: "options", TypeSize: 8}}, Vals: []uint64{1}, BitMask: true},
}},
{Name: "zx_thread_create", CallName: "zx_thread_create", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "zx_process", FldName: "process", TypeSize: 4}},
@@ -7285,4 +7281,4 @@ var consts_arm64 = []ConstValue{
{Name: "fuchsia_power_Status_OK"},
}
-const revision_arm64 = "e947153b4adcbaea981564a646566a4efa8fdffd"
+const revision_arm64 = "43822deeef9cd6ecfb711378d529dca12ec20614"
diff --git a/sys/fuchsia/tasks.txt b/sys/fuchsia/tasks.txt
index 29319a9e2..e42333303 100644
--- a/sys/fuchsia/tasks.txt
+++ b/sys/fuchsia/tasks.txt
@@ -6,11 +6,9 @@ include <zircon/syscalls/exception.h>
resource zx_task[zx_handle]
-zx_task_resume(task zx_task, options flags[task_resume_options])
zx_task_bind_exception_port(task zx_task, eport zx_port, key proc[1000, 4], options flags[exception_port_options])
# This is disabled until we figure out how to prevent executor from killing fuzzer (#594).
# zx_task_kill(handle zx_task)
-task_resume_options = ZX_RESUME_EXCEPTION, ZX_RESUME_TRY_NEXT
-exception_port_options = ZX_EXCEPTION_PORT_UNBIND_QUIETLY, ZX_EXCEPTION_PORT_DEBUGGER
+exception_port_options = ZX_EXCEPTION_PORT_DEBUGGER