diff options
author | gVisor bot <gvisor-bot@google.com> | 2020-10-14 07:18:14 +0000 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-10-14 07:18:14 +0000 |
commit | 3329a497f21ee98ab85f000908ed6bb99e189ffc (patch) | |
tree | cae0a24bc73971f985d596c36ea6f2dce5456d09 /pkg/sentry/kernel/kernel_state_autogen.go | |
parent | 6a09acd73a2a4cedc3273e9446fc2d8737d45d0d (diff) | |
parent | a7b7b7b9804e9968c1fed5f7b3849233f585a88b (diff) |
Merge release-20200928.0-115-ga7b7b7b98 (automated)
Diffstat (limited to 'pkg/sentry/kernel/kernel_state_autogen.go')
-rw-r--r-- | pkg/sentry/kernel/kernel_state_autogen.go | 39 |
1 files changed, 33 insertions, 6 deletions
diff --git a/pkg/sentry/kernel/kernel_state_autogen.go b/pkg/sentry/kernel/kernel_state_autogen.go index d8ff396b7..b7d6d4f1c 100644 --- a/pkg/sentry/kernel/kernel_state_autogen.go +++ b/pkg/sentry/kernel/kernel_state_autogen.go @@ -242,6 +242,7 @@ func (i *IPCNamespace) StateTypeName() string { func (i *IPCNamespace) StateFields() []string { return []string{ + "IPCNamespaceRefs", "userNS", "semaphores", "shms", @@ -252,17 +253,42 @@ func (i *IPCNamespace) beforeSave() {} func (i *IPCNamespace) StateSave(stateSinkObject state.Sink) { i.beforeSave() - stateSinkObject.Save(0, &i.userNS) - stateSinkObject.Save(1, &i.semaphores) - stateSinkObject.Save(2, &i.shms) + stateSinkObject.Save(0, &i.IPCNamespaceRefs) + stateSinkObject.Save(1, &i.userNS) + stateSinkObject.Save(2, &i.semaphores) + stateSinkObject.Save(3, &i.shms) } func (i *IPCNamespace) afterLoad() {} func (i *IPCNamespace) StateLoad(stateSourceObject state.Source) { - stateSourceObject.Load(0, &i.userNS) - stateSourceObject.Load(1, &i.semaphores) - stateSourceObject.Load(2, &i.shms) + stateSourceObject.Load(0, &i.IPCNamespaceRefs) + stateSourceObject.Load(1, &i.userNS) + stateSourceObject.Load(2, &i.semaphores) + stateSourceObject.Load(3, &i.shms) +} + +func (r *IPCNamespaceRefs) StateTypeName() string { + return "pkg/sentry/kernel.IPCNamespaceRefs" +} + +func (r *IPCNamespaceRefs) StateFields() []string { + return []string{ + "refCount", + } +} + +func (r *IPCNamespaceRefs) beforeSave() {} + +func (r *IPCNamespaceRefs) StateSave(stateSinkObject state.Sink) { + r.beforeSave() + stateSinkObject.Save(0, &r.refCount) +} + +func (r *IPCNamespaceRefs) afterLoad() {} + +func (r *IPCNamespaceRefs) StateLoad(stateSourceObject state.Source) { + stateSourceObject.Load(0, &r.refCount) } func (k *Kernel) StateTypeName() string { @@ -2292,6 +2318,7 @@ func init() { state.Register((*FSContext)(nil)) state.Register((*FSContextRefs)(nil)) state.Register((*IPCNamespace)(nil)) + state.Register((*IPCNamespaceRefs)(nil)) state.Register((*Kernel)(nil)) state.Register((*SocketRecord)(nil)) state.Register((*SocketRecordVFS1)(nil)) |