diff options
author | David S. Miller <davem@davemloft.net> | 2012-01-04 21:35:43 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-01-04 21:35:43 -0500 |
commit | 117ff42fd43e92d24c6aa6f3e4f0f1e1edada140 (patch) | |
tree | c08e1c0357fde481a16489b77feb8f6073faf538 /fs | |
parent | 1d5783030a14d1b6ee763f63c8136e581f48b365 (diff) | |
parent | 805a6af8dba5dfdd35ec35dc52ec0122400b2610 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'fs')
-rw-r--r-- | fs/cifs/connect.c | 4 | ||||
-rw-r--r-- | fs/minix/inode.c | 34 |
2 files changed, 19 insertions, 19 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c index 8cd4b52d4217..f3670cf72587 100644 --- a/fs/cifs/connect.c +++ b/fs/cifs/connect.c | |||
@@ -282,7 +282,7 @@ static int coalesce_t2(struct smb_hdr *psecond, struct smb_hdr *pTargetSMB) | |||
282 | byte_count = be32_to_cpu(pTargetSMB->smb_buf_length); | 282 | byte_count = be32_to_cpu(pTargetSMB->smb_buf_length); |
283 | byte_count += total_in_buf2; | 283 | byte_count += total_in_buf2; |
284 | /* don't allow buffer to overflow */ | 284 | /* don't allow buffer to overflow */ |
285 | if (byte_count > CIFSMaxBufSize) | 285 | if (byte_count > CIFSMaxBufSize + MAX_CIFS_HDR_SIZE - 4) |
286 | return -ENOBUFS; | 286 | return -ENOBUFS; |
287 | pTargetSMB->smb_buf_length = cpu_to_be32(byte_count); | 287 | pTargetSMB->smb_buf_length = cpu_to_be32(byte_count); |
288 | 288 | ||
@@ -2122,7 +2122,7 @@ cifs_get_smb_ses(struct TCP_Server_Info *server, struct smb_vol *volume_info) | |||
2122 | warned_on_ntlm = true; | 2122 | warned_on_ntlm = true; |
2123 | cERROR(1, "default security mechanism requested. The default " | 2123 | cERROR(1, "default security mechanism requested. The default " |
2124 | "security mechanism will be upgraded from ntlm to " | 2124 | "security mechanism will be upgraded from ntlm to " |
2125 | "ntlmv2 in kernel release 3.2"); | 2125 | "ntlmv2 in kernel release 3.3"); |
2126 | } | 2126 | } |
2127 | ses->overrideSecFlg = volume_info->secFlg; | 2127 | ses->overrideSecFlg = volume_info->secFlg; |
2128 | 2128 | ||
diff --git a/fs/minix/inode.c b/fs/minix/inode.c index 1d9e33966db0..4d46a6a59070 100644 --- a/fs/minix/inode.c +++ b/fs/minix/inode.c | |||
@@ -263,23 +263,6 @@ static int minix_fill_super(struct super_block *s, void *data, int silent) | |||
263 | goto out_no_root; | 263 | goto out_no_root; |
264 | } | 264 | } |
265 | 265 | ||
266 | ret = -ENOMEM; | ||
267 | s->s_root = d_alloc_root(root_inode); | ||
268 | if (!s->s_root) | ||
269 | goto out_iput; | ||
270 | |||
271 | if (!(s->s_flags & MS_RDONLY)) { | ||
272 | if (sbi->s_version != MINIX_V3) /* s_state is now out from V3 sb */ | ||
273 | ms->s_state &= ~MINIX_VALID_FS; | ||
274 | mark_buffer_dirty(bh); | ||
275 | } | ||
276 | if (!(sbi->s_mount_state & MINIX_VALID_FS)) | ||
277 | printk("MINIX-fs: mounting unchecked file system, " | ||
278 | "running fsck is recommended\n"); | ||
279 | else if (sbi->s_mount_state & MINIX_ERROR_FS) | ||
280 | printk("MINIX-fs: mounting file system with errors, " | ||
281 | "running fsck is recommended\n"); | ||
282 | |||
283 | /* Apparently minix can create filesystems that allocate more blocks for | 266 | /* Apparently minix can create filesystems that allocate more blocks for |
284 | * the bitmaps than needed. We simply ignore that, but verify it didn't | 267 | * the bitmaps than needed. We simply ignore that, but verify it didn't |
285 | * create one with not enough blocks and bail out if so. | 268 | * create one with not enough blocks and bail out if so. |
@@ -300,6 +283,23 @@ static int minix_fill_super(struct super_block *s, void *data, int silent) | |||
300 | goto out_iput; | 283 | goto out_iput; |
301 | } | 284 | } |
302 | 285 | ||
286 | ret = -ENOMEM; | ||
287 | s->s_root = d_alloc_root(root_inode); | ||
288 | if (!s->s_root) | ||
289 | goto out_iput; | ||
290 | |||
291 | if (!(s->s_flags & MS_RDONLY)) { | ||
292 | if (sbi->s_version != MINIX_V3) /* s_state is now out from V3 sb */ | ||
293 | ms->s_state &= ~MINIX_VALID_FS; | ||
294 | mark_buffer_dirty(bh); | ||
295 | } | ||
296 | if (!(sbi->s_mount_state & MINIX_VALID_FS)) | ||
297 | printk("MINIX-fs: mounting unchecked file system, " | ||
298 | "running fsck is recommended\n"); | ||
299 | else if (sbi->s_mount_state & MINIX_ERROR_FS) | ||
300 | printk("MINIX-fs: mounting file system with errors, " | ||
301 | "running fsck is recommended\n"); | ||
302 | |||
303 | return 0; | 303 | return 0; |
304 | 304 | ||
305 | out_iput: | 305 | out_iput: |