Commit ad9f1a7e authored by Anton Altaparmakov's avatar Anton Altaparmakov

NTFS: Merge

parents fa44005c b6e3d6bc
...@@ -24,6 +24,11 @@ ToDo: ...@@ -24,6 +24,11 @@ ToDo:
- Want to use dummy inodes for address space i/o. We need some VFS - Want to use dummy inodes for address space i/o. We need some VFS
changes first, which are currently under discussion. changes first, which are currently under discussion.
2.0.7 - Minor cleanups and updates for changes in core kernel code.
- Remove much of the NULL struct element initializers.
- Various updates to make compatible with recent kernels.
2.0.6 - Major bugfix to make compatible with other kernel changes. 2.0.6 - Major bugfix to make compatible with other kernel changes.
- Initialize the mftbmp address space properly now that there are more - Initialize the mftbmp address space properly now that there are more
......
...@@ -7,7 +7,7 @@ obj-y := aops.o attrib.o compress.o debug.o dir.o file.o inode.o mft.o \ ...@@ -7,7 +7,7 @@ obj-y := aops.o attrib.o compress.o debug.o dir.o file.o inode.o mft.o \
obj-m := $(O_TARGET) obj-m := $(O_TARGET)
EXTRA_CFLAGS = -DNTFS_VERSION=\"2.0.6\" EXTRA_CFLAGS = -DNTFS_VERSION=\"2.0.7\"
ifeq ($(CONFIG_NTFS_DEBUG),y) ifeq ($(CONFIG_NTFS_DEBUG),y)
EXTRA_CFLAGS += -DDEBUG EXTRA_CFLAGS += -DDEBUG
......
...@@ -43,6 +43,5 @@ struct address_space_operations ntfs_attr_aops = { ...@@ -43,6 +43,5 @@ struct address_space_operations ntfs_attr_aops = {
disk request queue. */ disk request queue. */
prepare_write: NULL, /* . */ prepare_write: NULL, /* . */
commit_write: NULL, /* . */ commit_write: NULL, /* . */
//truncatepage: NULL, /* . */
}; };
...@@ -24,127 +24,13 @@ ...@@ -24,127 +24,13 @@
struct file_operations ntfs_file_ops = { struct file_operations ntfs_file_ops = {
llseek: generic_file_llseek, /* Seek inside file. */ llseek: generic_file_llseek, /* Seek inside file. */
read: generic_file_read, /* Read from file. */ read: generic_file_read, /* Read from file. */
write: NULL, /* . */
readdir: NULL, /* . */
poll: NULL, /* . */
ioctl: NULL, /* . */
mmap: generic_file_mmap, /* Mmap file. */ mmap: generic_file_mmap, /* Mmap file. */
open: generic_file_open, /* Open file. */ open: generic_file_open, /* Open file. */
flush: NULL, /* . */
release: NULL, /* . */
fsync: NULL, /* . */
fasync: NULL, /* . */
lock: NULL, /* . */
readv: NULL, /* . */
writev: NULL, /* . */
sendpage: NULL, /* . */
get_unmapped_area: NULL, /* . */
}; };
struct inode_operations ntfs_file_inode_ops = { struct inode_operations ntfs_file_inode_ops = {};
create: NULL, /* . */
lookup: NULL, /* . */
link: NULL, /* . */
unlink: NULL, /* . */
symlink: NULL, /* . */
mkdir: NULL, /* . */
rmdir: NULL, /* . */
mknod: NULL, /* . */
rename: NULL, /* . */
readlink: NULL, /* . */
follow_link: NULL, /* . */
truncate: NULL, /* . */
permission: NULL, /* . */
revalidate: NULL, /* . */
setattr: NULL, /* . */
getattr: NULL, /* . */
};
#if 0
/* NOTE: read, write, poll, fsync, readv, writev can be called without the big
* kernel lock held in all filesystems. */
struct file_operations {
struct module *owner;
loff_t (*llseek) (struct file *, loff_t, int);
ssize_t (*read) (struct file *, char *, size_t, loff_t *);
ssize_t (*write) (struct file *, const char *, size_t, loff_t *);
int (*readdir) (struct file *, void *, filldir_t);
unsigned int (*poll) (struct file *, struct poll_table_struct *);
int (*ioctl) (struct inode *, struct file *, unsigned int,
unsigned long);
int (*mmap) (struct file *, struct vm_area_struct *);
int (*flush) (struct file *);
int (*release) (struct inode *, struct file *);
int (*fsync) (struct file *, struct dentry *, int datasync);
int (*fasync) (int, struct file *, int);
int (*lock) (struct file *, int, struct file_lock *);
ssize_t (*readv) (struct file *, const struct iovec *, unsigned long,
loff_t *);
ssize_t (*writev) (struct file *, const struct iovec *, unsigned long,
loff_t *);
ssize_t (*sendpage) (struct file *, struct page *, int, size_t,
loff_t *, int);
unsigned long (*get_unmapped_area)(struct file *, unsigned long,
unsigned long, unsigned long, unsigned long);
};
struct inode_operations { struct file_operations ntfs_empty_file_ops = {};
int (*create) (struct inode *,struct dentry *,int);
struct dentry * (*lookup) (struct inode *,struct dentry *);
int (*link) (struct dentry *,struct inode *,struct dentry *);
int (*unlink) (struct inode *,struct dentry *);
int (*symlink) (struct inode *,struct dentry *,const char *);
int (*mkdir) (struct inode *,struct dentry *,int);
int (*rmdir) (struct inode *,struct dentry *);
int (*mknod) (struct inode *,struct dentry *,int,int);
int (*rename) (struct inode *, struct dentry *,
struct inode *, struct dentry *);
int (*readlink) (struct dentry *, char *,int);
int (*follow_link) (struct dentry *, struct nameidata *);
void (*truncate) (struct inode *);
int (*permission) (struct inode *, int);
int (*revalidate) (struct dentry *);
int (*setattr) (struct dentry *, struct iattr *);
int (*getattr) (struct dentry *, struct iattr *);
};
#endif
struct file_operations ntfs_empty_file_ops = { struct inode_operations ntfs_empty_inode_ops = {};
llseek: NULL, /* . */
read: NULL, /* . */
write: NULL, /* . */
readdir: NULL, /* . */
poll: NULL, /* . */
ioctl: NULL, /* . */
mmap: NULL, /* . */
open: NULL, /* . */
flush: NULL, /* . */
release: NULL, /* . */
fsync: NULL, /* . */
fasync: NULL, /* . */
lock: NULL, /* . */
readv: NULL, /* . */
writev: NULL, /* . */
sendpage: NULL, /* . */
get_unmapped_area: NULL, /* . */
};
struct inode_operations ntfs_empty_inode_ops = {
create: NULL, /* . */
lookup: NULL, /* . */
link: NULL, /* . */
unlink: NULL, /* . */
symlink: NULL, /* . */
mkdir: NULL, /* . */
rmdir: NULL, /* . */
mknod: NULL, /* . */
rename: NULL, /* . */
readlink: NULL, /* . */
follow_link: NULL, /* . */
truncate: NULL, /* . */
permission: NULL, /* . */
revalidate: NULL, /* . */
setattr: NULL, /* . */
getattr: NULL, /* . */
};
...@@ -114,13 +114,6 @@ struct address_space_operations ntfs_mft_aops = { ...@@ -114,13 +114,6 @@ struct address_space_operations ntfs_mft_aops = {
disk request queue. */ disk request queue. */
prepare_write: NULL, /* . */ prepare_write: NULL, /* . */
commit_write: NULL, /* . */ commit_write: NULL, /* . */
bmap: NULL, /* Needed for FIBMAP.
Don't use it. */
flushpage: NULL, /* . */
releasepage: NULL, /* . */
#ifdef KERNEL_HAS_O_DIRECT
direct_IO: NULL, /* . */
#endif
}; };
/** /**
......
...@@ -103,43 +103,6 @@ static struct dentry *ntfs_lookup(struct inode *dir_ino, struct dentry *dent) ...@@ -103,43 +103,6 @@ static struct dentry *ntfs_lookup(struct inode *dir_ino, struct dentry *dent)
} }
struct inode_operations ntfs_dir_inode_ops = { struct inode_operations ntfs_dir_inode_ops = {
create: NULL, /* . */
lookup: ntfs_lookup, /* lookup directory. */ lookup: ntfs_lookup, /* lookup directory. */
link: NULL, /* . */
unlink: NULL, /* . */
symlink: NULL, /* . */
mkdir: NULL, /* . */
rmdir: NULL, /* . */
mknod: NULL, /* . */
rename: NULL, /* . */
readlink: NULL, /* . */
follow_link: NULL, /* . */
truncate: NULL, /* . */
permission: NULL, /* . */
revalidate: NULL, /* . */
setattr: NULL, /* . */
getattr: NULL, /* . */
}; };
#if 0
struct inode_operations {
int (*create) (struct inode *,struct dentry *,int);
struct dentry * (*lookup) (struct inode *,struct dentry *);
int (*link) (struct dentry *,struct inode *,struct dentry *);
int (*unlink) (struct inode *,struct dentry *);
int (*symlink) (struct inode *,struct dentry *,const char *);
int (*mkdir) (struct inode *,struct dentry *,int);
int (*rmdir) (struct inode *,struct dentry *);
int (*mknod) (struct inode *,struct dentry *,int,int);
int (*rename) (struct inode *, struct dentry *,
struct inode *, struct dentry *);
int (*readlink) (struct dentry *, char *,int);
int (*follow_link) (struct dentry *, struct nameidata *);
void (*truncate) (struct inode *);
int (*permission) (struct inode *, int);
int (*revalidate) (struct dentry *);
int (*setattr) (struct dentry *, struct iattr *);
int (*getattr) (struct dentry *, struct iattr *);
};
#endif
...@@ -1424,24 +1424,23 @@ struct super_operations ntfs_sops = { ...@@ -1424,24 +1424,23 @@ struct super_operations ntfs_sops = {
called from iget(). */ called from iget(). */
dirty_inode: ntfs_dirty_inode, /* VFS: Called from dirty_inode: ntfs_dirty_inode, /* VFS: Called from
__mark_inode_dirty(). */ __mark_inode_dirty(). */
write_inode: NULL, /* VFS: Write dirty inode to disk. */ //write_inode: NULL, /* VFS: Write dirty inode to disk. */
put_inode: NULL, /* VFS: Called whenever the reference //put_inode: NULL, /* VFS: Called whenever the reference
count (i_count) of the inode is // count (i_count) of the inode is
going to be decreased but before the // going to be decreased but before the
actual decrease. */ // actual decrease. */
delete_inode: NULL, /* VFS: Delete inode from disk. Called //delete_inode: NULL, /* VFS: Delete inode from disk. Called
when i_count becomes 0 and i_nlink is // when i_count becomes 0 and i_nlink is
also 0. */ // also 0. */
put_super: ntfs_put_super, /* Syscall: umount. */ put_super: ntfs_put_super, /* Syscall: umount. */
write_super: NULL, /* Flush dirty super block to disk. */ //write_super: NULL, /* Flush dirty super block to disk. */
write_super_lockfs: NULL, /* ? */ //write_super_lockfs: NULL, /* ? */
unlockfs: NULL, /* ? */ //unlockfs: NULL, /* ? */
statfs: ntfs_statfs, /* Syscall: statfs */ statfs: ntfs_statfs, /* Syscall: statfs */
remount_fs: ntfs_remount, /* Syscall: mount -o remount. */ remount_fs: ntfs_remount, /* Syscall: mount -o remount. */
clear_inode: ntfs_clear_big_inode, /* VFS: Called when an inode is clear_inode: ntfs_clear_big_inode, /* VFS: Called when an inode is
removed from memory. */ removed from memory. */
umount_begin: NULL, /* Forced umount. */ //umount_begin: NULL, /* Forced umount. */
show_options: ntfs_show_options, /* Show mount options in proc. */ show_options: ntfs_show_options, /* Show mount options in proc. */
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment