Block I/O Buffer Cache Kernel Services: Overview
The Block I/O Buffer Cache services are provided to support user access to device drivers through block I/O special files.
This access is required by the operating system file system for mounts and other limited activity, as well as for compatibility services required when other file systems are installed on these kinds of systems. These services are not used by the operating system's JFS (journal file system), NFS (Network File System), or CDRFS (CD-ROM file system) when processing standard file I/O data. Instead they use the virtual memory manager and pager to manage the system's memory pages as a buffer cache.
For compatibility support of other file systems and block special file support, the buffer cache services serve two important purposes:
- They ensure that multiple processes accessing the same block of the same device in multiprogrammed fashion maintain a consistent view of the data in the block.
- They increase the efficiency of the system by keeping in-memory copies of blocks that are frequently accessed.
The Buffer Cache services use the buf structure or buffer header as their main data-tracking mechanism. Each buffer header contains a pair of pointers that maintains a doubly-linked list of buffers associated with a particular block device. An additional pair of pointers maintain a doubly-linked list of blocks available for use again on another operation. Buffers that have I/O in progress or that are busy for other purposes do not appear in this available list.
Kernel buffers are discussed in more detail in Introduction to Kernel Buffers.
See Block I/O Kernel Services for a list of these services.