Skip to content

Commit

Permalink
9p: Add fscache support to 9p
Browse files Browse the repository at this point in the history
This patch adds a persistent, read-only caching facility for
9p clients using the FS-Cache caching backend.

When the fscache facility is enabled, each inode is associated
with a corresponding vcookie which is an index into the FS-Cache
indexing tree. The FS-Cache indexing tree is indexed at 3 levels:
- session object associated with each mount.
- inode/vcookie
- actual data (pages)

A cache tag is chosen randomly for each session. These tags can
be read off /sys/fs/9p/caches and can be passed as a mount-time
parameter to re-attach to the specified caching session.

Signed-off-by: Abhishek Kulkarni <[email protected]>
Signed-off-by: Eric Van Hensbergen <[email protected]>
  • Loading branch information
Abhishek Kulkarni authored and Eric Van Hensbergen committed Sep 23, 2009
1 parent 637d020 commit 60e78d2
Show file tree
Hide file tree
Showing 12 changed files with 1,009 additions and 42 deletions.
9 changes: 9 additions & 0 deletions fs/9p/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,12 @@ config 9P_FS
See <http://v9fs.sf.net> for more information.

If unsure, say N.

config 9P_FSCACHE
bool "Enable 9P client caching support (EXPERIMENTAL)"
depends on EXPERIMENTAL
depends on 9P_FS=m && FSCACHE || 9P_FS=y && FSCACHE=y
help
Choose Y here to enable persistent, read-only local
caching support for 9p clients using FS-Cache

3 changes: 2 additions & 1 deletion fs/9p/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@ obj-$(CONFIG_9P_FS) := 9p.o
vfs_dir.o \
vfs_dentry.o \
v9fs.o \
fid.o \
fid.o

9p-$(CONFIG_9P_FSCACHE) += cache.o
Loading

0 comments on commit 60e78d2

Please sign in to comment.