summaryrefslogtreecommitdiffhomepage
path: root/pkg/bpf
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-06-24 06:37:35 +0000
committergVisor bot <gvisor-bot@google.com>2020-06-24 06:37:35 +0000
commit9183888b520beeee8609170819a28bea89202909 (patch)
tree3cdcfa4de9ced4c539ab7c57e4cf58ffea980f6c /pkg/bpf
parentcab13958a54419262aba2a0cd7f1075ed02c8ee0 (diff)
parent364ac92baf83f2352f78b718090472639bd92a76 (diff)
Merge release-20200608.0-119-g364ac92ba (automated)
Diffstat (limited to 'pkg/bpf')
-rw-r--r--pkg/bpf/bpf_state_autogen.go22
1 files changed, 17 insertions, 5 deletions
diff --git a/pkg/bpf/bpf_state_autogen.go b/pkg/bpf/bpf_state_autogen.go
index ae8a36d57..43dd9ff9e 100644
--- a/pkg/bpf/bpf_state_autogen.go
+++ b/pkg/bpf/bpf_state_autogen.go
@@ -6,17 +6,29 @@ import (
"gvisor.dev/gvisor/pkg/state"
)
+func (x *Program) StateTypeName() string {
+ return "pkg/bpf.Program"
+}
+
+func (x *Program) StateFields() []string {
+ return []string{
+ "instructions",
+ }
+}
+
func (x *Program) beforeSave() {}
-func (x *Program) save(m state.Map) {
+
+func (x *Program) StateSave(m state.Sink) {
x.beforeSave()
- m.Save("instructions", &x.instructions)
+ m.Save(0, &x.instructions)
}
func (x *Program) afterLoad() {}
-func (x *Program) load(m state.Map) {
- m.Load("instructions", &x.instructions)
+
+func (x *Program) StateLoad(m state.Source) {
+ m.Load(0, &x.instructions)
}
func init() {
- state.Register("pkg/bpf.Program", (*Program)(nil), state.Fns{Save: (*Program).save, Load: (*Program).load})
+ state.Register((*Program)(nil))
}