summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/kernel/fasync
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/sentry/kernel/fasync')
-rw-r--r--pkg/sentry/kernel/fasync/BUILD18
-rw-r--r--pkg/sentry/kernel/fasync/fasync_state_autogen.go49
2 files changed, 49 insertions, 18 deletions
diff --git a/pkg/sentry/kernel/fasync/BUILD b/pkg/sentry/kernel/fasync/BUILD
deleted file mode 100644
index 2b3955598..000000000
--- a/pkg/sentry/kernel/fasync/BUILD
+++ /dev/null
@@ -1,18 +0,0 @@
-load("//tools:defs.bzl", "go_library")
-
-package(licenses = ["notice"])
-
-go_library(
- name = "fasync",
- srcs = ["fasync.go"],
- visibility = ["//:sandbox"],
- deps = [
- "//pkg/abi/linux",
- "//pkg/sentry/fs",
- "//pkg/sentry/kernel",
- "//pkg/sentry/kernel/auth",
- "//pkg/sentry/vfs",
- "//pkg/sync",
- "//pkg/waiter",
- ],
-)
diff --git a/pkg/sentry/kernel/fasync/fasync_state_autogen.go b/pkg/sentry/kernel/fasync/fasync_state_autogen.go
new file mode 100644
index 000000000..e4a0b5695
--- /dev/null
+++ b/pkg/sentry/kernel/fasync/fasync_state_autogen.go
@@ -0,0 +1,49 @@
+// automatically generated by stateify.
+
+package fasync
+
+import (
+ "gvisor.dev/gvisor/pkg/state"
+)
+
+func (f *FileAsync) StateTypeName() string {
+ return "pkg/sentry/kernel/fasync.FileAsync"
+}
+
+func (f *FileAsync) StateFields() []string {
+ return []string{
+ "e",
+ "requester",
+ "registered",
+ "recipientPG",
+ "recipientTG",
+ "recipientT",
+ }
+}
+
+func (f *FileAsync) beforeSave() {}
+
+func (f *FileAsync) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.e)
+ stateSinkObject.Save(1, &f.requester)
+ stateSinkObject.Save(2, &f.registered)
+ stateSinkObject.Save(3, &f.recipientPG)
+ stateSinkObject.Save(4, &f.recipientTG)
+ stateSinkObject.Save(5, &f.recipientT)
+}
+
+func (f *FileAsync) afterLoad() {}
+
+func (f *FileAsync) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.e)
+ stateSourceObject.Load(1, &f.requester)
+ stateSourceObject.Load(2, &f.registered)
+ stateSourceObject.Load(3, &f.recipientPG)
+ stateSourceObject.Load(4, &f.recipientTG)
+ stateSourceObject.Load(5, &f.recipientT)
+}
+
+func init() {
+ state.Register((*FileAsync)(nil))
+}