Pull vector-domain into release branch
[sfrench/cifs-2.6.git] / fs / reiserfs / super.c
index f13a7f164dc65e225eb36e93fa3cf6e7c10d22f0..5a93cfe1a0326eba2ef8872f67ae72eedbdf5f0a 100644 (file)
 #include <linux/reiserfs_fs.h>
 #include <linux/reiserfs_acl.h>
 #include <linux/reiserfs_xattr.h>
-#include <linux/smp_lock.h>
 #include <linux/init.h>
 #include <linux/blkdev.h>
 #include <linux/buffer_head.h>
+#include <linux/exportfs.h>
 #include <linux/vfs.h>
 #include <linux/mnt_namespace.h>
 #include <linux/mount.h>
@@ -433,12 +433,13 @@ int remove_save_link(struct inode *inode, int truncate)
 static void reiserfs_kill_sb(struct super_block *s)
 {
        if (REISERFS_SB(s)) {
+#ifdef CONFIG_REISERFS_FS_XATTR
                if (REISERFS_SB(s)->xattr_root) {
                        d_invalidate(REISERFS_SB(s)->xattr_root);
                        dput(REISERFS_SB(s)->xattr_root);
                        REISERFS_SB(s)->xattr_root = NULL;
                }
-
+#endif
                if (REISERFS_SB(s)->priv_root) {
                        d_invalidate(REISERFS_SB(s)->priv_root);
                        dput(REISERFS_SB(s)->priv_root);
@@ -511,15 +512,12 @@ static void init_once(void *foo, struct kmem_cache * cachep, unsigned long flags
 {
        struct reiserfs_inode_info *ei = (struct reiserfs_inode_info *)foo;
 
-       if ((flags & (SLAB_CTOR_VERIFY | SLAB_CTOR_CONSTRUCTOR)) ==
-           SLAB_CTOR_CONSTRUCTOR) {
-               INIT_LIST_HEAD(&ei->i_prealloc_list);
-               inode_init_once(&ei->vfs_inode);
+       INIT_LIST_HEAD(&ei->i_prealloc_list);
+       inode_init_once(&ei->vfs_inode);
 #ifdef CONFIG_REISERFS_FS_POSIX_ACL
-               ei->i_acl_access = NULL;
-               ei->i_acl_default = NULL;
+       ei->i_acl_access = NULL;
+       ei->i_acl_default = NULL;
 #endif
-       }
 }
 
 static int init_inodecache(void)
@@ -1563,9 +1561,10 @@ static int reiserfs_fill_super(struct super_block *s, void *data, int silent)
        REISERFS_SB(s)->s_alloc_options.preallocmin = 0;
        /* Preallocate by 16 blocks (17-1) at once */
        REISERFS_SB(s)->s_alloc_options.preallocsize = 17;
+#ifdef CONFIG_REISERFS_FS_XATTR
        /* Initialize the rwsem for xattr dir */
        init_rwsem(&REISERFS_SB(s)->xattr_dir_sem);
-
+#endif
        /* setup default block allocator options */
        reiserfs_init_alloc_options(s);