github.com/nicocha30/gvisor-ligolo@v0.0.0-20230726075806-989fa2c0a413/pkg/sentry/fsimpl/eventfd/eventfd_state_autogen.go (about) 1 // automatically generated by stateify. 2 3 package eventfd 4 5 import ( 6 "github.com/nicocha30/gvisor-ligolo/pkg/state" 7 ) 8 9 func (efd *EventFileDescription) StateTypeName() string { 10 return "pkg/sentry/fsimpl/eventfd.EventFileDescription" 11 } 12 13 func (efd *EventFileDescription) StateFields() []string { 14 return []string{ 15 "vfsfd", 16 "FileDescriptionDefaultImpl", 17 "DentryMetadataFileDescriptionImpl", 18 "NoLockFD", 19 "queue", 20 "val", 21 "semMode", 22 "hostfd", 23 } 24 } 25 26 func (efd *EventFileDescription) beforeSave() {} 27 28 // +checklocksignore 29 func (efd *EventFileDescription) StateSave(stateSinkObject state.Sink) { 30 efd.beforeSave() 31 stateSinkObject.Save(0, &efd.vfsfd) 32 stateSinkObject.Save(1, &efd.FileDescriptionDefaultImpl) 33 stateSinkObject.Save(2, &efd.DentryMetadataFileDescriptionImpl) 34 stateSinkObject.Save(3, &efd.NoLockFD) 35 stateSinkObject.Save(4, &efd.queue) 36 stateSinkObject.Save(5, &efd.val) 37 stateSinkObject.Save(6, &efd.semMode) 38 stateSinkObject.Save(7, &efd.hostfd) 39 } 40 41 func (efd *EventFileDescription) afterLoad() {} 42 43 // +checklocksignore 44 func (efd *EventFileDescription) StateLoad(stateSourceObject state.Source) { 45 stateSourceObject.Load(0, &efd.vfsfd) 46 stateSourceObject.Load(1, &efd.FileDescriptionDefaultImpl) 47 stateSourceObject.Load(2, &efd.DentryMetadataFileDescriptionImpl) 48 stateSourceObject.Load(3, &efd.NoLockFD) 49 stateSourceObject.Load(4, &efd.queue) 50 stateSourceObject.Load(5, &efd.val) 51 stateSourceObject.Load(6, &efd.semMode) 52 stateSourceObject.Load(7, &efd.hostfd) 53 } 54 55 func init() { 56 state.Register((*EventFileDescription)(nil)) 57 }