aboutsummaryrefslogtreecommitdiffstats
path: root/fs/autofs/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/autofs/inode.c')
-rw-r--r--fs/autofs/inode.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/autofs/inode.c b/fs/autofs/inode.c
index af2efbbb5d76..2c9759baad61 100644
--- a/fs/autofs/inode.c
+++ b/fs/autofs/inode.c
@@ -129,10 +129,9 @@ int autofs_fill_super(struct super_block *s, void *data, int silent)
129 struct autofs_sb_info *sbi; 129 struct autofs_sb_info *sbi;
130 int minproto, maxproto; 130 int minproto, maxproto;
131 131
132 sbi = kmalloc(sizeof(*sbi), GFP_KERNEL); 132 sbi = kzalloc(sizeof(*sbi), GFP_KERNEL);
133 if ( !sbi ) 133 if ( !sbi )
134 goto fail_unlock; 134 goto fail_unlock;
135 memset(sbi, 0, sizeof(*sbi));
136 DPRINTK(("autofs: starting up, sbi = %p\n",sbi)); 135 DPRINTK(("autofs: starting up, sbi = %p\n",sbi));
137 136
138 s->s_fs_info = sbi; 137 s->s_fs_info = sbi;
@@ -217,7 +216,6 @@ static void autofs_read_inode(struct inode *inode)
217 inode->i_nlink = 2; 216 inode->i_nlink = 2;
218 inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME; 217 inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME;
219 inode->i_blocks = 0; 218 inode->i_blocks = 0;
220 inode->i_blksize = 1024;
221 219
222 if ( ino == AUTOFS_ROOT_INO ) { 220 if ( ino == AUTOFS_ROOT_INO ) {
223 inode->i_mode = S_IFDIR | S_IRUGO | S_IXUGO | S_IWUSR; 221 inode->i_mode = S_IFDIR | S_IRUGO | S_IXUGO | S_IWUSR;
@@ -242,7 +240,7 @@ static void autofs_read_inode(struct inode *inode)
242 240
243 inode->i_op = &autofs_symlink_inode_operations; 241 inode->i_op = &autofs_symlink_inode_operations;
244 sl = &sbi->symlink[n]; 242 sl = &sbi->symlink[n];
245 inode->u.generic_ip = sl; 243 inode->i_private = sl;
246 inode->i_mode = S_IFLNK | S_IRWXUGO; 244 inode->i_mode = S_IFLNK | S_IRWXUGO;
247 inode->i_mtime.tv_sec = inode->i_ctime.tv_sec = sl->mtime; 245 inode->i_mtime.tv_sec = inode->i_ctime.tv_sec = sl->mtime;
248 inode->i_mtime.tv_nsec = inode->i_ctime.tv_nsec = 0; 246 inode->i_mtime.tv_nsec = inode->i_ctime.tv_nsec = 0;