ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.6.tar.bz2
[linux-2.6.git] / fs / sysv / symlink.c
1 /*
2  *  linux/fs/sysv/symlink.c
3  *
4  *  Handling of System V filesystem fast symlinks extensions.
5  *  Aug 2001, Christoph Hellwig (hch@infradead.org)
6  */
7
8 #include "sysv.h"
9
10 static int sysv_readlink(struct dentry *dentry, char *buffer, int buflen)
11 {
12         char *s = (char *)SYSV_I(dentry->d_inode)->i_data;
13         return vfs_readlink(dentry, buffer, buflen, s);
14 }
15
16 static int sysv_follow_link(struct dentry *dentry, struct nameidata *nd)
17 {
18         char *s = (char *)SYSV_I(dentry->d_inode)->i_data;
19         return vfs_follow_link(nd, s);
20 }
21
22 struct inode_operations sysv_fast_symlink_inode_operations = {
23         .readlink       = sysv_readlink,
24         .follow_link    = sysv_follow_link,
25 };