summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/kernel/eventfd/eventfd_state_autogen.go
blob: ced262ffcd64f651bf6513fb1766d6ba90004346 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// automatically generated by stateify.

package eventfd

import (
	"gvisor.dev/gvisor/pkg/state"
)

func (x *EventOperations) beforeSave() {}
func (x *EventOperations) save(m state.Map) {
	x.beforeSave()
	if !state.IsZeroValue(x.wq) {
		m.Failf("wq is %v, expected zero", x.wq)
	}
	m.Save("val", &x.val)
	m.Save("semMode", &x.semMode)
	m.Save("hostfd", &x.hostfd)
}

func (x *EventOperations) afterLoad() {}
func (x *EventOperations) load(m state.Map) {
	m.Load("val", &x.val)
	m.Load("semMode", &x.semMode)
	m.Load("hostfd", &x.hostfd)
}

func init() {
	state.Register("eventfd.EventOperations", (*EventOperations)(nil), state.Fns{Save: (*EventOperations).save, Load: (*EventOperations).load})
}