File I/O and copying

Skip to first unread message

Steve Keller

Feb 8, 2019, 6:39:51 AM2/8/19
I'd like to understand how file I/O is typically handled on todays PCs
or servers running any modern Unix (*BSD, Linux, etc.).

How much copying is involved when I read from a file using the read
system call? And does this depend on alignment of my user space
buffer that I read into?

Can the I/O hardware and block device driver (maybe using DMA) copy
directly to user space, and if so to any address or are there
alignment constraints? Or is data copied to a kernel buffer first and
then copied to user space?

Reply all
Reply to author
0 new messages