summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/fs
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-10-09 19:26:05 +0000
committergVisor bot <gvisor-bot@google.com>2020-10-09 19:26:05 +0000
commit69aa120d401c6d6028aebe4c050cefb4794a60f1 (patch)
tree9b57d56a75d3900b35c7814bf1417057f8fac933 /pkg/sentry/fs
parent578aece760dd47a06a686f82efab5b650807d4c5 (diff)
parent743327817faa1aa46ff3b31f74a0c5c2d047d65a (diff)
Merge release-20200928.0-78-g743327817 (automated)
Diffstat (limited to 'pkg/sentry/fs')
-rw-r--r--pkg/sentry/fs/dev/dev_state_autogen.go18
-rw-r--r--pkg/sentry/fs/fs_state_autogen.go306
-rw-r--r--pkg/sentry/fs/fsutil/fsutil_impl_state_autogen.go198
-rw-r--r--pkg/sentry/fs/fsutil/fsutil_state_autogen.go58
-rw-r--r--pkg/sentry/fs/gofer/gofer_state_autogen.go66
-rw-r--r--pkg/sentry/fs/lock/lock_state_autogen.go92
-rw-r--r--pkg/sentry/fs/proc/proc_state_autogen.go638
-rw-r--r--pkg/sentry/fs/proc/seqfile/seqfile_state_autogen.go18
-rw-r--r--pkg/sentry/fs/ramfs/ramfs_state_autogen.go22
-rw-r--r--pkg/sentry/fs/tty/tty_state_autogen.go148
10 files changed, 782 insertions, 782 deletions
diff --git a/pkg/sentry/fs/dev/dev_state_autogen.go b/pkg/sentry/fs/dev/dev_state_autogen.go
index 09e71c0c8..958ddf698 100644
--- a/pkg/sentry/fs/dev/dev_state_autogen.go
+++ b/pkg/sentry/fs/dev/dev_state_autogen.go
@@ -155,27 +155,27 @@ func (n *nullFileOperations) afterLoad() {}
func (n *nullFileOperations) StateLoad(stateSourceObject state.Source) {
}
-func (z *zeroDevice) StateTypeName() string {
+func (zd *zeroDevice) StateTypeName() string {
return "pkg/sentry/fs/dev.zeroDevice"
}
-func (z *zeroDevice) StateFields() []string {
+func (zd *zeroDevice) StateFields() []string {
return []string{
"nullDevice",
}
}
-func (z *zeroDevice) beforeSave() {}
+func (zd *zeroDevice) beforeSave() {}
-func (z *zeroDevice) StateSave(stateSinkObject state.Sink) {
- z.beforeSave()
- stateSinkObject.Save(0, &z.nullDevice)
+func (zd *zeroDevice) StateSave(stateSinkObject state.Sink) {
+ zd.beforeSave()
+ stateSinkObject.Save(0, &zd.nullDevice)
}
-func (z *zeroDevice) afterLoad() {}
+func (zd *zeroDevice) afterLoad() {}
-func (z *zeroDevice) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &z.nullDevice)
+func (zd *zeroDevice) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &zd.nullDevice)
}
func (z *zeroFileOperations) StateTypeName() string {
diff --git a/pkg/sentry/fs/fs_state_autogen.go b/pkg/sentry/fs/fs_state_autogen.go
index 95df2cad0..667495740 100644
--- a/pkg/sentry/fs/fs_state_autogen.go
+++ b/pkg/sentry/fs/fs_state_autogen.go
@@ -44,11 +44,11 @@ func (s *StableAttr) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(5, &s.DeviceFileMinor)
}
-func (u *UnstableAttr) StateTypeName() string {
+func (ua *UnstableAttr) StateTypeName() string {
return "pkg/sentry/fs.UnstableAttr"
}
-func (u *UnstableAttr) StateFields() []string {
+func (ua *UnstableAttr) StateFields() []string {
return []string{
"Size",
"Usage",
@@ -61,31 +61,31 @@ func (u *UnstableAttr) StateFields() []string {
}
}
-func (u *UnstableAttr) beforeSave() {}
+func (ua *UnstableAttr) beforeSave() {}
-func (u *UnstableAttr) StateSave(stateSinkObject state.Sink) {
- u.beforeSave()
- stateSinkObject.Save(0, &u.Size)
- stateSinkObject.Save(1, &u.Usage)
- stateSinkObject.Save(2, &u.Perms)
- stateSinkObject.Save(3, &u.Owner)
- stateSinkObject.Save(4, &u.AccessTime)
- stateSinkObject.Save(5, &u.ModificationTime)
- stateSinkObject.Save(6, &u.StatusChangeTime)
- stateSinkObject.Save(7, &u.Links)
+func (ua *UnstableAttr) StateSave(stateSinkObject state.Sink) {
+ ua.beforeSave()
+ stateSinkObject.Save(0, &ua.Size)
+ stateSinkObject.Save(1, &ua.Usage)
+ stateSinkObject.Save(2, &ua.Perms)
+ stateSinkObject.Save(3, &ua.Owner)
+ stateSinkObject.Save(4, &ua.AccessTime)
+ stateSinkObject.Save(5, &ua.ModificationTime)
+ stateSinkObject.Save(6, &ua.StatusChangeTime)
+ stateSinkObject.Save(7, &ua.Links)
}
-func (u *UnstableAttr) afterLoad() {}
+func (ua *UnstableAttr) afterLoad() {}
-func (u *UnstableAttr) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &u.Size)
- stateSourceObject.Load(1, &u.Usage)
- stateSourceObject.Load(2, &u.Perms)
- stateSourceObject.Load(3, &u.Owner)
- stateSourceObject.Load(4, &u.AccessTime)
- stateSourceObject.Load(5, &u.ModificationTime)
- stateSourceObject.Load(6, &u.StatusChangeTime)
- stateSourceObject.Load(7, &u.Links)
+func (ua *UnstableAttr) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &ua.Size)
+ stateSourceObject.Load(1, &ua.Usage)
+ stateSourceObject.Load(2, &ua.Perms)
+ stateSourceObject.Load(3, &ua.Owner)
+ stateSourceObject.Load(4, &ua.AccessTime)
+ stateSourceObject.Load(5, &ua.ModificationTime)
+ stateSourceObject.Load(6, &ua.StatusChangeTime)
+ stateSourceObject.Load(7, &ua.Links)
}
func (a *AttrMask) StateTypeName() string {
@@ -334,36 +334,36 @@ func (d *Dirent) StateLoad(stateSourceObject state.Source) {
stateSourceObject.AfterLoad(d.afterLoad)
}
-func (d *DirentCache) StateTypeName() string {
+func (c *DirentCache) StateTypeName() string {
return "pkg/sentry/fs.DirentCache"
}
-func (d *DirentCache) StateFields() []string {
+func (c *DirentCache) StateFields() []string {
return []string{
"maxSize",
"limit",
}
}
-func (d *DirentCache) beforeSave() {}
+func (c *DirentCache) beforeSave() {}
-func (d *DirentCache) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- if !state.IsZeroValue(&d.currentSize) {
- state.Failf("currentSize is %#v, expected zero", &d.currentSize)
+func (c *DirentCache) StateSave(stateSinkObject state.Sink) {
+ c.beforeSave()
+ if !state.IsZeroValue(&c.currentSize) {
+ state.Failf("currentSize is %#v, expected zero", &c.currentSize)
}
- if !state.IsZeroValue(&d.list) {
- state.Failf("list is %#v, expected zero", &d.list)
+ if !state.IsZeroValue(&c.list) {
+ state.Failf("list is %#v, expected zero", &c.list)
}
- stateSinkObject.Save(0, &d.maxSize)
- stateSinkObject.Save(1, &d.limit)
+ stateSinkObject.Save(0, &c.maxSize)
+ stateSinkObject.Save(1, &c.limit)
}
-func (d *DirentCache) afterLoad() {}
+func (c *DirentCache) afterLoad() {}
-func (d *DirentCache) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.maxSize)
- stateSourceObject.Load(1, &d.limit)
+func (c *DirentCache) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &c.maxSize)
+ stateSourceObject.Load(1, &c.limit)
}
func (d *DirentCacheLimiter) StateTypeName() string {
@@ -392,82 +392,82 @@ func (d *DirentCacheLimiter) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(0, &d.max)
}
-func (d *direntList) StateTypeName() string {
+func (l *direntList) StateTypeName() string {
return "pkg/sentry/fs.direntList"
}
-func (d *direntList) StateFields() []string {
+func (l *direntList) StateFields() []string {
return []string{
"head",
"tail",
}
}
-func (d *direntList) beforeSave() {}
+func (l *direntList) beforeSave() {}
-func (d *direntList) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- stateSinkObject.Save(0, &d.head)
- stateSinkObject.Save(1, &d.tail)
+func (l *direntList) StateSave(stateSinkObject state.Sink) {
+ l.beforeSave()
+ stateSinkObject.Save(0, &l.head)
+ stateSinkObject.Save(1, &l.tail)
}
-func (d *direntList) afterLoad() {}
+func (l *direntList) afterLoad() {}
-func (d *direntList) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.head)
- stateSourceObject.Load(1, &d.tail)
+func (l *direntList) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &l.head)
+ stateSourceObject.Load(1, &l.tail)
}
-func (d *direntEntry) StateTypeName() string {
+func (e *direntEntry) StateTypeName() string {
return "pkg/sentry/fs.direntEntry"
}
-func (d *direntEntry) StateFields() []string {
+func (e *direntEntry) StateFields() []string {
return []string{
"next",
"prev",
}
}
-func (d *direntEntry) beforeSave() {}
+func (e *direntEntry) beforeSave() {}
-func (d *direntEntry) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- stateSinkObject.Save(0, &d.next)
- stateSinkObject.Save(1, &d.prev)
+func (e *direntEntry) StateSave(stateSinkObject state.Sink) {
+ e.beforeSave()
+ stateSinkObject.Save(0, &e.next)
+ stateSinkObject.Save(1, &e.prev)
}
-func (d *direntEntry) afterLoad() {}
+func (e *direntEntry) afterLoad() {}
-func (d *direntEntry) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.next)
- stateSourceObject.Load(1, &d.prev)
+func (e *direntEntry) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &e.next)
+ stateSourceObject.Load(1, &e.prev)
}
-func (e *eventList) StateTypeName() string {
+func (l *eventList) StateTypeName() string {
return "pkg/sentry/fs.eventList"
}
-func (e *eventList) StateFields() []string {
+func (l *eventList) StateFields() []string {
return []string{
"head",
"tail",
}
}
-func (e *eventList) beforeSave() {}
+func (l *eventList) beforeSave() {}
-func (e *eventList) StateSave(stateSinkObject state.Sink) {
- e.beforeSave()
- stateSinkObject.Save(0, &e.head)
- stateSinkObject.Save(1, &e.tail)
+func (l *eventList) StateSave(stateSinkObject state.Sink) {
+ l.beforeSave()
+ stateSinkObject.Save(0, &l.head)
+ stateSinkObject.Save(1, &l.tail)
}
-func (e *eventList) afterLoad() {}
+func (l *eventList) afterLoad() {}
-func (e *eventList) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &e.head)
- stateSourceObject.Load(1, &e.tail)
+func (l *eventList) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &l.head)
+ stateSourceObject.Load(1, &l.tail)
}
func (e *eventEntry) StateTypeName() string {
@@ -534,11 +534,11 @@ func (f *File) StateLoad(stateSourceObject state.Source) {
stateSourceObject.AfterLoad(f.afterLoad)
}
-func (o *overlayFileOperations) StateTypeName() string {
+func (f *overlayFileOperations) StateTypeName() string {
return "pkg/sentry/fs.overlayFileOperations"
}
-func (o *overlayFileOperations) StateFields() []string {
+func (f *overlayFileOperations) StateFields() []string {
return []string{
"upper",
"lower",
@@ -546,28 +546,28 @@ func (o *overlayFileOperations) StateFields() []string {
}
}
-func (o *overlayFileOperations) beforeSave() {}
+func (f *overlayFileOperations) beforeSave() {}
-func (o *overlayFileOperations) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
- stateSinkObject.Save(0, &o.upper)
- stateSinkObject.Save(1, &o.lower)
- stateSinkObject.Save(2, &o.dirCursor)
+func (f *overlayFileOperations) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.upper)
+ stateSinkObject.Save(1, &f.lower)
+ stateSinkObject.Save(2, &f.dirCursor)
}
-func (o *overlayFileOperations) afterLoad() {}
+func (f *overlayFileOperations) afterLoad() {}
-func (o *overlayFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &o.upper)
- stateSourceObject.Load(1, &o.lower)
- stateSourceObject.Load(2, &o.dirCursor)
+func (f *overlayFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.upper)
+ stateSourceObject.Load(1, &f.lower)
+ stateSourceObject.Load(2, &f.dirCursor)
}
-func (o *overlayMappingIdentity) StateTypeName() string {
+func (omi *overlayMappingIdentity) StateTypeName() string {
return "pkg/sentry/fs.overlayMappingIdentity"
}
-func (o *overlayMappingIdentity) StateFields() []string {
+func (omi *overlayMappingIdentity) StateFields() []string {
return []string{
"AtomicRefCount",
"id",
@@ -575,21 +575,21 @@ func (o *overlayMappingIdentity) StateFields() []string {
}
}
-func (o *overlayMappingIdentity) beforeSave() {}
+func (omi *overlayMappingIdentity) beforeSave() {}
-func (o *overlayMappingIdentity) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
- stateSinkObject.Save(0, &o.AtomicRefCount)
- stateSinkObject.Save(1, &o.id)
- stateSinkObject.Save(2, &o.overlayFile)
+func (omi *overlayMappingIdentity) StateSave(stateSinkObject state.Sink) {
+ omi.beforeSave()
+ stateSinkObject.Save(0, &omi.AtomicRefCount)
+ stateSinkObject.Save(1, &omi.id)
+ stateSinkObject.Save(2, &omi.overlayFile)
}
-func (o *overlayMappingIdentity) afterLoad() {}
+func (omi *overlayMappingIdentity) afterLoad() {}
-func (o *overlayMappingIdentity) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &o.AtomicRefCount)
- stateSourceObject.Load(1, &o.id)
- stateSourceObject.Load(2, &o.overlayFile)
+func (omi *overlayMappingIdentity) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &omi.AtomicRefCount)
+ stateSourceObject.Load(1, &omi.id)
+ stateSourceObject.Load(2, &omi.overlayFile)
}
func (m *MountSourceFlags) StateTypeName() string {
@@ -890,11 +890,11 @@ func (w *Watch) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(5, &w.pins)
}
-func (m *MountSource) StateTypeName() string {
+func (msrc *MountSource) StateTypeName() string {
return "pkg/sentry/fs.MountSource"
}
-func (m *MountSource) StateFields() []string {
+func (msrc *MountSource) StateFields() []string {
return []string{
"AtomicRefCount",
"MountSourceOperations",
@@ -905,34 +905,34 @@ func (m *MountSource) StateFields() []string {
}
}
-func (m *MountSource) beforeSave() {}
+func (msrc *MountSource) beforeSave() {}
-func (m *MountSource) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.AtomicRefCount)
- stateSinkObject.Save(1, &m.MountSourceOperations)
- stateSinkObject.Save(2, &m.FilesystemType)
- stateSinkObject.Save(3, &m.Flags)
- stateSinkObject.Save(4, &m.fscache)
- stateSinkObject.Save(5, &m.direntRefs)
+func (msrc *MountSource) StateSave(stateSinkObject state.Sink) {
+ msrc.beforeSave()
+ stateSinkObject.Save(0, &msrc.AtomicRefCount)
+ stateSinkObject.Save(1, &msrc.MountSourceOperations)
+ stateSinkObject.Save(2, &msrc.FilesystemType)
+ stateSinkObject.Save(3, &msrc.Flags)
+ stateSinkObject.Save(4, &msrc.fscache)
+ stateSinkObject.Save(5, &msrc.direntRefs)
}
-func (m *MountSource) afterLoad() {}
+func (msrc *MountSource) afterLoad() {}
-func (m *MountSource) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.AtomicRefCount)
- stateSourceObject.Load(1, &m.MountSourceOperations)
- stateSourceObject.Load(2, &m.FilesystemType)
- stateSourceObject.Load(3, &m.Flags)
- stateSourceObject.Load(4, &m.fscache)
- stateSourceObject.Load(5, &m.direntRefs)
+func (msrc *MountSource) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &msrc.AtomicRefCount)
+ stateSourceObject.Load(1, &msrc.MountSourceOperations)
+ stateSourceObject.Load(2, &msrc.FilesystemType)
+ stateSourceObject.Load(3, &msrc.Flags)
+ stateSourceObject.Load(4, &msrc.fscache)
+ stateSourceObject.Load(5, &msrc.direntRefs)
}
-func (s *SimpleMountSourceOperations) StateTypeName() string {
+func (smo *SimpleMountSourceOperations) StateTypeName() string {
return "pkg/sentry/fs.SimpleMountSourceOperations"
}
-func (s *SimpleMountSourceOperations) StateFields() []string {
+func (smo *SimpleMountSourceOperations) StateFields() []string {
return []string{
"keep",
"revalidate",
@@ -940,21 +940,21 @@ func (s *SimpleMountSourceOperations) StateFields() []string {
}
}
-func (s *SimpleMountSourceOperations) beforeSave() {}
+func (smo *SimpleMountSourceOperations) beforeSave() {}
-func (s *SimpleMountSourceOperations) StateSave(stateSinkObject state.Sink) {
- s.beforeSave()
- stateSinkObject.Save(0, &s.keep)
- stateSinkObject.Save(1, &s.revalidate)
- stateSinkObject.Save(2, &s.cacheReaddir)
+func (smo *SimpleMountSourceOperations) StateSave(stateSinkObject state.Sink) {
+ smo.beforeSave()
+ stateSinkObject.Save(0, &smo.keep)
+ stateSinkObject.Save(1, &smo.revalidate)
+ stateSinkObject.Save(2, &smo.cacheReaddir)
}
-func (s *SimpleMountSourceOperations) afterLoad() {}
+func (smo *SimpleMountSourceOperations) afterLoad() {}
-func (s *SimpleMountSourceOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &s.keep)
- stateSourceObject.Load(1, &s.revalidate)
- stateSourceObject.Load(2, &s.cacheReaddir)
+func (smo *SimpleMountSourceOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &smo.keep)
+ stateSourceObject.Load(1, &smo.revalidate)
+ stateSourceObject.Load(2, &smo.cacheReaddir)
}
func (o *overlayMountSourceOperations) StateTypeName() string {
@@ -983,23 +983,23 @@ func (o *overlayMountSourceOperations) StateLoad(stateSourceObject state.Source)
stateSourceObject.Load(1, &o.lower)
}
-func (o *overlayFilesystem) StateTypeName() string {
+func (ofs *overlayFilesystem) StateTypeName() string {
return "pkg/sentry/fs.overlayFilesystem"
}
-func (o *overlayFilesystem) StateFields() []string {
+func (ofs *overlayFilesystem) StateFields() []string {
return []string{}
}
-func (o *overlayFilesystem) beforeSave() {}
+func (ofs *overlayFilesystem) beforeSave() {}
-func (o *overlayFilesystem) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
+func (ofs *overlayFilesystem) StateSave(stateSinkObject state.Sink) {
+ ofs.beforeSave()
}
-func (o *overlayFilesystem) afterLoad() {}
+func (ofs *overlayFilesystem) afterLoad() {}
-func (o *overlayFilesystem) StateLoad(stateSourceObject state.Source) {
+func (ofs *overlayFilesystem) StateLoad(stateSourceObject state.Source) {
}
func (m *Mount) StateTypeName() string {
@@ -1034,11 +1034,11 @@ func (m *Mount) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(3, &m.previous)
}
-func (m *MountNamespace) StateTypeName() string {
+func (mns *MountNamespace) StateTypeName() string {
return "pkg/sentry/fs.MountNamespace"
}
-func (m *MountNamespace) StateFields() []string {
+func (mns *MountNamespace) StateFields() []string {
return []string{
"AtomicRefCount",
"userns",
@@ -1048,25 +1048,25 @@ func (m *MountNamespace) StateFields() []string {
}
}
-func (m *MountNamespace) beforeSave() {}
+func (mns *MountNamespace) beforeSave() {}
-func (m *MountNamespace) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.AtomicRefCount)
- stateSinkObject.Save(1, &m.userns)
- stateSinkObject.Save(2, &m.root)
- stateSinkObject.Save(3, &m.mounts)
- stateSinkObject.Save(4, &m.mountID)
+func (mns *MountNamespace) StateSave(stateSinkObject state.Sink) {
+ mns.beforeSave()
+ stateSinkObject.Save(0, &mns.AtomicRefCount)
+ stateSinkObject.Save(1, &mns.userns)
+ stateSinkObject.Save(2, &mns.root)
+ stateSinkObject.Save(3, &mns.mounts)
+ stateSinkObject.Save(4, &mns.mountID)
}
-func (m *MountNamespace) afterLoad() {}
+func (mns *MountNamespace) afterLoad() {}
-func (m *MountNamespace) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.AtomicRefCount)
- stateSourceObject.Load(1, &m.userns)
- stateSourceObject.Load(2, &m.root)
- stateSourceObject.Load(3, &m.mounts)
- stateSourceObject.Load(4, &m.mountID)
+func (mns *MountNamespace) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &mns.AtomicRefCount)
+ stateSourceObject.Load(1, &mns.userns)
+ stateSourceObject.Load(2, &mns.root)
+ stateSourceObject.Load(3, &mns.mounts)
+ stateSourceObject.Load(4, &mns.mountID)
}
func (o *overlayEntry) StateTypeName() string {
diff --git a/pkg/sentry/fs/fsutil/fsutil_impl_state_autogen.go b/pkg/sentry/fs/fsutil/fsutil_impl_state_autogen.go
index 4d90bd42f..cb6b2ca81 100644
--- a/pkg/sentry/fs/fsutil/fsutil_impl_state_autogen.go
+++ b/pkg/sentry/fs/fsutil/fsutil_impl_state_autogen.go
@@ -6,35 +6,35 @@ import (
"gvisor.dev/gvisor/pkg/state"
)
-func (d *DirtySet) StateTypeName() string {
+func (s *DirtySet) StateTypeName() string {
return "pkg/sentry/fs/fsutil.DirtySet"
}
-func (d *DirtySet) StateFields() []string {
+func (s *DirtySet) StateFields() []string {
return []string{
"root",
}
}
-func (d *DirtySet) beforeSave() {}
+func (s *DirtySet) beforeSave() {}
-func (d *DirtySet) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- var rootValue *DirtySegmentDataSlices = d.saveRoot()
+func (s *DirtySet) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ var rootValue *DirtySegmentDataSlices = s.saveRoot()
stateSinkObject.SaveValue(0, rootValue)
}
-func (d *DirtySet) afterLoad() {}
+func (s *DirtySet) afterLoad() {}
-func (d *DirtySet) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.LoadValue(0, new(*DirtySegmentDataSlices), func(y interface{}) { d.loadRoot(y.(*DirtySegmentDataSlices)) })
+func (s *DirtySet) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.LoadValue(0, new(*DirtySegmentDataSlices), func(y interface{}) { s.loadRoot(y.(*DirtySegmentDataSlices)) })
}
-func (d *Dirtynode) StateTypeName() string {
+func (n *Dirtynode) StateTypeName() string {
return "pkg/sentry/fs/fsutil.Dirtynode"
}
-func (d *Dirtynode) StateFields() []string {
+func (n *Dirtynode) StateFields() []string {
return []string{
"nrSegments",
"parent",
@@ -47,31 +47,31 @@ func (d *Dirtynode) StateFields() []string {
}
}
-func (d *Dirtynode) beforeSave() {}
+func (n *Dirtynode) beforeSave() {}
-func (d *Dirtynode) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- stateSinkObject.Save(0, &d.nrSegments)
- stateSinkObject.Save(1, &d.parent)
- stateSinkObject.Save(2, &d.parentIndex)
- stateSinkObject.Save(3, &d.hasChildren)
- stateSinkObject.Save(4, &d.maxGap)
- stateSinkObject.Save(5, &d.keys)
- stateSinkObject.Save(6, &d.values)
- stateSinkObject.Save(7, &d.children)
+func (n *Dirtynode) StateSave(stateSinkObject state.Sink) {
+ n.beforeSave()
+ stateSinkObject.Save(0, &n.nrSegments)
+ stateSinkObject.Save(1, &n.parent)
+ stateSinkObject.Save(2, &n.parentIndex)
+ stateSinkObject.Save(3, &n.hasChildren)
+ stateSinkObject.Save(4, &n.maxGap)
+ stateSinkObject.Save(5, &n.keys)
+ stateSinkObject.Save(6, &n.values)
+ stateSinkObject.Save(7, &n.children)
}
-func (d *Dirtynode) afterLoad() {}
+func (n *Dirtynode) afterLoad() {}
-func (d *Dirtynode) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.nrSegments)
- stateSourceObject.Load(1, &d.parent)
- stateSourceObject.Load(2, &d.parentIndex)
- stateSourceObject.Load(3, &d.hasChildren)
- stateSourceObject.Load(4, &d.maxGap)
- stateSourceObject.Load(5, &d.keys)
- stateSourceObject.Load(6, &d.values)
- stateSourceObject.Load(7, &d.children)
+func (n *Dirtynode) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &n.nrSegments)
+ stateSourceObject.Load(1, &n.parent)
+ stateSourceObject.Load(2, &n.parentIndex)
+ stateSourceObject.Load(3, &n.hasChildren)
+ stateSourceObject.Load(4, &n.maxGap)
+ stateSourceObject.Load(5, &n.keys)
+ stateSourceObject.Load(6, &n.values)
+ stateSourceObject.Load(7, &n.children)
}
func (d *DirtySegmentDataSlices) StateTypeName() string {
@@ -103,35 +103,35 @@ func (d *DirtySegmentDataSlices) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(2, &d.Values)
}
-func (f *FileRangeSet) StateTypeName() string {
+func (s *FileRangeSet) StateTypeName() string {
return "pkg/sentry/fs/fsutil.FileRangeSet"
}
-func (f *FileRangeSet) StateFields() []string {
+func (s *FileRangeSet) StateFields() []string {
return []string{
"root",
}
}
-func (f *FileRangeSet) beforeSave() {}
+func (s *FileRangeSet) beforeSave() {}
-func (f *FileRangeSet) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- var rootValue *FileRangeSegmentDataSlices = f.saveRoot()
+func (s *FileRangeSet) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ var rootValue *FileRangeSegmentDataSlices = s.saveRoot()
stateSinkObject.SaveValue(0, rootValue)
}
-func (f *FileRangeSet) afterLoad() {}
+func (s *FileRangeSet) afterLoad() {}
-func (f *FileRangeSet) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.LoadValue(0, new(*FileRangeSegmentDataSlices), func(y interface{}) { f.loadRoot(y.(*FileRangeSegmentDataSlices)) })
+func (s *FileRangeSet) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.LoadValue(0, new(*FileRangeSegmentDataSlices), func(y interface{}) { s.loadRoot(y.(*FileRangeSegmentDataSlices)) })
}
-func (f *FileRangenode) StateTypeName() string {
+func (n *FileRangenode) StateTypeName() string {
return "pkg/sentry/fs/fsutil.FileRangenode"
}
-func (f *FileRangenode) StateFields() []string {
+func (n *FileRangenode) StateFields() []string {
return []string{
"nrSegments",
"parent",
@@ -144,31 +144,31 @@ func (f *FileRangenode) StateFields() []string {
}
}
-func (f *FileRangenode) beforeSave() {}
+func (n *FileRangenode) beforeSave() {}
-func (f *FileRangenode) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- stateSinkObject.Save(0, &f.nrSegments)
- stateSinkObject.Save(1, &f.parent)
- stateSinkObject.Save(2, &f.parentIndex)
- stateSinkObject.Save(3, &f.hasChildren)
- stateSinkObject.Save(4, &f.maxGap)
- stateSinkObject.Save(5, &f.keys)
- stateSinkObject.Save(6, &f.values)
- stateSinkObject.Save(7, &f.children)
+func (n *FileRangenode) StateSave(stateSinkObject state.Sink) {
+ n.beforeSave()
+ stateSinkObject.Save(0, &n.nrSegments)
+ stateSinkObject.Save(1, &n.parent)
+ stateSinkObject.Save(2, &n.parentIndex)
+ stateSinkObject.Save(3, &n.hasChildren)
+ stateSinkObject.Save(4, &n.maxGap)
+ stateSinkObject.Save(5, &n.keys)
+ stateSinkObject.Save(6, &n.values)
+ stateSinkObject.Save(7, &n.children)
}
-func (f *FileRangenode) afterLoad() {}
+func (n *FileRangenode) afterLoad() {}
-func (f *FileRangenode) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &f.nrSegments)
- stateSourceObject.Load(1, &f.parent)
- stateSourceObject.Load(2, &f.parentIndex)
- stateSourceObject.Load(3, &f.hasChildren)
- stateSourceObject.Load(4, &f.maxGap)
- stateSourceObject.Load(5, &f.keys)
- stateSourceObject.Load(6, &f.values)
- stateSourceObject.Load(7, &f.children)
+func (n *FileRangenode) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &n.nrSegments)
+ stateSourceObject.Load(1, &n.parent)
+ stateSourceObject.Load(2, &n.parentIndex)
+ stateSourceObject.Load(3, &n.hasChildren)
+ stateSourceObject.Load(4, &n.maxGap)
+ stateSourceObject.Load(5, &n.keys)
+ stateSourceObject.Load(6, &n.values)
+ stateSourceObject.Load(7, &n.children)
}
func (f *FileRangeSegmentDataSlices) StateTypeName() string {
@@ -200,35 +200,35 @@ func (f *FileRangeSegmentDataSlices) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(2, &f.Values)
}
-func (f *FrameRefSet) StateTypeName() string {
+func (s *FrameRefSet) StateTypeName() string {
return "pkg/sentry/fs/fsutil.FrameRefSet"
}
-func (f *FrameRefSet) StateFields() []string {
+func (s *FrameRefSet) StateFields() []string {
return []string{
"root",
}
}
-func (f *FrameRefSet) beforeSave() {}
+func (s *FrameRefSet) beforeSave() {}
-func (f *FrameRefSet) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- var rootValue *FrameRefSegmentDataSlices = f.saveRoot()
+func (s *FrameRefSet) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ var rootValue *FrameRefSegmentDataSlices = s.saveRoot()
stateSinkObject.SaveValue(0, rootValue)
}
-func (f *FrameRefSet) afterLoad() {}
+func (s *FrameRefSet) afterLoad() {}
-func (f *FrameRefSet) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.LoadValue(0, new(*FrameRefSegmentDataSlices), func(y interface{}) { f.loadRoot(y.(*FrameRefSegmentDataSlices)) })
+func (s *FrameRefSet) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.LoadValue(0, new(*FrameRefSegmentDataSlices), func(y interface{}) { s.loadRoot(y.(*FrameRefSegmentDataSlices)) })
}
-func (f *FrameRefnode) StateTypeName() string {
+func (n *FrameRefnode) StateTypeName() string {
return "pkg/sentry/fs/fsutil.FrameRefnode"
}
-func (f *FrameRefnode) StateFields() []string {
+func (n *FrameRefnode) StateFields() []string {
return []string{
"nrSegments",
"parent",
@@ -241,31 +241,31 @@ func (f *FrameRefnode) StateFields() []string {
}
}
-func (f *FrameRefnode) beforeSave() {}
+func (n *FrameRefnode) beforeSave() {}
-func (f *FrameRefnode) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- stateSinkObject.Save(0, &f.nrSegments)
- stateSinkObject.Save(1, &f.parent)
- stateSinkObject.Save(2, &f.parentIndex)
- stateSinkObject.Save(3, &f.hasChildren)
- stateSinkObject.Save(4, &f.maxGap)
- stateSinkObject.Save(5, &f.keys)
- stateSinkObject.Save(6, &f.values)
- stateSinkObject.Save(7, &f.children)
-}
-
-func (f *FrameRefnode) afterLoad() {}
-
-func (f *FrameRefnode) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &f.nrSegments)
- stateSourceObject.Load(1, &f.parent)
- stateSourceObject.Load(2, &f.parentIndex)
- stateSourceObject.Load(3, &f.hasChildren)
- stateSourceObject.Load(4, &f.maxGap)
- stateSourceObject.Load(5, &f.keys)
- stateSourceObject.Load(6, &f.values)
- stateSourceObject.Load(7, &f.children)
+func (n *FrameRefnode) StateSave(stateSinkObject state.Sink) {
+ n.beforeSave()
+ stateSinkObject.Save(0, &n.nrSegments)
+ stateSinkObject.Save(1, &n.parent)
+ stateSinkObject.Save(2, &n.parentIndex)
+ stateSinkObject.Save(3, &n.hasChildren)
+ stateSinkObject.Save(4, &n.maxGap)
+ stateSinkObject.Save(5, &n.keys)
+ stateSinkObject.Save(6, &n.values)
+ stateSinkObject.Save(7, &n.children)
+}
+
+func (n *FrameRefnode) afterLoad() {}
+
+func (n *FrameRefnode) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &n.nrSegments)
+ stateSourceObject.Load(1, &n.parent)
+ stateSourceObject.Load(2, &n.parentIndex)
+ stateSourceObject.Load(3, &n.hasChildren)
+ stateSourceObject.Load(4, &n.maxGap)
+ stateSourceObject.Load(5, &n.keys)
+ stateSourceObject.Load(6, &n.values)
+ stateSourceObject.Load(7, &n.children)
}
func (f *FrameRefSegmentDataSlices) StateTypeName() string {
diff --git a/pkg/sentry/fs/fsutil/fsutil_state_autogen.go b/pkg/sentry/fs/fsutil/fsutil_state_autogen.go
index 43016f689..439ab9a65 100644
--- a/pkg/sentry/fs/fsutil/fsutil_state_autogen.go
+++ b/pkg/sentry/fs/fsutil/fsutil_state_autogen.go
@@ -29,30 +29,30 @@ func (d *DirtyInfo) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(0, &d.Keep)
}
-func (s *StaticDirFileOperations) StateTypeName() string {
+func (sdfo *StaticDirFileOperations) StateTypeName() string {
return "pkg/sentry/fs/fsutil.StaticDirFileOperations"
}
-func (s *StaticDirFileOperations) StateFields() []string {
+func (sdfo *StaticDirFileOperations) StateFields() []string {
return []string{
"dentryMap",
"dirCursor",
}
}
-func (s *StaticDirFileOperations) beforeSave() {}
+func (sdfo *StaticDirFileOperations) beforeSave() {}
-func (s *StaticDirFileOperations) StateSave(stateSinkObject state.Sink) {
- s.beforeSave()
- stateSinkObject.Save(0, &s.dentryMap)
- stateSinkObject.Save(1, &s.dirCursor)
+func (sdfo *StaticDirFileOperations) StateSave(stateSinkObject state.Sink) {
+ sdfo.beforeSave()
+ stateSinkObject.Save(0, &sdfo.dentryMap)
+ stateSinkObject.Save(1, &sdfo.dirCursor)
}
-func (s *StaticDirFileOperations) afterLoad() {}
+func (sdfo *StaticDirFileOperations) afterLoad() {}
-func (s *StaticDirFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &s.dentryMap)
- stateSourceObject.Load(1, &s.dirCursor)
+func (sdfo *StaticDirFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &sdfo.dentryMap)
+ stateSourceObject.Load(1, &sdfo.dirCursor)
}
func (n *NoReadWriteFile) StateTypeName() string {
@@ -74,49 +74,49 @@ func (n *NoReadWriteFile) afterLoad() {}
func (n *NoReadWriteFile) StateLoad(stateSourceObject state.Source) {
}
-func (f *FileStaticContentReader) StateTypeName() string {
+func (scr *FileStaticContentReader) StateTypeName() string {
return "pkg/sentry/fs/fsutil.FileStaticContentReader"
}
-func (f *FileStaticContentReader) StateFields() []string {
+func (scr *FileStaticContentReader) StateFields() []string {
return []string{
"content",
}
}
-func (f *FileStaticContentReader) beforeSave() {}
+func (scr *FileStaticContentReader) beforeSave() {}
-func (f *FileStaticContentReader) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- stateSinkObject.Save(0, &f.content)
+func (scr *FileStaticContentReader) StateSave(stateSinkObject state.Sink) {
+ scr.beforeSave()
+ stateSinkObject.Save(0, &scr.content)
}
-func (f *FileStaticContentReader) afterLoad() {}
+func (scr *FileStaticContentReader) afterLoad() {}
-func (f *FileStaticContentReader) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &f.content)
+func (scr *FileStaticContentReader) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &scr.content)
}
-func (h *HostFileMapper) StateTypeName() string {
+func (f *HostFileMapper) StateTypeName() string {
return "pkg/sentry/fs/fsutil.HostFileMapper"
}
-func (h *HostFileMapper) StateFields() []string {
+func (f *HostFileMapper) StateFields() []string {
return []string{
"refs",
}
}
-func (h *HostFileMapper) beforeSave() {}
+func (f *HostFileMapper) beforeSave() {}
-func (h *HostFileMapper) StateSave(stateSinkObject state.Sink) {
- h.beforeSave()
- stateSinkObject.Save(0, &h.refs)
+func (f *HostFileMapper) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.refs)
}
-func (h *HostFileMapper) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &h.refs)
- stateSourceObject.AfterLoad(h.afterLoad)
+func (f *HostFileMapper) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.refs)
+ stateSourceObject.AfterLoad(f.afterLoad)
}
func (h *HostMappable) StateTypeName() string {
diff --git a/pkg/sentry/fs/gofer/gofer_state_autogen.go b/pkg/sentry/fs/gofer/gofer_state_autogen.go
index c3cad4ad5..d2eb67d58 100644
--- a/pkg/sentry/fs/gofer/gofer_state_autogen.go
+++ b/pkg/sentry/fs/gofer/gofer_state_autogen.go
@@ -6,30 +6,30 @@ import (
"gvisor.dev/gvisor/pkg/state"
)
-func (f *fifo) StateTypeName() string {
+func (i *fifo) StateTypeName() string {
return "pkg/sentry/fs/gofer.fifo"
}
-func (f *fifo) StateFields() []string {
+func (i *fifo) StateFields() []string {
return []string{
"InodeOperations",
"fileIops",
}
}
-func (f *fifo) beforeSave() {}
+func (i *fifo) beforeSave() {}
-func (f *fifo) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- stateSinkObject.Save(0, &f.InodeOperations)
- stateSinkObject.Save(1, &f.fileIops)
+func (i *fifo) StateSave(stateSinkObject state.Sink) {
+ i.beforeSave()
+ stateSinkObject.Save(0, &i.InodeOperations)
+ stateSinkObject.Save(1, &i.fileIops)
}
-func (f *fifo) afterLoad() {}
+func (i *fifo) afterLoad() {}
-func (f *fifo) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &f.InodeOperations)
- stateSourceObject.Load(1, &f.fileIops)
+func (i *fifo) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &i.InodeOperations)
+ stateSourceObject.Load(1, &i.fileIops)
}
func (f *fileOperations) StateTypeName() string {
@@ -138,11 +138,11 @@ func (i *inodeFileState) StateLoad(stateSourceObject state.Source) {
stateSourceObject.AfterLoad(i.afterLoad)
}
-func (o *overrideInfo) StateTypeName() string {
+func (l *overrideInfo) StateTypeName() string {
return "pkg/sentry/fs/gofer.overrideInfo"
}
-func (o *overrideInfo) StateFields() []string {
+func (l *overrideInfo) StateFields() []string {
return []string{
"dirent",
"endpoint",
@@ -150,44 +150,44 @@ func (o *overrideInfo) StateFields() []string {
}
}
-func (o *overrideInfo) beforeSave() {}
+func (l *overrideInfo) beforeSave() {}
-func (o *overrideInfo) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
- stateSinkObject.Save(0, &o.dirent)
- stateSinkObject.Save(1, &o.endpoint)
- stateSinkObject.Save(2, &o.inode)
+func (l *overrideInfo) StateSave(stateSinkObject state.Sink) {
+ l.beforeSave()
+ stateSinkObject.Save(0, &l.dirent)
+ stateSinkObject.Save(1, &l.endpoint)
+ stateSinkObject.Save(2, &l.inode)
}
-func (o *overrideInfo) afterLoad() {}
+func (l *overrideInfo) afterLoad() {}
-func (o *overrideInfo) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &o.dirent)
- stateSourceObject.Load(1, &o.endpoint)
- stateSourceObject.Load(2, &o.inode)
+func (l *overrideInfo) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &l.dirent)
+ stateSourceObject.Load(1, &l.endpoint)
+ stateSourceObject.Load(2, &l.inode)
}
-func (o *overrideMaps) StateTypeName() string {
+func (e *overrideMaps) StateTypeName() string {
return "pkg/sentry/fs/gofer.overrideMaps"
}
-func (o *overrideMaps) StateFields() []string {
+func (e *overrideMaps) StateFields() []string {
return []string{
"pathMap",
}
}
-func (o *overrideMaps) beforeSave() {}
+func (e *overrideMaps) beforeSave() {}
-func (o *overrideMaps) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
- stateSinkObject.Save(0, &o.pathMap)
+func (e *overrideMaps) StateSave(stateSinkObject state.Sink) {
+ e.beforeSave()
+ stateSinkObject.Save(0, &e.pathMap)
}
-func (o *overrideMaps) afterLoad() {}
+func (e *overrideMaps) afterLoad() {}
-func (o *overrideMaps) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &o.pathMap)
+func (e *overrideMaps) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &e.pathMap)
}
func (s *session) StateTypeName() string {
diff --git a/pkg/sentry/fs/lock/lock_state_autogen.go b/pkg/sentry/fs/lock/lock_state_autogen.go
index 2b307be59..707a7518f 100644
--- a/pkg/sentry/fs/lock/lock_state_autogen.go
+++ b/pkg/sentry/fs/lock/lock_state_autogen.go
@@ -58,61 +58,61 @@ func (l *Locks) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(0, &l.locks)
}
-func (l *LockRange) StateTypeName() string {
+func (r *LockRange) StateTypeName() string {
return "pkg/sentry/fs/lock.LockRange"
}
-func (l *LockRange) StateFields() []string {
+func (r *LockRange) StateFields() []string {
return []string{
"Start",
"End",
}
}
-func (l *LockRange) beforeSave() {}
+func (r *LockRange) beforeSave() {}
-func (l *LockRange) StateSave(stateSinkObject state.Sink) {
- l.beforeSave()
- stateSinkObject.Save(0, &l.Start)
- stateSinkObject.Save(1, &l.End)
+func (r *LockRange) StateSave(stateSinkObject state.Sink) {
+ r.beforeSave()
+ stateSinkObject.Save(0, &r.Start)
+ stateSinkObject.Save(1, &r.End)
}
-func (l *LockRange) afterLoad() {}
+func (r *LockRange) afterLoad() {}
-func (l *LockRange) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &l.Start)
- stateSourceObject.Load(1, &l.End)
+func (r *LockRange) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &r.Start)
+ stateSourceObject.Load(1, &r.End)
}
-func (l *LockSet) StateTypeName() string {
+func (s *LockSet) StateTypeName() string {
return "pkg/sentry/fs/lock.LockSet"
}
-func (l *LockSet) StateFields() []string {
+func (s *LockSet) StateFields() []string {
return []string{
"root",
}
}
-func (l *LockSet) beforeSave() {}
+func (s *LockSet) beforeSave() {}
-func (l *LockSet) StateSave(stateSinkObject state.Sink) {
- l.beforeSave()
- var rootValue *LockSegmentDataSlices = l.saveRoot()
+func (s *LockSet) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ var rootValue *LockSegmentDataSlices = s.saveRoot()
stateSinkObject.SaveValue(0, rootValue)
}
-func (l *LockSet) afterLoad() {}
+func (s *LockSet) afterLoad() {}
-func (l *LockSet) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.LoadValue(0, new(*LockSegmentDataSlices), func(y interface{}) { l.loadRoot(y.(*LockSegmentDataSlices)) })
+func (s *LockSet) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.LoadValue(0, new(*LockSegmentDataSlices), func(y interface{}) { s.loadRoot(y.(*LockSegmentDataSlices)) })
}
-func (l *Locknode) StateTypeName() string {
+func (n *Locknode) StateTypeName() string {
return "pkg/sentry/fs/lock.Locknode"
}
-func (l *Locknode) StateFields() []string {
+func (n *Locknode) StateFields() []string {
return []string{
"nrSegments",
"parent",
@@ -125,31 +125,31 @@ func (l *Locknode) StateFields() []string {
}
}
-func (l *Locknode) beforeSave() {}
+func (n *Locknode) beforeSave() {}
-func (l *Locknode) StateSave(stateSinkObject state.Sink) {
- l.beforeSave()
- stateSinkObject.Save(0, &l.nrSegments)
- stateSinkObject.Save(1, &l.parent)
- stateSinkObject.Save(2, &l.parentIndex)
- stateSinkObject.Save(3, &l.hasChildren)
- stateSinkObject.Save(4, &l.maxGap)
- stateSinkObject.Save(5, &l.keys)
- stateSinkObject.Save(6, &l.values)
- stateSinkObject.Save(7, &l.children)
-}
-
-func (l *Locknode) afterLoad() {}
-
-func (l *Locknode) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &l.nrSegments)
- stateSourceObject.Load(1, &l.parent)
- stateSourceObject.Load(2, &l.parentIndex)
- stateSourceObject.Load(3, &l.hasChildren)
- stateSourceObject.Load(4, &l.maxGap)
- stateSourceObject.Load(5, &l.keys)
- stateSourceObject.Load(6, &l.values)
- stateSourceObject.Load(7, &l.children)
+func (n *Locknode) StateSave(stateSinkObject state.Sink) {
+ n.beforeSave()
+ stateSinkObject.Save(0, &n.nrSegments)
+ stateSinkObject.Save(1, &n.parent)
+ stateSinkObject.Save(2, &n.parentIndex)
+ stateSinkObject.Save(3, &n.hasChildren)
+ stateSinkObject.Save(4, &n.maxGap)
+ stateSinkObject.Save(5, &n.keys)
+ stateSinkObject.Save(6, &n.values)
+ stateSinkObject.Save(7, &n.children)
+}
+
+func (n *Locknode) afterLoad() {}
+
+func (n *Locknode) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &n.nrSegments)
+ stateSourceObject.Load(1, &n.parent)
+ stateSourceObject.Load(2, &n.parentIndex)
+ stateSourceObject.Load(3, &n.hasChildren)
+ stateSourceObject.Load(4, &n.maxGap)
+ stateSourceObject.Load(5, &n.keys)
+ stateSourceObject.Load(6, &n.values)
+ stateSourceObject.Load(7, &n.children)
}
func (l *LockSegmentDataSlices) StateTypeName() string {
diff --git a/pkg/sentry/fs/proc/proc_state_autogen.go b/pkg/sentry/fs/proc/proc_state_autogen.go
index ddb1f4e6e..d39cd1d2e 100644
--- a/pkg/sentry/fs/proc/proc_state_autogen.go
+++ b/pkg/sentry/fs/proc/proc_state_autogen.go
@@ -6,11 +6,11 @@ import (
"gvisor.dev/gvisor/pkg/state"
)
-func (e *execArgInode) StateTypeName() string {
+func (i *execArgInode) StateTypeName() string {
return "pkg/sentry/fs/proc.execArgInode"
}
-func (e *execArgInode) StateFields() []string {
+func (i *execArgInode) StateFields() []string {
return []string{
"SimpleFileInode",
"arg",
@@ -18,47 +18,47 @@ func (e *execArgInode) StateFields() []string {
}
}
-func (e *execArgInode) beforeSave() {}
+func (i *execArgInode) beforeSave() {}
-func (e *execArgInode) StateSave(stateSinkObject state.Sink) {
- e.beforeSave()
- stateSinkObject.Save(0, &e.SimpleFileInode)
- stateSinkObject.Save(1, &e.arg)
- stateSinkObject.Save(2, &e.t)
+func (i *execArgInode) StateSave(stateSinkObject state.Sink) {
+ i.beforeSave()
+ stateSinkObject.Save(0, &i.SimpleFileInode)
+ stateSinkObject.Save(1, &i.arg)
+ stateSinkObject.Save(2, &i.t)
}
-func (e *execArgInode) afterLoad() {}
+func (i *execArgInode) afterLoad() {}
-func (e *execArgInode) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &e.SimpleFileInode)
- stateSourceObject.Load(1, &e.arg)
- stateSourceObject.Load(2, &e.t)
+func (i *execArgInode) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &i.SimpleFileInode)
+ stateSourceObject.Load(1, &i.arg)
+ stateSourceObject.Load(2, &i.t)
}
-func (e *execArgFile) StateTypeName() string {
+func (f *execArgFile) StateTypeName() string {
return "pkg/sentry/fs/proc.execArgFile"
}
-func (e *execArgFile) StateFields() []string {
+func (f *execArgFile) StateFields() []string {
return []string{
"arg",
"t",
}
}
-func (e *execArgFile) beforeSave() {}
+func (f *execArgFile) beforeSave() {}
-func (e *execArgFile) StateSave(stateSinkObject state.Sink) {
- e.beforeSave()
- stateSinkObject.Save(0, &e.arg)
- stateSinkObject.Save(1, &e.t)
+func (f *execArgFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.arg)
+ stateSinkObject.Save(1, &f.t)
}
-func (e *execArgFile) afterLoad() {}
+func (f *execArgFile) afterLoad() {}
-func (e *execArgFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &e.arg)
- stateSourceObject.Load(1, &e.t)
+func (f *execArgFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.arg)
+ stateSourceObject.Load(1, &f.t)
}
func (f *fdDir) StateTypeName() string {
@@ -113,30 +113,30 @@ func (f *fdDirFile) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &f.t)
}
-func (f *fdInfoDir) StateTypeName() string {
+func (fdid *fdInfoDir) StateTypeName() string {
return "pkg/sentry/fs/proc.fdInfoDir"
}
-func (f *fdInfoDir) StateFields() []string {
+func (fdid *fdInfoDir) StateFields() []string {
return []string{
"Dir",
"t",
}
}
-func (f *fdInfoDir) beforeSave() {}
+func (fdid *fdInfoDir) beforeSave() {}
-func (f *fdInfoDir) StateSave(stateSinkObject state.Sink) {
- f.beforeSave()
- stateSinkObject.Save(0, &f.Dir)
- stateSinkObject.Save(1, &f.t)
+func (fdid *fdInfoDir) StateSave(stateSinkObject state.Sink) {
+ fdid.beforeSave()
+ stateSinkObject.Save(0, &fdid.Dir)
+ stateSinkObject.Save(1, &fdid.t)
}
-func (f *fdInfoDir) afterLoad() {}
+func (fdid *fdInfoDir) afterLoad() {}
-func (f *fdInfoDir) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &f.Dir)
- stateSourceObject.Load(1, &f.t)
+func (fdid *fdInfoDir) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &fdid.Dir)
+ stateSourceObject.Load(1, &fdid.t)
}
func (f *filesystemsData) StateTypeName() string {
@@ -177,30 +177,30 @@ func (f *filesystem) afterLoad() {}
func (f *filesystem) StateLoad(stateSourceObject state.Source) {
}
-func (t *taskOwnedInodeOps) StateTypeName() string {
+func (i *taskOwnedInodeOps) StateTypeName() string {
return "pkg/sentry/fs/proc.taskOwnedInodeOps"
}
-func (t *taskOwnedInodeOps) StateFields() []string {
+func (i *taskOwnedInodeOps) StateFields() []string {
return []string{
"InodeOperations",
"t",
}
}
-func (t *taskOwnedInodeOps) beforeSave() {}
+func (i *taskOwnedInodeOps) beforeSave() {}
-func (t *taskOwnedInodeOps) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.InodeOperations)
- stateSinkObject.Save(1, &t.t)
+func (i *taskOwnedInodeOps) StateSave(stateSinkObject state.Sink) {
+ i.beforeSave()
+ stateSinkObject.Save(0, &i.InodeOperations)
+ stateSinkObject.Save(1, &i.t)
}
-func (t *taskOwnedInodeOps) afterLoad() {}
+func (i *taskOwnedInodeOps) afterLoad() {}
-func (t *taskOwnedInodeOps) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.InodeOperations)
- stateSourceObject.Load(1, &t.t)
+func (i *taskOwnedInodeOps) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &i.InodeOperations)
+ stateSourceObject.Load(1, &i.t)
}
func (s *staticFileInodeOps) StateTypeName() string {
@@ -229,115 +229,115 @@ func (s *staticFileInodeOps) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &s.InodeStaticFileGetter)
}
-func (l *loadavgData) StateTypeName() string {
+func (d *loadavgData) StateTypeName() string {
return "pkg/sentry/fs/proc.loadavgData"
}
-func (l *loadavgData) StateFields() []string {
+func (d *loadavgData) StateFields() []string {
return []string{}
}
-func (l *loadavgData) beforeSave() {}
+func (d *loadavgData) beforeSave() {}
-func (l *loadavgData) StateSave(stateSinkObject state.Sink) {
- l.beforeSave()
+func (d *loadavgData) StateSave(stateSinkObject state.Sink) {
+ d.beforeSave()
}
-func (l *loadavgData) afterLoad() {}
+func (d *loadavgData) afterLoad() {}
-func (l *loadavgData) StateLoad(stateSourceObject state.Source) {
+func (d *loadavgData) StateLoad(stateSourceObject state.Source) {
}
-func (m *meminfoData) StateTypeName() string {
+func (d *meminfoData) StateTypeName() string {
return "pkg/sentry/fs/proc.meminfoData"
}
-func (m *meminfoData) StateFields() []string {
+func (d *meminfoData) StateFields() []string {
return []string{
"k",
}
}
-func (m *meminfoData) beforeSave() {}
+func (d *meminfoData) beforeSave() {}
-func (m *meminfoData) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.k)
+func (d *meminfoData) StateSave(stateSinkObject state.Sink) {
+ d.beforeSave()
+ stateSinkObject.Save(0, &d.k)
}
-func (m *meminfoData) afterLoad() {}
+func (d *meminfoData) afterLoad() {}
-func (m *meminfoData) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.k)
+func (d *meminfoData) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &d.k)
}
-func (m *mountInfoFile) StateTypeName() string {
+func (mif *mountInfoFile) StateTypeName() string {
return "pkg/sentry/fs/proc.mountInfoFile"
}
-func (m *mountInfoFile) StateFields() []string {
+func (mif *mountInfoFile) StateFields() []string {
return []string{
"t",
}
}
-func (m *mountInfoFile) beforeSave() {}
+func (mif *mountInfoFile) beforeSave() {}
-func (m *mountInfoFile) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.t)
+func (mif *mountInfoFile) StateSave(stateSinkObject state.Sink) {
+ mif.beforeSave()
+ stateSinkObject.Save(0, &mif.t)
}
-func (m *mountInfoFile) afterLoad() {}
+func (mif *mountInfoFile) afterLoad() {}
-func (m *mountInfoFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.t)
+func (mif *mountInfoFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &mif.t)
}
-func (m *mountsFile) StateTypeName() string {
+func (mf *mountsFile) StateTypeName() string {
return "pkg/sentry/fs/proc.mountsFile"
}
-func (m *mountsFile) StateFields() []string {
+func (mf *mountsFile) StateFields() []string {
return []string{
"t",
}
}
-func (m *mountsFile) beforeSave() {}
+func (mf *mountsFile) beforeSave() {}
-func (m *mountsFile) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.t)
+func (mf *mountsFile) StateSave(stateSinkObject state.Sink) {
+ mf.beforeSave()
+ stateSinkObject.Save(0, &mf.t)
}
-func (m *mountsFile) afterLoad() {}
+func (mf *mountsFile) afterLoad() {}
-func (m *mountsFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.t)
+func (mf *mountsFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &mf.t)
}
-func (i *ifinet6) StateTypeName() string {
+func (n *ifinet6) StateTypeName() string {
return "pkg/sentry/fs/proc.ifinet6"
}
-func (i *ifinet6) StateFields() []string {
+func (n *ifinet6) StateFields() []string {
return []string{
"s",
}
}
-func (i *ifinet6) beforeSave() {}
+func (n *ifinet6) beforeSave() {}
-func (i *ifinet6) StateSave(stateSinkObject state.Sink) {
- i.beforeSave()
- stateSinkObject.Save(0, &i.s)
+func (n *ifinet6) StateSave(stateSinkObject state.Sink) {
+ n.beforeSave()
+ stateSinkObject.Save(0, &n.s)
}
-func (i *ifinet6) afterLoad() {}
+func (n *ifinet6) afterLoad() {}
-func (i *ifinet6) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &i.s)
+func (n *ifinet6) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &n.s)
}
func (n *netDev) StateTypeName() string {
@@ -559,53 +559,53 @@ func (s *self) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &s.pidns)
}
-func (t *threadSelf) StateTypeName() string {
+func (s *threadSelf) StateTypeName() string {
return "pkg/sentry/fs/proc.threadSelf"
}
-func (t *threadSelf) StateFields() []string {
+func (s *threadSelf) StateFields() []string {
return []string{
"Symlink",
"pidns",
}
}
-func (t *threadSelf) beforeSave() {}
+func (s *threadSelf) beforeSave() {}
-func (t *threadSelf) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.Symlink)
- stateSinkObject.Save(1, &t.pidns)
+func (s *threadSelf) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ stateSinkObject.Save(0, &s.Symlink)
+ stateSinkObject.Save(1, &s.pidns)
}
-func (t *threadSelf) afterLoad() {}
+func (s *threadSelf) afterLoad() {}
-func (t *threadSelf) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.Symlink)
- stateSourceObject.Load(1, &t.pidns)
+func (s *threadSelf) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &s.Symlink)
+ stateSourceObject.Load(1, &s.pidns)
}
-func (r *rootProcFile) StateTypeName() string {
+func (rpf *rootProcFile) StateTypeName() string {
return "pkg/sentry/fs/proc.rootProcFile"
}
-func (r *rootProcFile) StateFields() []string {
+func (rpf *rootProcFile) StateFields() []string {
return []string{
"iops",
}
}
-func (r *rootProcFile) beforeSave() {}
+func (rpf *rootProcFile) beforeSave() {}
-func (r *rootProcFile) StateSave(stateSinkObject state.Sink) {
- r.beforeSave()
- stateSinkObject.Save(0, &r.iops)
+func (rpf *rootProcFile) StateSave(stateSinkObject state.Sink) {
+ rpf.beforeSave()
+ stateSinkObject.Save(0, &rpf.iops)
}
-func (r *rootProcFile) afterLoad() {}
+func (rpf *rootProcFile) afterLoad() {}
-func (r *rootProcFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &r.iops)
+func (rpf *rootProcFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &rpf.iops)
}
func (s *statData) StateTypeName() string {
@@ -631,27 +631,27 @@ func (s *statData) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(0, &s.k)
}
-func (m *mmapMinAddrData) StateTypeName() string {
+func (d *mmapMinAddrData) StateTypeName() string {
return "pkg/sentry/fs/proc.mmapMinAddrData"
}
-func (m *mmapMinAddrData) StateFields() []string {
+func (d *mmapMinAddrData) StateFields() []string {
return []string{
"k",
}
}
-func (m *mmapMinAddrData) beforeSave() {}
+func (d *mmapMinAddrData) beforeSave() {}
-func (m *mmapMinAddrData) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.k)
+func (d *mmapMinAddrData) StateSave(stateSinkObject state.Sink) {
+ d.beforeSave()
+ stateSinkObject.Save(0, &d.k)
}
-func (m *mmapMinAddrData) afterLoad() {}
+func (d *mmapMinAddrData) afterLoad() {}
-func (m *mmapMinAddrData) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.k)
+func (d *mmapMinAddrData) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &d.k)
}
func (o *overcommitMemory) StateTypeName() string {
@@ -696,23 +696,23 @@ func (h *hostname) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(0, &h.SimpleFileInode)
}
-func (h *hostnameFile) StateTypeName() string {
+func (hf *hostnameFile) StateTypeName() string {
return "pkg/sentry/fs/proc.hostnameFile"
}
-func (h *hostnameFile) StateFields() []string {
+func (hf *hostnameFile) StateFields() []string {
return []string{}
}
-func (h *hostnameFile) beforeSave() {}
+func (hf *hostnameFile) beforeSave() {}
-func (h *hostnameFile) StateSave(stateSinkObject state.Sink) {
- h.beforeSave()
+func (hf *hostnameFile) StateSave(stateSinkObject state.Sink) {
+ hf.beforeSave()
}
-func (h *hostnameFile) afterLoad() {}
+func (hf *hostnameFile) afterLoad() {}
-func (h *hostnameFile) StateLoad(stateSourceObject state.Source) {
+func (hf *hostnameFile) StateLoad(stateSourceObject state.Source) {
}
func (t *tcpMemInode) StateTypeName() string {
@@ -744,34 +744,34 @@ func (t *tcpMemInode) StateLoad(stateSourceObject state.Source) {
stateSourceObject.AfterLoad(t.afterLoad)
}
-func (t *tcpMemFile) StateTypeName() string {
+func (f *tcpMemFile) StateTypeName() string {
return "pkg/sentry/fs/proc.tcpMemFile"
}
-func (t *tcpMemFile) StateFields() []string {
+func (f *tcpMemFile) StateFields() []string {
return []string{
"tcpMemInode",
}
}
-func (t *tcpMemFile) beforeSave() {}
+func (f *tcpMemFile) beforeSave() {}
-func (t *tcpMemFile) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.tcpMemInode)
+func (f *tcpMemFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.tcpMemInode)
}
-func (t *tcpMemFile) afterLoad() {}
+func (f *tcpMemFile) afterLoad() {}
-func (t *tcpMemFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.tcpMemInode)
+func (f *tcpMemFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.tcpMemInode)
}
-func (t *tcpSack) StateTypeName() string {
+func (s *tcpSack) StateTypeName() string {
return "pkg/sentry/fs/proc.tcpSack"
}
-func (t *tcpSack) StateFields() []string {
+func (s *tcpSack) StateFields() []string {
return []string{
"SimpleFileInode",
"stack",
@@ -779,53 +779,53 @@ func (t *tcpSack) StateFields() []string {
}
}
-func (t *tcpSack) beforeSave() {}
+func (s *tcpSack) beforeSave() {}
-func (t *tcpSack) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.SimpleFileInode)
- stateSinkObject.Save(1, &t.stack)
- stateSinkObject.Save(2, &t.enabled)
+func (s *tcpSack) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ stateSinkObject.Save(0, &s.SimpleFileInode)
+ stateSinkObject.Save(1, &s.stack)
+ stateSinkObject.Save(2, &s.enabled)
}
-func (t *tcpSack) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.SimpleFileInode)
- stateSourceObject.LoadWait(1, &t.stack)
- stateSourceObject.Load(2, &t.enabled)
- stateSourceObject.AfterLoad(t.afterLoad)
+func (s *tcpSack) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &s.SimpleFileInode)
+ stateSourceObject.LoadWait(1, &s.stack)
+ stateSourceObject.Load(2, &s.enabled)
+ stateSourceObject.AfterLoad(s.afterLoad)
}
-func (t *tcpSackFile) StateTypeName() string {
+func (f *tcpSackFile) StateTypeName() string {
return "pkg/sentry/fs/proc.tcpSackFile"
}
-func (t *tcpSackFile) StateFields() []string {
+func (f *tcpSackFile) StateFields() []string {
return []string{
"tcpSack",
"stack",
}
}
-func (t *tcpSackFile) beforeSave() {}
+func (f *tcpSackFile) beforeSave() {}
-func (t *tcpSackFile) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.tcpSack)
- stateSinkObject.Save(1, &t.stack)
+func (f *tcpSackFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.tcpSack)
+ stateSinkObject.Save(1, &f.stack)
}
-func (t *tcpSackFile) afterLoad() {}
+func (f *tcpSackFile) afterLoad() {}
-func (t *tcpSackFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.tcpSack)
- stateSourceObject.LoadWait(1, &t.stack)
+func (f *tcpSackFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.tcpSack)
+ stateSourceObject.LoadWait(1, &f.stack)
}
-func (t *tcpRecovery) StateTypeName() string {
+func (r *tcpRecovery) StateTypeName() string {
return "pkg/sentry/fs/proc.tcpRecovery"
}
-func (t *tcpRecovery) StateFields() []string {
+func (r *tcpRecovery) StateFields() []string {
return []string{
"SimpleFileInode",
"stack",
@@ -833,54 +833,54 @@ func (t *tcpRecovery) StateFields() []string {
}
}
-func (t *tcpRecovery) beforeSave() {}
+func (r *tcpRecovery) beforeSave() {}
-func (t *tcpRecovery) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.SimpleFileInode)
- stateSinkObject.Save(1, &t.stack)
- stateSinkObject.Save(2, &t.recovery)
+func (r *tcpRecovery) StateSave(stateSinkObject state.Sink) {
+ r.beforeSave()
+ stateSinkObject.Save(0, &r.SimpleFileInode)
+ stateSinkObject.Save(1, &r.stack)
+ stateSinkObject.Save(2, &r.recovery)
}
-func (t *tcpRecovery) afterLoad() {}
+func (r *tcpRecovery) afterLoad() {}
-func (t *tcpRecovery) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.SimpleFileInode)
- stateSourceObject.LoadWait(1, &t.stack)
- stateSourceObject.Load(2, &t.recovery)
+func (r *tcpRecovery) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &r.SimpleFileInode)
+ stateSourceObject.LoadWait(1, &r.stack)
+ stateSourceObject.Load(2, &r.recovery)
}
-func (t *tcpRecoveryFile) StateTypeName() string {
+func (f *tcpRecoveryFile) StateTypeName() string {
return "pkg/sentry/fs/proc.tcpRecoveryFile"
}
-func (t *tcpRecoveryFile) StateFields() []string {
+func (f *tcpRecoveryFile) StateFields() []string {
return []string{
"tcpRecovery",
"stack",
}
}
-func (t *tcpRecoveryFile) beforeSave() {}
+func (f *tcpRecoveryFile) beforeSave() {}
-func (t *tcpRecoveryFile) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.tcpRecovery)
- stateSinkObject.Save(1, &t.stack)
+func (f *tcpRecoveryFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.tcpRecovery)
+ stateSinkObject.Save(1, &f.stack)
}
-func (t *tcpRecoveryFile) afterLoad() {}
+func (f *tcpRecoveryFile) afterLoad() {}
-func (t *tcpRecoveryFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.tcpRecovery)
- stateSourceObject.LoadWait(1, &t.stack)
+func (f *tcpRecoveryFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.tcpRecovery)
+ stateSourceObject.LoadWait(1, &f.stack)
}
-func (i *ipForwarding) StateTypeName() string {
+func (ipf *ipForwarding) StateTypeName() string {
return "pkg/sentry/fs/proc.ipForwarding"
}
-func (i *ipForwarding) StateFields() []string {
+func (ipf *ipForwarding) StateFields() []string {
return []string{
"SimpleFileInode",
"stack",
@@ -888,46 +888,46 @@ func (i *ipForwarding) StateFields() []string {
}
}
-func (i *ipForwarding) beforeSave() {}
+func (ipf *ipForwarding) beforeSave() {}
-func (i *ipForwarding) StateSave(stateSinkObject state.Sink) {
- i.beforeSave()
- stateSinkObject.Save(0, &i.SimpleFileInode)
- stateSinkObject.Save(1, &i.stack)
- stateSinkObject.Save(2, &i.enabled)
+func (ipf *ipForwarding) StateSave(stateSinkObject state.Sink) {
+ ipf.beforeSave()
+ stateSinkObject.Save(0, &ipf.SimpleFileInode)
+ stateSinkObject.Save(1, &ipf.stack)
+ stateSinkObject.Save(2, &ipf.enabled)
}
-func (i *ipForwarding) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &i.SimpleFileInode)
- stateSourceObject.LoadWait(1, &i.stack)
- stateSourceObject.Load(2, &i.enabled)
- stateSourceObject.AfterLoad(i.afterLoad)
+func (ipf *ipForwarding) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &ipf.SimpleFileInode)
+ stateSourceObject.LoadWait(1, &ipf.stack)
+ stateSourceObject.Load(2, &ipf.enabled)
+ stateSourceObject.AfterLoad(ipf.afterLoad)
}
-func (i *ipForwardingFile) StateTypeName() string {
+func (f *ipForwardingFile) StateTypeName() string {
return "pkg/sentry/fs/proc.ipForwardingFile"
}
-func (i *ipForwardingFile) StateFields() []string {
+func (f *ipForwardingFile) StateFields() []string {
return []string{
"ipf",
"stack",
}
}
-func (i *ipForwardingFile) beforeSave() {}
+func (f *ipForwardingFile) beforeSave() {}
-func (i *ipForwardingFile) StateSave(stateSinkObject state.Sink) {
- i.beforeSave()
- stateSinkObject.Save(0, &i.ipf)
- stateSinkObject.Save(1, &i.stack)
+func (f *ipForwardingFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.ipf)
+ stateSinkObject.Save(1, &f.stack)
}
-func (i *ipForwardingFile) afterLoad() {}
+func (f *ipForwardingFile) afterLoad() {}
-func (i *ipForwardingFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &i.ipf)
- stateSourceObject.LoadWait(1, &i.stack)
+func (f *ipForwardingFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.ipf)
+ stateSourceObject.LoadWait(1, &f.stack)
}
func (t *taskDir) StateTypeName() string {
@@ -985,30 +985,30 @@ func (s *subtasks) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(2, &s.p)
}
-func (s *subtasksFile) StateTypeName() string {
+func (f *subtasksFile) StateTypeName() string {
return "pkg/sentry/fs/proc.subtasksFile"
}
-func (s *subtasksFile) StateFields() []string {
+func (f *subtasksFile) StateFields() []string {
return []string{
"t",
"pidns",
}
}
-func (s *subtasksFile) beforeSave() {}
+func (f *subtasksFile) beforeSave() {}
-func (s *subtasksFile) StateSave(stateSinkObject state.Sink) {
- s.beforeSave()
- stateSinkObject.Save(0, &s.t)
- stateSinkObject.Save(1, &s.pidns)
+func (f *subtasksFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.t)
+ stateSinkObject.Save(1, &f.pidns)
}
-func (s *subtasksFile) afterLoad() {}
+func (f *subtasksFile) afterLoad() {}
-func (s *subtasksFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &s.t)
- stateSourceObject.Load(1, &s.pidns)
+func (f *subtasksFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.t)
+ stateSourceObject.Load(1, &f.pidns)
}
func (e *exe) StateTypeName() string {
@@ -1037,30 +1037,30 @@ func (e *exe) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &e.t)
}
-func (c *cwd) StateTypeName() string {
+func (e *cwd) StateTypeName() string {
return "pkg/sentry/fs/proc.cwd"
}
-func (c *cwd) StateFields() []string {
+func (e *cwd) StateFields() []string {
return []string{
"Symlink",
"t",
}
}
-func (c *cwd) beforeSave() {}
+func (e *cwd) beforeSave() {}
-func (c *cwd) StateSave(stateSinkObject state.Sink) {
- c.beforeSave()
- stateSinkObject.Save(0, &c.Symlink)
- stateSinkObject.Save(1, &c.t)
+func (e *cwd) StateSave(stateSinkObject state.Sink) {
+ e.beforeSave()
+ stateSinkObject.Save(0, &e.Symlink)
+ stateSinkObject.Save(1, &e.t)
}
-func (c *cwd) afterLoad() {}
+func (e *cwd) afterLoad() {}
-func (c *cwd) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &c.Symlink)
- stateSourceObject.Load(1, &c.t)
+func (e *cwd) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &e.Symlink)
+ stateSourceObject.Load(1, &e.t)
}
func (n *namespaceSymlink) StateTypeName() string {
@@ -1089,57 +1089,57 @@ func (n *namespaceSymlink) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &n.t)
}
-func (m *mapsData) StateTypeName() string {
+func (md *mapsData) StateTypeName() string {
return "pkg/sentry/fs/proc.mapsData"
}
-func (m *mapsData) StateFields() []string {
+func (md *mapsData) StateFields() []string {
return []string{
"t",
}
}
-func (m *mapsData) beforeSave() {}
+func (md *mapsData) beforeSave() {}
-func (m *mapsData) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.t)
+func (md *mapsData) StateSave(stateSinkObject state.Sink) {
+ md.beforeSave()
+ stateSinkObject.Save(0, &md.t)
}
-func (m *mapsData) afterLoad() {}
+func (md *mapsData) afterLoad() {}
-func (m *mapsData) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.t)
+func (md *mapsData) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &md.t)
}
-func (s *smapsData) StateTypeName() string {
+func (sd *smapsData) StateTypeName() string {
return "pkg/sentry/fs/proc.smapsData"
}
-func (s *smapsData) StateFields() []string {
+func (sd *smapsData) StateFields() []string {
return []string{
"t",
}
}
-func (s *smapsData) beforeSave() {}
+func (sd *smapsData) beforeSave() {}
-func (s *smapsData) StateSave(stateSinkObject state.Sink) {
- s.beforeSave()
- stateSinkObject.Save(0, &s.t)
+func (sd *smapsData) StateSave(stateSinkObject state.Sink) {
+ sd.beforeSave()
+ stateSinkObject.Save(0, &sd.t)
}
-func (s *smapsData) afterLoad() {}
+func (sd *smapsData) afterLoad() {}
-func (s *smapsData) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &s.t)
+func (sd *smapsData) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &sd.t)
}
-func (t *taskStatData) StateTypeName() string {
+func (s *taskStatData) StateTypeName() string {
return "pkg/sentry/fs/proc.taskStatData"
}
-func (t *taskStatData) StateFields() []string {
+func (s *taskStatData) StateFields() []string {
return []string{
"t",
"tgstats",
@@ -1147,21 +1147,21 @@ func (t *taskStatData) StateFields() []string {
}
}
-func (t *taskStatData) beforeSave() {}
+func (s *taskStatData) beforeSave() {}
-func (t *taskStatData) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.t)
- stateSinkObject.Save(1, &t.tgstats)
- stateSinkObject.Save(2, &t.pidns)
+func (s *taskStatData) StateSave(stateSinkObject state.Sink) {
+ s.beforeSave()
+ stateSinkObject.Save(0, &s.t)
+ stateSinkObject.Save(1, &s.tgstats)
+ stateSinkObject.Save(2, &s.pidns)
}
-func (t *taskStatData) afterLoad() {}
+func (s *taskStatData) afterLoad() {}
-func (t *taskStatData) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.t)
- stateSourceObject.Load(1, &t.tgstats)
- stateSourceObject.Load(2, &t.pidns)
+func (s *taskStatData) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &s.t)
+ stateSourceObject.Load(1, &s.tgstats)
+ stateSourceObject.Load(2, &s.pidns)
}
func (s *statmData) StateTypeName() string {
@@ -1262,27 +1262,27 @@ func (c *comm) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &c.t)
}
-func (c *commFile) StateTypeName() string {
+func (f *commFile) StateTypeName() string {
return "pkg/sentry/fs/proc.commFile"
}
-func (c *commFile) StateFields() []string {
+func (f *commFile) StateFields() []string {
return []string{
"t",
}
}
-func (c *commFile) beforeSave() {}
+func (f *commFile) beforeSave() {}
-func (c *commFile) StateSave(stateSinkObject state.Sink) {
- c.beforeSave()
- stateSinkObject.Save(0, &c.t)
+func (f *commFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.t)
}
-func (c *commFile) afterLoad() {}
+func (f *commFile) afterLoad() {}
-func (c *commFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &c.t)
+func (f *commFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.t)
}
func (a *auxvec) StateTypeName() string {
@@ -1311,27 +1311,27 @@ func (a *auxvec) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &a.t)
}
-func (a *auxvecFile) StateTypeName() string {
+func (f *auxvecFile) StateTypeName() string {
return "pkg/sentry/fs/proc.auxvecFile"
}
-func (a *auxvecFile) StateFields() []string {
+func (f *auxvecFile) StateFields() []string {
return []string{
"t",
}
}
-func (a *auxvecFile) beforeSave() {}
+func (f *auxvecFile) beforeSave() {}
-func (a *auxvecFile) StateSave(stateSinkObject state.Sink) {
- a.beforeSave()
- stateSinkObject.Save(0, &a.t)
+func (f *auxvecFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.t)
}
-func (a *auxvecFile) afterLoad() {}
+func (f *auxvecFile) afterLoad() {}
-func (a *auxvecFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &a.t)
+func (f *auxvecFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.t)
}
func (o *oomScoreAdj) StateTypeName() string {
@@ -1360,34 +1360,34 @@ func (o *oomScoreAdj) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &o.t)
}
-func (o *oomScoreAdjFile) StateTypeName() string {
+func (f *oomScoreAdjFile) StateTypeName() string {
return "pkg/sentry/fs/proc.oomScoreAdjFile"
}
-func (o *oomScoreAdjFile) StateFields() []string {
+func (f *oomScoreAdjFile) StateFields() []string {
return []string{
"t",
}
}
-func (o *oomScoreAdjFile) beforeSave() {}
+func (f *oomScoreAdjFile) beforeSave() {}
-func (o *oomScoreAdjFile) StateSave(stateSinkObject state.Sink) {
- o.beforeSave()
- stateSinkObject.Save(0, &o.t)
+func (f *oomScoreAdjFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.t)
}
-func (o *oomScoreAdjFile) afterLoad() {}
+func (f *oomScoreAdjFile) afterLoad() {}
-func (o *oomScoreAdjFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &o.t)
+func (f *oomScoreAdjFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.t)
}
-func (i *idMapInodeOperations) StateTypeName() string {
+func (imio *idMapInodeOperations) StateTypeName() string {
return "pkg/sentry/fs/proc.idMapInodeOperations"
}
-func (i *idMapInodeOperations) StateFields() []string {
+func (imio *idMapInodeOperations) StateFields() []string {
return []string{
"InodeSimpleAttributes",
"InodeSimpleExtendedAttributes",
@@ -1396,46 +1396,46 @@ func (i *idMapInodeOperations) StateFields() []string {
}
}
-func (i *idMapInodeOperations) beforeSave() {}
+func (imio *idMapInodeOperations) beforeSave() {}
-func (i *idMapInodeOperations) StateSave(stateSinkObject state.Sink) {
- i.beforeSave()
- stateSinkObject.Save(0, &i.InodeSimpleAttributes)
- stateSinkObject.Save(1, &i.InodeSimpleExtendedAttributes)
- stateSinkObject.Save(2, &i.t)
- stateSinkObject.Save(3, &i.gids)
+func (imio *idMapInodeOperations) StateSave(stateSinkObject state.Sink) {
+ imio.beforeSave()
+ stateSinkObject.Save(0, &imio.InodeSimpleAttributes)
+ stateSinkObject.Save(1, &imio.InodeSimpleExtendedAttributes)
+ stateSinkObject.Save(2, &imio.t)
+ stateSinkObject.Save(3, &imio.gids)
}
-func (i *idMapInodeOperations) afterLoad() {}
+func (imio *idMapInodeOperations) afterLoad() {}
-func (i *idMapInodeOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &i.InodeSimpleAttributes)
- stateSourceObject.Load(1, &i.InodeSimpleExtendedAttributes)
- stateSourceObject.Load(2, &i.t)
- stateSourceObject.Load(3, &i.gids)
+func (imio *idMapInodeOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &imio.InodeSimpleAttributes)
+ stateSourceObject.Load(1, &imio.InodeSimpleExtendedAttributes)
+ stateSourceObject.Load(2, &imio.t)
+ stateSourceObject.Load(3, &imio.gids)
}
-func (i *idMapFileOperations) StateTypeName() string {
+func (imfo *idMapFileOperations) StateTypeName() string {
return "pkg/sentry/fs/proc.idMapFileOperations"
}
-func (i *idMapFileOperations) StateFields() []string {
+func (imfo *idMapFileOperations) StateFields() []string {
return []string{
"iops",
}
}
-func (i *idMapFileOperations) beforeSave() {}
+func (imfo *idMapFileOperations) beforeSave() {}
-func (i *idMapFileOperations) StateSave(stateSinkObject state.Sink) {
- i.beforeSave()
- stateSinkObject.Save(0, &i.iops)
+func (imfo *idMapFileOperations) StateSave(stateSinkObject state.Sink) {
+ imfo.beforeSave()
+ stateSinkObject.Save(0, &imfo.iops)
}
-func (i *idMapFileOperations) afterLoad() {}
+func (imfo *idMapFileOperations) afterLoad() {}
-func (i *idMapFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &i.iops)
+func (imfo *idMapFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &imfo.iops)
}
func (u *uptime) StateTypeName() string {
@@ -1464,27 +1464,27 @@ func (u *uptime) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(1, &u.startTime)
}
-func (u *uptimeFile) StateTypeName() string {
+func (f *uptimeFile) StateTypeName() string {
return "pkg/sentry/fs/proc.uptimeFile"
}
-func (u *uptimeFile) StateFields() []string {
+func (f *uptimeFile) StateFields() []string {
return []string{
"startTime",
}
}
-func (u *uptimeFile) beforeSave() {}
+func (f *uptimeFile) beforeSave() {}
-func (u *uptimeFile) StateSave(stateSinkObject state.Sink) {
- u.beforeSave()
- stateSinkObject.Save(0, &u.startTime)
+func (f *uptimeFile) StateSave(stateSinkObject state.Sink) {
+ f.beforeSave()
+ stateSinkObject.Save(0, &f.startTime)
}
-func (u *uptimeFile) afterLoad() {}
+func (f *uptimeFile) afterLoad() {}
-func (u *uptimeFile) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &u.startTime)
+func (f *uptimeFile) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &f.startTime)
}
func (v *versionData) StateTypeName() string {
diff --git a/pkg/sentry/fs/proc/seqfile/seqfile_state_autogen.go b/pkg/sentry/fs/proc/seqfile/seqfile_state_autogen.go
index cc107af96..ab08bbaa3 100644
--- a/pkg/sentry/fs/proc/seqfile/seqfile_state_autogen.go
+++ b/pkg/sentry/fs/proc/seqfile/seqfile_state_autogen.go
@@ -70,27 +70,27 @@ func (s *SeqFile) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(5, &s.lastRead)
}
-func (s *seqFileOperations) StateTypeName() string {
+func (sfo *seqFileOperations) StateTypeName() string {
return "pkg/sentry/fs/proc/seqfile.seqFileOperations"
}
-func (s *seqFileOperations) StateFields() []string {
+func (sfo *seqFileOperations) StateFields() []string {
return []string{
"seqFile",
}
}
-func (s *seqFileOperations) beforeSave() {}
+func (sfo *seqFileOperations) beforeSave() {}
-func (s *seqFileOperations) StateSave(stateSinkObject state.Sink) {
- s.beforeSave()
- stateSinkObject.Save(0, &s.seqFile)
+func (sfo *seqFileOperations) StateSave(stateSinkObject state.Sink) {
+ sfo.beforeSave()
+ stateSinkObject.Save(0, &sfo.seqFile)
}
-func (s *seqFileOperations) afterLoad() {}
+func (sfo *seqFileOperations) afterLoad() {}
-func (s *seqFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &s.seqFile)
+func (sfo *seqFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &sfo.seqFile)
}
func init() {
diff --git a/pkg/sentry/fs/ramfs/ramfs_state_autogen.go b/pkg/sentry/fs/ramfs/ramfs_state_autogen.go
index e4943e646..482d5d391 100644
--- a/pkg/sentry/fs/ramfs/ramfs_state_autogen.go
+++ b/pkg/sentry/fs/ramfs/ramfs_state_autogen.go
@@ -38,30 +38,30 @@ func (d *Dir) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(3, &d.dentryMap)
}
-func (d *dirFileOperations) StateTypeName() string {
+func (dfo *dirFileOperations) StateTypeName() string {
return "pkg/sentry/fs/ramfs.dirFileOperations"
}
-func (d *dirFileOperations) StateFields() []string {
+func (dfo *dirFileOperations) StateFields() []string {
return []string{
"dirCursor",
"dir",
}
}
-func (d *dirFileOperations) beforeSave() {}
+func (dfo *dirFileOperations) beforeSave() {}
-func (d *dirFileOperations) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- stateSinkObject.Save(0, &d.dirCursor)
- stateSinkObject.Save(1, &d.dir)
+func (dfo *dirFileOperations) StateSave(stateSinkObject state.Sink) {
+ dfo.beforeSave()
+ stateSinkObject.Save(0, &dfo.dirCursor)
+ stateSinkObject.Save(1, &dfo.dir)
}
-func (d *dirFileOperations) afterLoad() {}
+func (dfo *dirFileOperations) afterLoad() {}
-func (d *dirFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.dirCursor)
- stateSourceObject.Load(1, &d.dir)
+func (dfo *dirFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &dfo.dirCursor)
+ stateSourceObject.Load(1, &dfo.dir)
}
func (s *Socket) StateTypeName() string {
diff --git a/pkg/sentry/fs/tty/tty_state_autogen.go b/pkg/sentry/fs/tty/tty_state_autogen.go
index c644ea9db..0d3785768 100644
--- a/pkg/sentry/fs/tty/tty_state_autogen.go
+++ b/pkg/sentry/fs/tty/tty_state_autogen.go
@@ -44,30 +44,30 @@ func (d *dirInodeOperations) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(5, &d.next)
}
-func (d *dirFileOperations) StateTypeName() string {
+func (df *dirFileOperations) StateTypeName() string {
return "pkg/sentry/fs/tty.dirFileOperations"
}
-func (d *dirFileOperations) StateFields() []string {
+func (df *dirFileOperations) StateFields() []string {
return []string{
"di",
"dirCursor",
}
}
-func (d *dirFileOperations) beforeSave() {}
+func (df *dirFileOperations) beforeSave() {}
-func (d *dirFileOperations) StateSave(stateSinkObject state.Sink) {
- d.beforeSave()
- stateSinkObject.Save(0, &d.di)
- stateSinkObject.Save(1, &d.dirCursor)
+func (df *dirFileOperations) StateSave(stateSinkObject state.Sink) {
+ df.beforeSave()
+ stateSinkObject.Save(0, &df.di)
+ stateSinkObject.Save(1, &df.dirCursor)
}
-func (d *dirFileOperations) afterLoad() {}
+func (df *dirFileOperations) afterLoad() {}
-func (d *dirFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &d.di)
- stateSourceObject.Load(1, &d.dirCursor)
+func (df *dirFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &df.di)
+ stateSourceObject.Load(1, &df.dirCursor)
}
func (f *filesystem) StateTypeName() string {
@@ -187,56 +187,56 @@ func (i *inputQueueTransformer) afterLoad() {}
func (i *inputQueueTransformer) StateLoad(stateSourceObject state.Source) {
}
-func (m *masterInodeOperations) StateTypeName() string {
+func (mi *masterInodeOperations) StateTypeName() string {
return "pkg/sentry/fs/tty.masterInodeOperations"
}
-func (m *masterInodeOperations) StateFields() []string {
+func (mi *masterInodeOperations) StateFields() []string {
return []string{
"SimpleFileInode",
"d",
}
}
-func (m *masterInodeOperations) beforeSave() {}
+func (mi *masterInodeOperations) beforeSave() {}
-func (m *masterInodeOperations) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.SimpleFileInode)
- stateSinkObject.Save(1, &m.d)
+func (mi *masterInodeOperations) StateSave(stateSinkObject state.Sink) {
+ mi.beforeSave()
+ stateSinkObject.Save(0, &mi.SimpleFileInode)
+ stateSinkObject.Save(1, &mi.d)
}
-func (m *masterInodeOperations) afterLoad() {}
+func (mi *masterInodeOperations) afterLoad() {}
-func (m *masterInodeOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.SimpleFileInode)
- stateSourceObject.Load(1, &m.d)
+func (mi *masterInodeOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &mi.SimpleFileInode)
+ stateSourceObject.Load(1, &mi.d)
}
-func (m *masterFileOperations) StateTypeName() string {
+func (mf *masterFileOperations) StateTypeName() string {
return "pkg/sentry/fs/tty.masterFileOperations"
}
-func (m *masterFileOperations) StateFields() []string {
+func (mf *masterFileOperations) StateFields() []string {
return []string{
"d",
"t",
}
}
-func (m *masterFileOperations) beforeSave() {}
+func (mf *masterFileOperations) beforeSave() {}
-func (m *masterFileOperations) StateSave(stateSinkObject state.Sink) {
- m.beforeSave()
- stateSinkObject.Save(0, &m.d)
- stateSinkObject.Save(1, &m.t)
+func (mf *masterFileOperations) StateSave(stateSinkObject state.Sink) {
+ mf.beforeSave()
+ stateSinkObject.Save(0, &mf.d)
+ stateSinkObject.Save(1, &mf.t)
}
-func (m *masterFileOperations) afterLoad() {}
+func (mf *masterFileOperations) afterLoad() {}
-func (m *masterFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &m.d)
- stateSourceObject.Load(1, &m.t)
+func (mf *masterFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &mf.d)
+ stateSourceObject.Load(1, &mf.t)
}
func (q *queue) StateTypeName() string {
@@ -274,11 +274,11 @@ func (q *queue) StateLoad(stateSourceObject state.Source) {
stateSourceObject.Load(4, &q.transformer)
}
-func (r *replicaInodeOperations) StateTypeName() string {
+func (si *replicaInodeOperations) StateTypeName() string {
return "pkg/sentry/fs/tty.replicaInodeOperations"
}
-func (r *replicaInodeOperations) StateFields() []string {
+func (si *replicaInodeOperations) StateFields() []string {
return []string{
"SimpleFileInode",
"d",
@@ -286,51 +286,51 @@ func (r *replicaInodeOperations) StateFields() []string {
}
}
-func (r *replicaInodeOperations) beforeSave() {}
+func (si *replicaInodeOperations) beforeSave() {}
-func (r *replicaInodeOperations) StateSave(stateSinkObject state.Sink) {
- r.beforeSave()
- stateSinkObject.Save(0, &r.SimpleFileInode)
- stateSinkObject.Save(1, &r.d)
- stateSinkObject.Save(2, &r.t)
+func (si *replicaInodeOperations) StateSave(stateSinkObject state.Sink) {
+ si.beforeSave()
+ stateSinkObject.Save(0, &si.SimpleFileInode)
+ stateSinkObject.Save(1, &si.d)
+ stateSinkObject.Save(2, &si.t)
}
-func (r *replicaInodeOperations) afterLoad() {}
+func (si *replicaInodeOperations) afterLoad() {}
-func (r *replicaInodeOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &r.SimpleFileInode)
- stateSourceObject.Load(1, &r.d)
- stateSourceObject.Load(2, &r.t)
+func (si *replicaInodeOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &si.SimpleFileInode)
+ stateSourceObject.Load(1, &si.d)
+ stateSourceObject.Load(2, &si.t)
}
-func (r *replicaFileOperations) StateTypeName() string {
+func (sf *replicaFileOperations) StateTypeName() string {
return "pkg/sentry/fs/tty.replicaFileOperations"
}
-func (r *replicaFileOperations) StateFields() []string {
+func (sf *replicaFileOperations) StateFields() []string {
return []string{
"si",
}
}
-func (r *replicaFileOperations) beforeSave() {}
+func (sf *replicaFileOperations) beforeSave() {}
-func (r *replicaFileOperations) StateSave(stateSinkObject state.Sink) {
- r.beforeSave()
- stateSinkObject.Save(0, &r.si)
+func (sf *replicaFileOperations) StateSave(stateSinkObject state.Sink) {
+ sf.beforeSave()
+ stateSinkObject.Save(0, &sf.si)
}
-func (r *replicaFileOperations) afterLoad() {}
+func (sf *replicaFileOperations) afterLoad() {}
-func (r *replicaFileOperations) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &r.si)
+func (sf *replicaFileOperations) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &sf.si)
}
-func (t *Terminal) StateTypeName() string {
+func (tm *Terminal) StateTypeName() string {
return "pkg/sentry/fs/tty.Terminal"
}
-func (t *Terminal) StateFields() []string {
+func (tm *Terminal) StateFields() []string {
return []string{
"AtomicRefCount",
"n",
@@ -341,27 +341,27 @@ func (t *Terminal) StateFields() []string {
}
}
-func (t *Terminal) beforeSave() {}
+func (tm *Terminal) beforeSave() {}
-func (t *Terminal) StateSave(stateSinkObject state.Sink) {
- t.beforeSave()
- stateSinkObject.Save(0, &t.AtomicRefCount)
- stateSinkObject.Save(1, &t.n)
- stateSinkObject.Save(2, &t.d)
- stateSinkObject.Save(3, &t.ld)
- stateSinkObject.Save(4, &t.masterKTTY)
- stateSinkObject.Save(5, &t.replicaKTTY)
+func (tm *Terminal) StateSave(stateSinkObject state.Sink) {
+ tm.beforeSave()
+ stateSinkObject.Save(0, &tm.AtomicRefCount)
+ stateSinkObject.Save(1, &tm.n)
+ stateSinkObject.Save(2, &tm.d)
+ stateSinkObject.Save(3, &tm.ld)
+ stateSinkObject.Save(4, &tm.masterKTTY)
+ stateSinkObject.Save(5, &tm.replicaKTTY)
}
-func (t *Terminal) afterLoad() {}
+func (tm *Terminal) afterLoad() {}
-func (t *Terminal) StateLoad(stateSourceObject state.Source) {
- stateSourceObject.Load(0, &t.AtomicRefCount)
- stateSourceObject.Load(1, &t.n)
- stateSourceObject.Load(2, &t.d)
- stateSourceObject.Load(3, &t.ld)
- stateSourceObject.Load(4, &t.masterKTTY)
- stateSourceObject.Load(5, &t.replicaKTTY)
+func (tm *Terminal) StateLoad(stateSourceObject state.Source) {
+ stateSourceObject.Load(0, &tm.AtomicRefCount)
+ stateSourceObject.Load(1, &tm.n)
+ stateSourceObject.Load(2, &tm.d)
+ stateSourceObject.Load(3, &tm.ld)
+ stateSourceObject.Load(4, &tm.masterKTTY)
+ stateSourceObject.Load(5, &tm.replicaKTTY)
}
func init() {