diff options
Diffstat (limited to 'pkg/sentry/kernel/fasync')
-rw-r--r-- | pkg/sentry/kernel/fasync/BUILD | 18 | ||||
-rw-r--r-- | pkg/sentry/kernel/fasync/fasync_state_autogen.go | 49 |
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..ac5f4bb54 --- /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 (a *FileAsync) StateTypeName() string { + return "pkg/sentry/kernel/fasync.FileAsync" +} + +func (a *FileAsync) StateFields() []string { + return []string{ + "e", + "requester", + "registered", + "recipientPG", + "recipientTG", + "recipientT", + } +} + +func (a *FileAsync) beforeSave() {} + +func (a *FileAsync) StateSave(stateSinkObject state.Sink) { + a.beforeSave() + stateSinkObject.Save(0, &a.e) + stateSinkObject.Save(1, &a.requester) + stateSinkObject.Save(2, &a.registered) + stateSinkObject.Save(3, &a.recipientPG) + stateSinkObject.Save(4, &a.recipientTG) + stateSinkObject.Save(5, &a.recipientT) +} + +func (a *FileAsync) afterLoad() {} + +func (a *FileAsync) StateLoad(stateSourceObject state.Source) { + stateSourceObject.Load(0, &a.e) + stateSourceObject.Load(1, &a.requester) + stateSourceObject.Load(2, &a.registered) + stateSourceObject.Load(3, &a.recipientPG) + stateSourceObject.Load(4, &a.recipientTG) + stateSourceObject.Load(5, &a.recipientT) +} + +func init() { + state.Register((*FileAsync)(nil)) +} |