• Linux 6.6.21-gentoo
  • OpenZFS 2.2.2
  • Go 1.22.4
  • x/sys 0.22.0

Test log:

ok      golang.org/x/sys/cpu    0.002s
ok      golang.org/x/sys/execabs        0.003s
--- FAIL: TestIoctlFileDedupeRange (0.00s)
    syscall_linux_test.go:1093: Unexpected error in FileDedupeRange: ENOTSUP
    syscall_linux_test.go:1098: Unexpected amount of bytes deduped 0 != 4096
    syscall_linux_test.go:1108: Unexpected error in FileDedupeRange: ENOTSUP
FAIL
FAIL    golang.org/x/sys/unix   0.594s
FAIL

Comment From: lanodan

Also seems to be reproducible inside a tmpfs.

Comment From: gopherbot

Change https://go.dev/cl/597555 mentions this issue: unix: skip TestIoctlFileDedupeRange on EOPNOTSUPP error

Comment From: cagedmantis

cc @golang/runtime

Comment From: lanodan

Change https://go.dev/cl/597555 mentions this issue: unix: skip TestIoctlFileDedupeRange on EOPNOTSUPP error

With this change tests pass successfully.

Thanks!