summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/kernel/epoll/epoll_state.go
diff options
context:
space:
mode:
authorTamir Duberstein <tamird@google.com>2020-06-25 14:17:00 -0700
committergVisor bot <gvisor-bot@google.com>2020-06-25 14:18:33 -0700
commit4069461877d843654d18db74a5962b332f1226aa (patch)
tree48affc2bd8c7de9ae5f2cd19307c7ccbb63553b9 /pkg/sentry/kernel/epoll/epoll_state.go
parent00ee5abaa70965b1baad996f53d3dc2a17805fcf (diff)
Avoid an allocation in epoll
PiperOrigin-RevId: 318346153
Diffstat (limited to 'pkg/sentry/kernel/epoll/epoll_state.go')
-rw-r--r--pkg/sentry/kernel/epoll/epoll_state.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/sentry/kernel/epoll/epoll_state.go b/pkg/sentry/kernel/epoll/epoll_state.go
index 02f9aabfa..7c61e0258 100644
--- a/pkg/sentry/kernel/epoll/epoll_state.go
+++ b/pkg/sentry/kernel/epoll/epoll_state.go
@@ -21,7 +21,7 @@ import (
// afterLoad is invoked by stateify.
func (p *pollEntry) afterLoad() {
- p.waiter.Callback = &readyCallback{context: p}
+ p.waiter.Callback = p
p.file = refs.NewWeakRef(p.id.File, p)
p.id.File.EventRegister(&p.waiter, p.mask)
}