Skip to content

syncthing: Enable inotify on x86_64#174

Merged
chenxiaolong merged 1 commit into
masterfrom
epoll-wait
Jun 20, 2026
Merged

syncthing: Enable inotify on x86_64#174
chenxiaolong merged 1 commit into
masterfrom
epoll-wait

Conversation

@chenxiaolong

Copy link
Copy Markdown
Owner

Upstream Syncthing currently disables inotify on Android x86_64 because it uses golang.org/x/sys's unix.EpollWait function, which is implemented in terms of epoll_wait on x86_64. That syscall is blocked by Android's x86_64 seccomp policy.

I've reported this at golang/go#80080, but in the meantime, we can temporarily fork the golang.org/x/sys package to make it use epoll_pwait (same as what bionic libc does) on x86_64.

This allow file watchers to work in the Android emulator.

Upstream Syncthing currently disables inotify on Android x86_64 because
it uses golang.org/x/sys's unix.EpollWait function, which is implemented
in terms of epoll_wait on x86_64. That syscall is blocked by Android's
x86_64 seccomp policy.

I've reported this at golang/go#80080, but in
the meantime, we can temporarily fork the golang.org/x/sys package to
make it use epoll_pwait (same as what bionic libc does) on x86_64.

This allow file watchers to work in the Android emulator.

Signed-off-by: Andrew Gunnerson <accounts+github@chiller3.com>
@chenxiaolong chenxiaolong self-assigned this Jun 20, 2026
chenxiaolong added a commit that referenced this pull request Jun 20, 2026
Signed-off-by: Andrew Gunnerson <accounts+github@chiller3.com>
@chenxiaolong chenxiaolong merged commit 3efef71 into master Jun 20, 2026
1 check passed
@chenxiaolong chenxiaolong deleted the epoll-wait branch June 20, 2026 00:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant