[Bug 273962] copy_file_range does not work on shared memory objects
- In reply to: bugzilla-noreply_a_freebsd.org: "[Bug 273962] copy_file_range does not work on shared memory objects"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 20 Sep 2023 21:48:22 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=273962 --- Comment #7 from Rick Macklem <rmacklem@FreeBSD.org> --- Now that I have taken a quick look, doing the shared memory fallback will be quite a bit of work, given the range locking stuff. Something like: - Define a new f_op (f_copy_file_range()). - Factor most of the contents of kern_copy_file_range() out into a vn_fileop_copy_file_range(). - Call the new f_op from kern_copy_file_range() - Write a shm_copy_file_range() f_op that is similar to the vnode one, but uses the shmfd stuff for rangelocking and then does the copying (via memcpy() in some sort of loop or maybe uiomove() needs to be used?). - I am not sure what this last step requires. Not that big a deal, but not that easy. -- You are receiving this mail because: You are the assignee for the bug.