git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vserver 1.9.5.x5
[linux-2.6.git]
/
fs
/
hostfs
/
hostfs_kern.c
diff --git
a/fs/hostfs/hostfs_kern.c
b/fs/hostfs/hostfs_kern.c
index
7d42da0
..
144ff70
100644
(file)
--- a/
fs/hostfs/hostfs_kern.c
+++ b/
fs/hostfs/hostfs_kern.c
@@
-15,7
+15,6
@@
#include <linux/pagemap.h>
#include <linux/blkdev.h>
#include <linux/list.h>
#include <linux/pagemap.h>
#include <linux/blkdev.h>
#include <linux/list.h>
-#include <linux/buffer_head.h>
#include <linux/root_dev.h>
#include <linux/statfs.h>
#include <linux/kdev_t.h>
#include <linux/root_dev.h>
#include <linux/statfs.h>
#include <linux/kdev_t.h>
@@
-393,6
+392,11
@@
int hostfs_fsync(struct file *file, struct dentry *dentry, int datasync)
static struct file_operations hostfs_file_fops = {
.llseek = generic_file_llseek,
.read = generic_file_read,
static struct file_operations hostfs_file_fops = {
.llseek = generic_file_llseek,
.read = generic_file_read,
+ .sendfile = generic_file_sendfile,
+ .aio_read = generic_file_aio_read,
+ .aio_write = generic_file_aio_write,
+ .readv = generic_file_readv,
+ .writev = generic_file_writev,
.write = generic_file_write,
.mmap = generic_file_mmap,
.open = hostfs_file_open,
.write = generic_file_write,
.mmap = generic_file_mmap,
.open = hostfs_file_open,
@@
-401,6
+405,7
@@
static struct file_operations hostfs_file_fops = {
};
static struct file_operations hostfs_dir_fops = {
};
static struct file_operations hostfs_dir_fops = {
+ .llseek = generic_file_llseek,
.readdir = hostfs_readdir,
.read = generic_read_dir,
};
.readdir = hostfs_readdir,
.read = generic_read_dir,
};
@@
-808,7
+813,7
@@
int hostfs_permission(struct inode *ino, int desired, struct nameidata *nd)
if(name == NULL) return(-ENOMEM);
err = access_file(name, r, w, x);
kfree(name);
if(name == NULL) return(-ENOMEM);
err = access_file(name, r, w, x);
kfree(name);
- if(!err) err =
vfs_permission(ino, desired
);
+ if(!err) err =
generic_permission(ino, desired, NULL
);
return(err);
}
return(err);
}
@@
-818,6
+823,10
@@
int hostfs_setattr(struct dentry *dentry, struct iattr *attr)
char *name;
int err;
char *name;
int err;
+ err = inode_change_ok(dentry->d_inode, attr);
+ if (err)
+ return err;
+
if(append)
attr->ia_valid &= ~ATTR_SIZE;
if(append)
attr->ia_valid &= ~ATTR_SIZE;