Readfile System Call Patches Revisited For Efficiently Reading Small Files
![LINUX STORAGE](/assets/categories/linuxstorage.webp)
The readfile system call is rather simple and intended to simply open the given file, read it into the buffer, and close the file -- all within that single call rather than handling each of those steps separately. The intent is to use the readfile system call if frequently reading "tiny" to "small" files like those exposed under sysfs, procfs, etc.
The single system call approach should be more efficient with less syscall overhead, particularly if frequently reading to many small files.
As of Friday, Greg KH has re-based the readfile syscall patch, self tests, and related documentation on his driver-core.git's "readfile" branch.
As of writing the patches haven't yet worked their way to Greg's driver-core-next branch, but seeing the freshly updated readfile branch gives hope once again this simple system call may finally land after 2+ years of talk.
15 Comments