bytecodealliance / userfaultfd-rs

Rust bindings for the Linux userfaultfd functionality
Apache License 2.0
43 stars 22 forks source link

Add PartiallyCopied error for copy() #36

Closed kawasin73 closed 1 year ago

kawasin73 commented 2 years ago

UFFDIO_COPY returns EAGAIN when "The number of bytes copied (i.e., the value returned in the copy field) does not equal the value that was specified in the len field." (the man page: https://man7.org/linux/man-pages/man2/ioctl_userfaultfd.2.html)

We need the copy field of struct uffdio_copy to retry copying.

pchickey commented 1 year ago

Sorry for the delay!