Skip to content

Support Firecracker clean teardown - prerequisite for rust sanitizers and/or Valgrind #2599

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jun 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 98 additions & 0 deletions resources/seccomp/aarch64-unknown-linux-musl.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@
"syscall": "rt_sigreturn",
"comment": "rt_sigreturn is needed in case a fault does occur, so that the signal handler can return. Otherwise we get stuck in a fault loop."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "accept4",
"comment": "Called to accept vsock connections",
Expand Down Expand Up @@ -103,6 +107,32 @@
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown when joining multiple vcpu threads at once)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down Expand Up @@ -381,6 +411,14 @@
"syscall": "recvfrom",
"comment": "Used to retrieve data from the socket"
},
{
"syscall": "rt_sigprocmask",
"comment": "rt_sigprocmask is used by Rust stdlib to remove custom signal handler during thread teardown."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "accept4",
"comment": "Called to accept socket connections",
Expand All @@ -394,6 +432,32 @@
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down Expand Up @@ -513,10 +577,44 @@
"syscall": "munmap",
"comment": "Used for freeing memory"
},
{
"syscall": "rt_sigprocmask",
"comment": "rt_sigprocmask is used by Rust stdlib to remove custom signal handler during thread teardown."
},
{
"syscall": "rt_sigreturn",
"comment": "rt_sigreturn is needed in case a fault does occur, so that the signal handler can return. Otherwise we get stuck in a fault loop."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown when joining multiple vcpu threads at once)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down
98 changes: 98 additions & 0 deletions resources/seccomp/x86_64-unknown-linux-musl.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@
"syscall": "rt_sigreturn",
"comment": "rt_sigreturn is needed in case a fault does occur, so that the signal handler can return. Otherwise we get stuck in a fault loop."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "accept4",
"comment": "Called to accept vsock connections",
Expand Down Expand Up @@ -103,6 +107,32 @@
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown when joining multiple vcpu threads at once)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down Expand Up @@ -393,6 +423,14 @@
"syscall": "recvfrom",
"comment": "Used to retrieve data from the socket"
},
{
"syscall": "rt_sigprocmask",
"comment": "rt_sigprocmask is used by Rust stdlib to remove custom signal handler during thread teardown."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "accept4",
"comment": "Called to accept socket connections",
Expand All @@ -406,6 +444,32 @@
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down Expand Up @@ -525,10 +589,44 @@
"syscall": "munmap",
"comment": "Used for freeing memory"
},
{
"syscall": "rt_sigprocmask",
"comment": "rt_sigprocmask is used by Rust stdlib to remove custom signal handler during thread teardown."
},
{
"syscall": "rt_sigreturn",
"comment": "rt_sigreturn is needed in case a fault does occur, so that the signal handler can return. Otherwise we get stuck in a fault loop."
},
{
"syscall": "sigaltstack",
"comment": "sigaltstack is used by Rust stdlib to remove alternative signal stack during thread teardown."
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown when joining multiple vcpu threads at once)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 0,
"comment": "FUTEX_WAIT"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization (during thread teardown)",
"args": [
{
"arg_index": 1,
"arg_type": "dword",
"op": "eq",
"val": 1,
"comment": "FUTEX_WAKE"
}
]
},
{
"syscall": "futex",
"comment": "Used for synchronization",
Expand Down
Loading