diff options
Diffstat (limited to 'pkg/sentry/fsimpl/signalfd')
-rw-r--r-- | pkg/sentry/fsimpl/signalfd/BUILD | 19 | ||||
-rw-r--r-- | pkg/sentry/fsimpl/signalfd/signalfd_state_autogen.go | 51 |
2 files changed, 51 insertions, 19 deletions
diff --git a/pkg/sentry/fsimpl/signalfd/BUILD b/pkg/sentry/fsimpl/signalfd/BUILD deleted file mode 100644 index adb610213..000000000 --- a/pkg/sentry/fsimpl/signalfd/BUILD +++ /dev/null @@ -1,19 +0,0 @@ -load("//tools:defs.bzl", "go_library") - -package(licenses = ["notice"]) - -go_library( - name = "signalfd", - srcs = ["signalfd.go"], - visibility = ["//pkg/sentry:internal"], - deps = [ - "//pkg/abi/linux", - "//pkg/context", - "//pkg/sentry/kernel", - "//pkg/sentry/vfs", - "//pkg/sync", - "//pkg/syserror", - "//pkg/usermem", - "//pkg/waiter", - ], -) diff --git a/pkg/sentry/fsimpl/signalfd/signalfd_state_autogen.go b/pkg/sentry/fsimpl/signalfd/signalfd_state_autogen.go new file mode 100644 index 000000000..3bf27c6a6 --- /dev/null +++ b/pkg/sentry/fsimpl/signalfd/signalfd_state_autogen.go @@ -0,0 +1,51 @@ +// automatically generated by stateify. + +package signalfd + +import ( + "gvisor.dev/gvisor/pkg/state" +) + +func (sfd *SignalFileDescription) StateTypeName() string { + return "pkg/sentry/fsimpl/signalfd.SignalFileDescription" +} + +func (sfd *SignalFileDescription) StateFields() []string { + return []string{ + "vfsfd", + "FileDescriptionDefaultImpl", + "DentryMetadataFileDescriptionImpl", + "NoLockFD", + "target", + "mask", + } +} + +func (sfd *SignalFileDescription) beforeSave() {} + +// +checklocksignore +func (sfd *SignalFileDescription) StateSave(stateSinkObject state.Sink) { + sfd.beforeSave() + stateSinkObject.Save(0, &sfd.vfsfd) + stateSinkObject.Save(1, &sfd.FileDescriptionDefaultImpl) + stateSinkObject.Save(2, &sfd.DentryMetadataFileDescriptionImpl) + stateSinkObject.Save(3, &sfd.NoLockFD) + stateSinkObject.Save(4, &sfd.target) + stateSinkObject.Save(5, &sfd.mask) +} + +func (sfd *SignalFileDescription) afterLoad() {} + +// +checklocksignore +func (sfd *SignalFileDescription) StateLoad(stateSourceObject state.Source) { + stateSourceObject.Load(0, &sfd.vfsfd) + stateSourceObject.Load(1, &sfd.FileDescriptionDefaultImpl) + stateSourceObject.Load(2, &sfd.DentryMetadataFileDescriptionImpl) + stateSourceObject.Load(3, &sfd.NoLockFD) + stateSourceObject.Load(4, &sfd.target) + stateSourceObject.Load(5, &sfd.mask) +} + +func init() { + state.Register((*SignalFileDescription)(nil)) +} |