diff options
Diffstat (limited to 'fs')
| -rw-r--r-- | fs/fuse/dev.c | 4 | ||||
| -rw-r--r-- | fs/fuse/file.c | 84 | ||||
| -rw-r--r-- | fs/fuse/fuse_i.h | 8 | ||||
| -rw-r--r-- | fs/fuse/inode.c | 10 | ||||
| -rw-r--r-- | fs/hugetlbfs/inode.c | 1 | ||||
| -rw-r--r-- | fs/inode.c | 24 | ||||
| -rw-r--r-- | fs/xfs/Makefile | 119 | ||||
| -rw-r--r-- | fs/xfs/kmem.c (renamed from fs/xfs/linux-2.6/kmem.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/kmem.h (renamed from fs/xfs/linux-2.6/kmem.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/mrlock.h (renamed from fs/xfs/linux-2.6/mrlock.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/time.h (renamed from fs/xfs/linux-2.6/time.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/uuid.c (renamed from fs/xfs/support/uuid.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/uuid.h (renamed from fs/xfs/support/uuid.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs.h | 3 | ||||
| -rw-r--r-- | fs/xfs/xfs_acl.c (renamed from fs/xfs/linux-2.6/xfs_acl.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_aops.c (renamed from fs/xfs/linux-2.6/xfs_aops.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_aops.h (renamed from fs/xfs/linux-2.6/xfs_aops.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_buf.c (renamed from fs/xfs/linux-2.6/xfs_buf.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_buf.h (renamed from fs/xfs/linux-2.6/xfs_buf.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_discard.c (renamed from fs/xfs/linux-2.6/xfs_discard.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_discard.h (renamed from fs/xfs/linux-2.6/xfs_discard.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_dquot.c (renamed from fs/xfs/quota/xfs_dquot.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_dquot.h (renamed from fs/xfs/quota/xfs_dquot.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_dquot_item.c (renamed from fs/xfs/quota/xfs_dquot_item.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_dquot_item.h (renamed from fs/xfs/quota/xfs_dquot_item.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_export.c (renamed from fs/xfs/linux-2.6/xfs_export.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_export.h (renamed from fs/xfs/linux-2.6/xfs_export.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_file.c (renamed from fs/xfs/linux-2.6/xfs_file.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_fs_subr.c (renamed from fs/xfs/linux-2.6/xfs_fs_subr.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_globals.c (renamed from fs/xfs/linux-2.6/xfs_globals.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_ioctl.c (renamed from fs/xfs/linux-2.6/xfs_ioctl.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_ioctl.h (renamed from fs/xfs/linux-2.6/xfs_ioctl.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_ioctl32.c (renamed from fs/xfs/linux-2.6/xfs_ioctl32.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_ioctl32.h (renamed from fs/xfs/linux-2.6/xfs_ioctl32.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_iops.c (renamed from fs/xfs/linux-2.6/xfs_iops.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_iops.h (renamed from fs/xfs/linux-2.6/xfs_iops.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_linux.h (renamed from fs/xfs/linux-2.6/xfs_linux.h) | 27 | ||||
| -rw-r--r-- | fs/xfs/xfs_message.c (renamed from fs/xfs/linux-2.6/xfs_message.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_message.h (renamed from fs/xfs/linux-2.6/xfs_message.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm.c (renamed from fs/xfs/quota/xfs_qm.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm.h (renamed from fs/xfs/quota/xfs_qm.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm_bhv.c (renamed from fs/xfs/quota/xfs_qm_bhv.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm_stats.c (renamed from fs/xfs/quota/xfs_qm_stats.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm_stats.h (renamed from fs/xfs/quota/xfs_qm_stats.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_qm_syscalls.c (renamed from fs/xfs/quota/xfs_qm_syscalls.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_quota_priv.h (renamed from fs/xfs/quota/xfs_quota_priv.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_quotaops.c (renamed from fs/xfs/linux-2.6/xfs_quotaops.c) | 2 | ||||
| -rw-r--r-- | fs/xfs/xfs_stats.c (renamed from fs/xfs/linux-2.6/xfs_stats.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_stats.h (renamed from fs/xfs/linux-2.6/xfs_stats.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_super.c (renamed from fs/xfs/linux-2.6/xfs_super.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_super.h (renamed from fs/xfs/linux-2.6/xfs_super.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_sync.c (renamed from fs/xfs/linux-2.6/xfs_sync.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_sync.h (renamed from fs/xfs/linux-2.6/xfs_sync.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_sysctl.c (renamed from fs/xfs/linux-2.6/xfs_sysctl.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_sysctl.h (renamed from fs/xfs/linux-2.6/xfs_sysctl.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_trace.c (renamed from fs/xfs/linux-2.6/xfs_trace.c) | 4 | ||||
| -rw-r--r-- | fs/xfs/xfs_trace.h (renamed from fs/xfs/linux-2.6/xfs_trace.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_trans_dquot.c (renamed from fs/xfs/quota/xfs_trans_dquot.c) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_vnode.h (renamed from fs/xfs/linux-2.6/xfs_vnode.h) | 0 | ||||
| -rw-r--r-- | fs/xfs/xfs_xattr.c (renamed from fs/xfs/linux-2.6/xfs_xattr.c) | 0 | 
60 files changed, 124 insertions, 162 deletions
diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c index 640fc229df1..168a80f7f12 100644 --- a/fs/fuse/dev.c +++ b/fs/fuse/dev.c @@ -1358,6 +1358,10 @@ static int fuse_notify_inval_entry(struct fuse_conn *fc, unsigned int size,  	if (outarg.namelen > FUSE_NAME_MAX)  		goto err; +	err = -EINVAL; +	if (size != sizeof(outarg) + outarg.namelen + 1) +		goto err; +  	name.name = buf;  	name.len = outarg.namelen;  	err = fuse_copy_one(cs, buf, outarg.namelen + 1); diff --git a/fs/fuse/file.c b/fs/fuse/file.c index d480d9af46c..594f07a81c2 100644 --- a/fs/fuse/file.c +++ b/fs/fuse/file.c @@ -14,6 +14,7 @@  #include <linux/sched.h>  #include <linux/module.h>  #include <linux/compat.h> +#include <linux/swap.h>  static const struct file_operations fuse_direct_io_file_operations; @@ -245,6 +246,12 @@ void fuse_release_common(struct file *file, int opcode)  	req = ff->reserved_req;  	fuse_prepare_release(ff, file->f_flags, opcode); +	if (ff->flock) { +		struct fuse_release_in *inarg = &req->misc.release.in; +		inarg->release_flags |= FUSE_RELEASE_FLOCK_UNLOCK; +		inarg->lock_owner = fuse_lock_owner_id(ff->fc, +						       (fl_owner_t) file); +	}  	/* Hold vfsmount and dentry until release is finished */  	path_get(&file->f_path);  	req->misc.release.path = file->f_path; @@ -755,18 +762,6 @@ static size_t fuse_send_write(struct fuse_req *req, struct file *file,  	return req->misc.write.out.size;  } -static int fuse_write_begin(struct file *file, struct address_space *mapping, -			loff_t pos, unsigned len, unsigned flags, -			struct page **pagep, void **fsdata) -{ -	pgoff_t index = pos >> PAGE_CACHE_SHIFT; - -	*pagep = grab_cache_page_write_begin(mapping, index, flags); -	if (!*pagep) -		return -ENOMEM; -	return 0; -} -  void fuse_write_update_size(struct inode *inode, loff_t pos)  {  	struct fuse_conn *fc = get_fuse_conn(inode); @@ -779,62 +774,6 @@ void fuse_write_update_size(struct inode *inode, loff_t pos)  	spin_unlock(&fc->lock);  } -static int fuse_buffered_write(struct file *file, struct inode *inode, -			       loff_t pos, unsigned count, struct page *page) -{ -	int err; -	size_t nres; -	struct fuse_conn *fc = get_fuse_conn(inode); -	unsigned offset = pos & (PAGE_CACHE_SIZE - 1); -	struct fuse_req *req; - -	if (is_bad_inode(inode)) -		return -EIO; - -	/* -	 * Make sure writepages on the same page are not mixed up with -	 * plain writes. -	 */ -	fuse_wait_on_page_writeback(inode, page->index); - -	req = fuse_get_req(fc); -	if (IS_ERR(req)) -		return PTR_ERR(req); - -	req->in.argpages = 1; -	req->num_pages = 1; -	req->pages[0] = page; -	req->page_offset = offset; -	nres = fuse_send_write(req, file, pos, count, NULL); -	err = req->out.h.error; -	fuse_put_request(fc, req); -	if (!err && !nres) -		err = -EIO; -	if (!err) { -		pos += nres; -		fuse_write_update_size(inode, pos); -		if (count == PAGE_CACHE_SIZE) -			SetPageUptodate(page); -	} -	fuse_invalidate_attr(inode); -	return err ? err : nres; -} - -static int fuse_write_end(struct file *file, struct address_space *mapping, -			loff_t pos, unsigned len, unsigned copied, -			struct page *page, void *fsdata) -{ -	struct inode *inode = mapping->host; -	int res = 0; - -	if (copied) -		res = fuse_buffered_write(file, inode, pos, copied, page); - -	unlock_page(page); -	page_cache_release(page); -	return res; -} -  static size_t fuse_send_write_pages(struct fuse_req *req, struct file *file,  				    struct inode *inode, loff_t pos,  				    size_t count) @@ -908,6 +847,8 @@ static ssize_t fuse_fill_write_pages(struct fuse_req *req,  		pagefault_enable();  		flush_dcache_page(page); +		mark_page_accessed(page); +  		if (!tmp) {  			unlock_page(page);  			page_cache_release(page); @@ -1559,11 +1500,14 @@ static int fuse_file_flock(struct file *file, int cmd, struct file_lock *fl)  	struct fuse_conn *fc = get_fuse_conn(inode);  	int err; -	if (fc->no_lock) { +	if (fc->no_flock) {  		err = flock_lock_file_wait(file, fl);  	} else { +		struct fuse_file *ff = file->private_data; +  		/* emulate flock with POSIX locks */  		fl->fl_owner = (fl_owner_t) file; +		ff->flock = true;  		err = fuse_setlk(file, fl, 1);  	} @@ -2201,8 +2145,6 @@ static const struct address_space_operations fuse_file_aops  = {  	.readpage	= fuse_readpage,  	.writepage	= fuse_writepage,  	.launder_page	= fuse_launder_page, -	.write_begin	= fuse_write_begin, -	.write_end	= fuse_write_end,  	.readpages	= fuse_readpages,  	.set_page_dirty	= __set_page_dirty_nobuffers,  	.bmap		= fuse_bmap, diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h index c6aa2d4b851..cf6db0a9321 100644 --- a/fs/fuse/fuse_i.h +++ b/fs/fuse/fuse_i.h @@ -135,6 +135,9 @@ struct fuse_file {  	/** Wait queue head for poll */  	wait_queue_head_t poll_wait; + +	/** Has flock been performed on this file? */ +	bool flock:1;  };  /** One input argument of a request */ @@ -448,7 +451,7 @@ struct fuse_conn {  	/** Is removexattr not implemented by fs? */  	unsigned no_removexattr:1; -	/** Are file locking primitives not implemented by fs? */ +	/** Are posix file locking primitives not implemented by fs? */  	unsigned no_lock:1;  	/** Is access not implemented by fs? */ @@ -472,6 +475,9 @@ struct fuse_conn {  	/** Don't apply umask to creation modes */  	unsigned dont_mask:1; +	/** Are BSD file locking primitives not implemented by fs? */ +	unsigned no_flock:1; +  	/** The number of requests waiting for completion */  	atomic_t num_waiting; diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index 38f84cd48b6..12b502929da 100644 --- a/fs/fuse/inode.c +++ b/fs/fuse/inode.c @@ -71,7 +71,7 @@ struct fuse_mount_data {  	unsigned blksize;  }; -struct fuse_forget_link *fuse_alloc_forget() +struct fuse_forget_link *fuse_alloc_forget(void)  {  	return kzalloc(sizeof(struct fuse_forget_link), GFP_KERNEL);  } @@ -809,6 +809,10 @@ static void process_init_reply(struct fuse_conn *fc, struct fuse_req *req)  				fc->async_read = 1;  			if (!(arg->flags & FUSE_POSIX_LOCKS))  				fc->no_lock = 1; +			if (arg->minor >= 17) { +				if (!(arg->flags & FUSE_FLOCK_LOCKS)) +					fc->no_flock = 1; +			}  			if (arg->flags & FUSE_ATOMIC_O_TRUNC)  				fc->atomic_o_trunc = 1;  			if (arg->minor >= 9) { @@ -823,6 +827,7 @@ static void process_init_reply(struct fuse_conn *fc, struct fuse_req *req)  		} else {  			ra_pages = fc->max_read / PAGE_CACHE_SIZE;  			fc->no_lock = 1; +			fc->no_flock = 1;  		}  		fc->bdi.ra_pages = min(fc->bdi.ra_pages, ra_pages); @@ -843,7 +848,8 @@ static void fuse_send_init(struct fuse_conn *fc, struct fuse_req *req)  	arg->minor = FUSE_KERNEL_MINOR_VERSION;  	arg->max_readahead = fc->bdi.ra_pages * PAGE_CACHE_SIZE;  	arg->flags |= FUSE_ASYNC_READ | FUSE_POSIX_LOCKS | FUSE_ATOMIC_O_TRUNC | -		FUSE_EXPORT_SUPPORT | FUSE_BIG_WRITES | FUSE_DONT_MASK; +		FUSE_EXPORT_SUPPORT | FUSE_BIG_WRITES | FUSE_DONT_MASK | +		FUSE_FLOCK_LOCKS;  	req->in.h.opcode = FUSE_INIT;  	req->in.numargs = 1;  	req->in.args[0].size = sizeof(*arg); diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c index 87b6e0421c1..ec889538e5a 100644 --- a/fs/hugetlbfs/inode.c +++ b/fs/hugetlbfs/inode.c @@ -491,6 +491,7 @@ static struct inode *hugetlbfs_get_inode(struct super_block *sb, uid_t uid,  			inode->i_op = &page_symlink_inode_operations;  			break;  		} +		lockdep_annotate_inode_mutex_key(inode);  	}  	return inode;  } diff --git a/fs/inode.c b/fs/inode.c index 73920d555c8..ec7924696a1 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -848,16 +848,9 @@ struct inode *new_inode(struct super_block *sb)  }  EXPORT_SYMBOL(new_inode); -/** - * unlock_new_inode - clear the I_NEW state and wake up any waiters - * @inode:	new inode to unlock - * - * Called when the inode is fully initialised to clear the new state of the - * inode and wake up anyone waiting for the inode to finish initialisation. - */ -void unlock_new_inode(struct inode *inode) -{  #ifdef CONFIG_DEBUG_LOCK_ALLOC +void lockdep_annotate_inode_mutex_key(struct inode *inode) +{  	if (S_ISDIR(inode->i_mode)) {  		struct file_system_type *type = inode->i_sb->s_type; @@ -873,7 +866,20 @@ void unlock_new_inode(struct inode *inode)  					  &type->i_mutex_dir_key);  		}  	} +} +EXPORT_SYMBOL(lockdep_annotate_inode_mutex_key);  #endif + +/** + * unlock_new_inode - clear the I_NEW state and wake up any waiters + * @inode:	new inode to unlock + * + * Called when the inode is fully initialised to clear the new state of the + * inode and wake up anyone waiting for the inode to finish initialisation. + */ +void unlock_new_inode(struct inode *inode) +{ +	lockdep_annotate_inode_mutex_key(inode);  	spin_lock(&inode->i_lock);  	WARN_ON(!(inode->i_state & I_NEW));  	inode->i_state &= ~I_NEW; diff --git a/fs/xfs/Makefile b/fs/xfs/Makefile index 75bb316529d..427a4e82a58 100644 --- a/fs/xfs/Makefile +++ b/fs/xfs/Makefile @@ -16,44 +16,53 @@  # Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA  # -ccflags-y := -I$(src) -I$(src)/linux-2.6 -ccflags-$(CONFIG_XFS_DEBUG) += -g +ccflags-y += -I$(src)			# needed for trace events -XFS_LINUX := linux-2.6 +ccflags-$(CONFIG_XFS_DEBUG) += -g  obj-$(CONFIG_XFS_FS)		+= xfs.o -xfs-y				+= linux-2.6/xfs_trace.o - -xfs-$(CONFIG_XFS_QUOTA)		+= $(addprefix quota/, \ -				   xfs_dquot.o \ -				   xfs_dquot_item.o \ -				   xfs_trans_dquot.o \ -				   xfs_qm_syscalls.o \ -				   xfs_qm_bhv.o \ -				   xfs_qm.o) -xfs-$(CONFIG_XFS_QUOTA)		+= linux-2.6/xfs_quotaops.o - -ifeq ($(CONFIG_XFS_QUOTA),y) -xfs-$(CONFIG_PROC_FS)		+= quota/xfs_qm_stats.o -endif - -xfs-$(CONFIG_XFS_RT)		+= xfs_rtalloc.o -xfs-$(CONFIG_XFS_POSIX_ACL)	+= $(XFS_LINUX)/xfs_acl.o -xfs-$(CONFIG_PROC_FS)		+= $(XFS_LINUX)/xfs_stats.o -xfs-$(CONFIG_SYSCTL)		+= $(XFS_LINUX)/xfs_sysctl.o -xfs-$(CONFIG_COMPAT)		+= $(XFS_LINUX)/xfs_ioctl32.o +# this one should be compiled first, as the tracing macros can easily blow up +xfs-y				+= xfs_trace.o +# highlevel code +xfs-y				+= xfs_aops.o \ +				   xfs_bit.o \ +				   xfs_buf.o \ +				   xfs_dfrag.o \ +				   xfs_discard.o \ +				   xfs_error.o \ +				   xfs_export.o \ +				   xfs_file.o \ +				   xfs_filestream.o \ +				   xfs_fsops.o \ +				   xfs_fs_subr.o \ +				   xfs_globals.o \ +				   xfs_iget.o \ +				   xfs_ioctl.o \ +				   xfs_iomap.o \ +				   xfs_iops.o \ +				   xfs_itable.o \ +				   xfs_message.o \ +				   xfs_mru_cache.o \ +				   xfs_super.o \ +				   xfs_sync.o \ +				   xfs_xattr.o \ +				   xfs_rename.o \ +				   xfs_rw.o \ +				   xfs_utils.o \ +				   xfs_vnodeops.o \ +				   kmem.o \ +				   uuid.o +# code shared with libxfs  xfs-y				+= xfs_alloc.o \  				   xfs_alloc_btree.o \  				   xfs_attr.o \  				   xfs_attr_leaf.o \ -				   xfs_bit.o \  				   xfs_bmap.o \  				   xfs_bmap_btree.o \  				   xfs_btree.o \ -				   xfs_buf_item.o \  				   xfs_da_btree.o \  				   xfs_dir2.o \  				   xfs_dir2_block.o \ @@ -61,49 +70,37 @@ xfs-y				+= xfs_alloc.o \  				   xfs_dir2_leaf.o \  				   xfs_dir2_node.o \  				   xfs_dir2_sf.o \ -				   xfs_error.o \ -				   xfs_extfree_item.o \ -				   xfs_filestream.o \ -				   xfs_fsops.o \  				   xfs_ialloc.o \  				   xfs_ialloc_btree.o \ -				   xfs_iget.o \  				   xfs_inode.o \ -				   xfs_inode_item.o \ -				   xfs_iomap.o \ -				   xfs_itable.o \ -				   xfs_dfrag.o \ -				   xfs_log.o \ -				   xfs_log_cil.o \  				   xfs_log_recover.o \  				   xfs_mount.o \ -				   xfs_mru_cache.o \ -				   xfs_rename.o \ -				   xfs_trans.o \ +				   xfs_trans.o + +# low-level transaction/log code +xfs-y				+= xfs_log.o \ +				   xfs_log_cil.o \ +				   xfs_buf_item.o \ +				   xfs_extfree_item.o \ +				   xfs_inode_item.o \  				   xfs_trans_ail.o \  				   xfs_trans_buf.o \  				   xfs_trans_extfree.o \  				   xfs_trans_inode.o \ -				   xfs_utils.o \ -				   xfs_vnodeops.o \ -				   xfs_rw.o - -# Objects in linux/ -xfs-y				+= $(addprefix $(XFS_LINUX)/, \ -				   kmem.o \ -				   xfs_aops.o \ -				   xfs_buf.o \ -				   xfs_discard.o \ -				   xfs_export.o \ -				   xfs_file.o \ -				   xfs_fs_subr.o \ -				   xfs_globals.o \ -				   xfs_ioctl.o \ -				   xfs_iops.o \ -				   xfs_message.o \ -				   xfs_super.o \ -				   xfs_sync.o \ -				   xfs_xattr.o) -# Objects in support/ -xfs-y				+= support/uuid.o +# optional features +xfs-$(CONFIG_XFS_QUOTA)		+= xfs_dquot.o \ +				   xfs_dquot_item.o \ +				   xfs_trans_dquot.o \ +				   xfs_qm_syscalls.o \ +				   xfs_qm_bhv.o \ +				   xfs_qm.o \ +				   xfs_quotaops.o +ifeq ($(CONFIG_XFS_QUOTA),y) +xfs-$(CONFIG_PROC_FS)		+= xfs_qm_stats.o +endif +xfs-$(CONFIG_XFS_RT)		+= xfs_rtalloc.o +xfs-$(CONFIG_XFS_POSIX_ACL)	+= xfs_acl.o +xfs-$(CONFIG_PROC_FS)		+= xfs_stats.o +xfs-$(CONFIG_SYSCTL)		+= xfs_sysctl.o +xfs-$(CONFIG_COMPAT)		+= xfs_ioctl32.o diff --git a/fs/xfs/linux-2.6/kmem.c b/fs/xfs/kmem.c index a907de565db..a907de565db 100644 --- a/fs/xfs/linux-2.6/kmem.c +++ b/fs/xfs/kmem.c diff --git a/fs/xfs/linux-2.6/kmem.h b/fs/xfs/kmem.h index f7c8f7a9ea6..f7c8f7a9ea6 100644 --- a/fs/xfs/linux-2.6/kmem.h +++ b/fs/xfs/kmem.h diff --git a/fs/xfs/linux-2.6/mrlock.h b/fs/xfs/mrlock.h index ff6a19873e5..ff6a19873e5 100644 --- a/fs/xfs/linux-2.6/mrlock.h +++ b/fs/xfs/mrlock.h diff --git a/fs/xfs/linux-2.6/time.h b/fs/xfs/time.h index 387e695a184..387e695a184 100644 --- a/fs/xfs/linux-2.6/time.h +++ b/fs/xfs/time.h diff --git a/fs/xfs/support/uuid.c b/fs/xfs/uuid.c index b83f76b6d41..b83f76b6d41 100644 --- a/fs/xfs/support/uuid.c +++ b/fs/xfs/uuid.c diff --git a/fs/xfs/support/uuid.h b/fs/xfs/uuid.h index 4732d71262c..4732d71262c 100644 --- a/fs/xfs/support/uuid.h +++ b/fs/xfs/uuid.h diff --git a/fs/xfs/xfs.h b/fs/xfs/xfs.h index 53ec3ea9a62..d8b11b7f94a 100644 --- a/fs/xfs/xfs.h +++ b/fs/xfs/xfs.h @@ -24,5 +24,6 @@  #define XFS_BUF_LOCK_TRACKING 1  #endif -#include <linux-2.6/xfs_linux.h> +#include "xfs_linux.h" +  #endif	/* __XFS_H__ */ diff --git a/fs/xfs/linux-2.6/xfs_acl.c b/fs/xfs/xfs_acl.c index b6c4b3795c4..b6c4b3795c4 100644 --- a/fs/xfs/linux-2.6/xfs_acl.c +++ b/fs/xfs/xfs_acl.c diff --git a/fs/xfs/linux-2.6/xfs_aops.c b/fs/xfs/xfs_aops.c index 63e971e2b83..63e971e2b83 100644 --- a/fs/xfs/linux-2.6/xfs_aops.c +++ b/fs/xfs/xfs_aops.c diff --git a/fs/xfs/linux-2.6/xfs_aops.h b/fs/xfs/xfs_aops.h index 71f721e1a71..71f721e1a71 100644 --- a/fs/xfs/linux-2.6/xfs_aops.h +++ b/fs/xfs/xfs_aops.h diff --git a/fs/xfs/linux-2.6/xfs_buf.c b/fs/xfs/xfs_buf.c index c57836dc778..c57836dc778 100644 --- a/fs/xfs/linux-2.6/xfs_buf.c +++ b/fs/xfs/xfs_buf.c diff --git a/fs/xfs/linux-2.6/xfs_buf.h b/fs/xfs/xfs_buf.h index 620972b8094..620972b8094 100644 --- a/fs/xfs/linux-2.6/xfs_buf.h +++ b/fs/xfs/xfs_buf.h diff --git a/fs/xfs/linux-2.6/xfs_discard.c b/fs/xfs/xfs_discard.c index 244e797dae3..244e797dae3 100644 --- a/fs/xfs/linux-2.6/xfs_discard.c +++ b/fs/xfs/xfs_discard.c diff --git a/fs/xfs/linux-2.6/xfs_discard.h b/fs/xfs/xfs_discard.h index 344879aea64..344879aea64 100644 --- a/fs/xfs/linux-2.6/xfs_discard.h +++ b/fs/xfs/xfs_discard.h diff --git a/fs/xfs/quota/xfs_dquot.c b/fs/xfs/xfs_dquot.c index db62959bed1..db62959bed1 100644 --- a/fs/xfs/quota/xfs_dquot.c +++ b/fs/xfs/xfs_dquot.c diff --git a/fs/xfs/quota/xfs_dquot.h b/fs/xfs/xfs_dquot.h index 34b7e945dbf..34b7e945dbf 100644 --- a/fs/xfs/quota/xfs_dquot.h +++ b/fs/xfs/xfs_dquot.h diff --git a/fs/xfs/quota/xfs_dquot_item.c b/fs/xfs/xfs_dquot_item.c index 9e0e2fa3f2c..9e0e2fa3f2c 100644 --- a/fs/xfs/quota/xfs_dquot_item.c +++ b/fs/xfs/xfs_dquot_item.c diff --git a/fs/xfs/quota/xfs_dquot_item.h b/fs/xfs/xfs_dquot_item.h index 5acae2ada70..5acae2ada70 100644 --- a/fs/xfs/quota/xfs_dquot_item.h +++ b/fs/xfs/xfs_dquot_item.h diff --git a/fs/xfs/linux-2.6/xfs_export.c b/fs/xfs/xfs_export.c index 75e5d322e48..75e5d322e48 100644 --- a/fs/xfs/linux-2.6/xfs_export.c +++ b/fs/xfs/xfs_export.c diff --git a/fs/xfs/linux-2.6/xfs_export.h b/fs/xfs/xfs_export.h index 3272b6ae7a3..3272b6ae7a3 100644 --- a/fs/xfs/linux-2.6/xfs_export.h +++ b/fs/xfs/xfs_export.h diff --git a/fs/xfs/linux-2.6/xfs_file.c b/fs/xfs/xfs_file.c index 7f7b42469ea..7f7b42469ea 100644 --- a/fs/xfs/linux-2.6/xfs_file.c +++ b/fs/xfs/xfs_file.c diff --git a/fs/xfs/linux-2.6/xfs_fs_subr.c b/fs/xfs/xfs_fs_subr.c index ed88ed16811..ed88ed16811 100644 --- a/fs/xfs/linux-2.6/xfs_fs_subr.c +++ b/fs/xfs/xfs_fs_subr.c diff --git a/fs/xfs/linux-2.6/xfs_globals.c b/fs/xfs/xfs_globals.c index 76e81cff70b..76e81cff70b 100644 --- a/fs/xfs/linux-2.6/xfs_globals.c +++ b/fs/xfs/xfs_globals.c diff --git a/fs/xfs/linux-2.6/xfs_ioctl.c b/fs/xfs/xfs_ioctl.c index f7ce7debe14..f7ce7debe14 100644 --- a/fs/xfs/linux-2.6/xfs_ioctl.c +++ b/fs/xfs/xfs_ioctl.c diff --git a/fs/xfs/linux-2.6/xfs_ioctl.h b/fs/xfs/xfs_ioctl.h index d56173b34a2..d56173b34a2 100644 --- a/fs/xfs/linux-2.6/xfs_ioctl.h +++ b/fs/xfs/xfs_ioctl.h diff --git a/fs/xfs/linux-2.6/xfs_ioctl32.c b/fs/xfs/xfs_ioctl32.c index 54e623bfbb8..54e623bfbb8 100644 --- a/fs/xfs/linux-2.6/xfs_ioctl32.c +++ b/fs/xfs/xfs_ioctl32.c diff --git a/fs/xfs/linux-2.6/xfs_ioctl32.h b/fs/xfs/xfs_ioctl32.h index 80f4060e897..80f4060e897 100644 --- a/fs/xfs/linux-2.6/xfs_ioctl32.h +++ b/fs/xfs/xfs_ioctl32.h diff --git a/fs/xfs/linux-2.6/xfs_iops.c b/fs/xfs/xfs_iops.c index b9c172b3fbb..b9c172b3fbb 100644 --- a/fs/xfs/linux-2.6/xfs_iops.c +++ b/fs/xfs/xfs_iops.c diff --git a/fs/xfs/linux-2.6/xfs_iops.h b/fs/xfs/xfs_iops.h index ef41c92ce66..ef41c92ce66 100644 --- a/fs/xfs/linux-2.6/xfs_iops.h +++ b/fs/xfs/xfs_iops.h diff --git a/fs/xfs/linux-2.6/xfs_linux.h b/fs/xfs/xfs_linux.h index d42f814e4d3..1e8a45e74c3 100644 --- a/fs/xfs/linux-2.6/xfs_linux.h +++ b/fs/xfs/xfs_linux.h @@ -32,13 +32,12 @@  # define XFS_BIG_INUMS	0  #endif -#include <xfs_types.h> +#include "xfs_types.h" -#include <kmem.h> -#include <mrlock.h> -#include <time.h> - -#include <support/uuid.h> +#include "kmem.h" +#include "mrlock.h" +#include "time.h" +#include "uuid.h"  #include <linux/semaphore.h>  #include <linux/mm.h> @@ -78,14 +77,14 @@  #include <asm/byteorder.h>  #include <asm/unaligned.h> -#include <xfs_vnode.h> -#include <xfs_stats.h> -#include <xfs_sysctl.h> -#include <xfs_iops.h> -#include <xfs_aops.h> -#include <xfs_super.h> -#include <xfs_buf.h> -#include <xfs_message.h> +#include "xfs_vnode.h" +#include "xfs_stats.h" +#include "xfs_sysctl.h" +#include "xfs_iops.h" +#include "xfs_aops.h" +#include "xfs_super.h" +#include "xfs_buf.h" +#include "xfs_message.h"  #ifdef __BIG_ENDIAN  #define XFS_NATIVE_HOST 1 diff --git a/fs/xfs/linux-2.6/xfs_message.c b/fs/xfs/xfs_message.c index bd672def95a..bd672def95a 100644 --- a/fs/xfs/linux-2.6/xfs_message.c +++ b/fs/xfs/xfs_message.c diff --git a/fs/xfs/linux-2.6/xfs_message.h b/fs/xfs/xfs_message.h index 7fb7ea00767..7fb7ea00767 100644 --- a/fs/xfs/linux-2.6/xfs_message.h +++ b/fs/xfs/xfs_message.h diff --git a/fs/xfs/quota/xfs_qm.c b/fs/xfs/xfs_qm.c index 9a0aa76facd..9a0aa76facd 100644 --- a/fs/xfs/quota/xfs_qm.c +++ b/fs/xfs/xfs_qm.c diff --git a/fs/xfs/quota/xfs_qm.h b/fs/xfs/xfs_qm.h index 43b9abe1052..43b9abe1052 100644 --- a/fs/xfs/quota/xfs_qm.h +++ b/fs/xfs/xfs_qm.h diff --git a/fs/xfs/quota/xfs_qm_bhv.c b/fs/xfs/xfs_qm_bhv.c index a0a829addca..a0a829addca 100644 --- a/fs/xfs/quota/xfs_qm_bhv.c +++ b/fs/xfs/xfs_qm_bhv.c diff --git a/fs/xfs/quota/xfs_qm_stats.c b/fs/xfs/xfs_qm_stats.c index 8671a0b3264..8671a0b3264 100644 --- a/fs/xfs/quota/xfs_qm_stats.c +++ b/fs/xfs/xfs_qm_stats.c diff --git a/fs/xfs/quota/xfs_qm_stats.h b/fs/xfs/xfs_qm_stats.h index 5b964fc0dc0..5b964fc0dc0 100644 --- a/fs/xfs/quota/xfs_qm_stats.h +++ b/fs/xfs/xfs_qm_stats.h diff --git a/fs/xfs/quota/xfs_qm_syscalls.c b/fs/xfs/xfs_qm_syscalls.c index 609246f42e6..609246f42e6 100644 --- a/fs/xfs/quota/xfs_qm_syscalls.c +++ b/fs/xfs/xfs_qm_syscalls.c diff --git a/fs/xfs/quota/xfs_quota_priv.h b/fs/xfs/xfs_quota_priv.h index 94a3d927d71..94a3d927d71 100644 --- a/fs/xfs/quota/xfs_quota_priv.h +++ b/fs/xfs/xfs_quota_priv.h diff --git a/fs/xfs/linux-2.6/xfs_quotaops.c b/fs/xfs/xfs_quotaops.c index 29b9d642e93..7e76f537abb 100644 --- a/fs/xfs/linux-2.6/xfs_quotaops.c +++ b/fs/xfs/xfs_quotaops.c @@ -25,7 +25,7 @@  #include "xfs_trans.h"  #include "xfs_bmap_btree.h"  #include "xfs_inode.h" -#include "quota/xfs_qm.h" +#include "xfs_qm.h"  #include <linux/quota.h> diff --git a/fs/xfs/linux-2.6/xfs_stats.c b/fs/xfs/xfs_stats.c index 76fdc586193..76fdc586193 100644 --- a/fs/xfs/linux-2.6/xfs_stats.c +++ b/fs/xfs/xfs_stats.c diff --git a/fs/xfs/linux-2.6/xfs_stats.h b/fs/xfs/xfs_stats.h index 736854b1ca1..736854b1ca1 100644 --- a/fs/xfs/linux-2.6/xfs_stats.h +++ b/fs/xfs/xfs_stats.h diff --git a/fs/xfs/linux-2.6/xfs_super.c b/fs/xfs/xfs_super.c index 9a72dda58bd..9a72dda58bd 100644 --- a/fs/xfs/linux-2.6/xfs_super.c +++ b/fs/xfs/xfs_super.c diff --git a/fs/xfs/linux-2.6/xfs_super.h b/fs/xfs/xfs_super.h index 50a3266c999..50a3266c999 100644 --- a/fs/xfs/linux-2.6/xfs_super.h +++ b/fs/xfs/xfs_super.h diff --git a/fs/xfs/linux-2.6/xfs_sync.c b/fs/xfs/xfs_sync.c index 4604f90f86a..4604f90f86a 100644 --- a/fs/xfs/linux-2.6/xfs_sync.c +++ b/fs/xfs/xfs_sync.c diff --git a/fs/xfs/linux-2.6/xfs_sync.h b/fs/xfs/xfs_sync.h index 941202e7ac6..941202e7ac6 100644 --- a/fs/xfs/linux-2.6/xfs_sync.h +++ b/fs/xfs/xfs_sync.h diff --git a/fs/xfs/linux-2.6/xfs_sysctl.c b/fs/xfs/xfs_sysctl.c index ee2d2adaa43..ee2d2adaa43 100644 --- a/fs/xfs/linux-2.6/xfs_sysctl.c +++ b/fs/xfs/xfs_sysctl.c diff --git a/fs/xfs/linux-2.6/xfs_sysctl.h b/fs/xfs/xfs_sysctl.h index b9937d450f8..b9937d450f8 100644 --- a/fs/xfs/linux-2.6/xfs_sysctl.h +++ b/fs/xfs/xfs_sysctl.h diff --git a/fs/xfs/linux-2.6/xfs_trace.c b/fs/xfs/xfs_trace.c index 88d25d4aa56..9010ce885e6 100644 --- a/fs/xfs/linux-2.6/xfs_trace.c +++ b/fs/xfs/xfs_trace.c @@ -43,8 +43,8 @@  #include "xfs_quota.h"  #include "xfs_iomap.h"  #include "xfs_aops.h" -#include "quota/xfs_dquot_item.h" -#include "quota/xfs_dquot.h" +#include "xfs_dquot_item.h" +#include "xfs_dquot.h"  #include "xfs_log_recover.h"  #include "xfs_inode_item.h" diff --git a/fs/xfs/linux-2.6/xfs_trace.h b/fs/xfs/xfs_trace.h index 690fc7a7bd7..690fc7a7bd7 100644 --- a/fs/xfs/linux-2.6/xfs_trace.h +++ b/fs/xfs/xfs_trace.h diff --git a/fs/xfs/quota/xfs_trans_dquot.c b/fs/xfs/xfs_trans_dquot.c index 4d00ee67792..4d00ee67792 100644 --- a/fs/xfs/quota/xfs_trans_dquot.c +++ b/fs/xfs/xfs_trans_dquot.c diff --git a/fs/xfs/linux-2.6/xfs_vnode.h b/fs/xfs/xfs_vnode.h index 7c220b4227b..7c220b4227b 100644 --- a/fs/xfs/linux-2.6/xfs_vnode.h +++ b/fs/xfs/xfs_vnode.h diff --git a/fs/xfs/linux-2.6/xfs_xattr.c b/fs/xfs/xfs_xattr.c index 87d3e03878c..87d3e03878c 100644 --- a/fs/xfs/linux-2.6/xfs_xattr.c +++ b/fs/xfs/xfs_xattr.c  |