Page MenuHomeFreeBSD

freebsd32 shims for copy_file_range(2)
ClosedPublic

Authored by kib on Jul 27 2019, 8:57 PM.

Details

Test Plan

Rick, could you, please, provide me with the test program you used for the syscall check ?

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

kib created this revision.Jul 27 2019, 8:57 PM

I don't really know anything about this, but it looks fine to me.
The only change is uint32_t replaces size_t, which makes sense to 32bits.
(I'm guessing this is only used for amd64, where "int" and "unsigned int"
remain 32bits.)

Hopefully brooks can review this, but if not, I'll click reviewed in a few days.

Why is a shim required? All arguments are extended to 64-bits as part of the combat layer. There would be an issue if len were an off_t, but it's a size_t. The only pointers point to off_t's which are always 64-bit and thus require no special handling.

kib added a comment.Jul 29 2019, 8:40 PM

Why is a shim required? All arguments are extended to 64-bits as part of the combat layer. There would be an issue if len were an off_t, but it's a size_t. The only pointers point to off_t's which are always 64-bit and thus require no special handling.

Yes, it started with len having off_t, see some discussion on fs@. I am on fence there, I can drop the shim and change STD to NOPROTO, of course.

kib updated this revision to Diff 60269.Jul 30 2019, 11:08 AM

Drop shims.

brooks accepted this revision.Jul 30 2019, 10:16 PM

LGTM

This revision is now accepted and ready to land.Jul 30 2019, 10:16 PM
This revision was automatically updated to reflect the committed changes.