diff options
Diffstat (limited to 'mm/swapfile.c')
-rw-r--r-- | mm/swapfile.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/mm/swapfile.c b/mm/swapfile.c index 0184f510aac..1dcaeda039f 100644 --- a/mm/swapfile.c +++ b/mm/swapfile.c | |||
@@ -1381,6 +1381,7 @@ asmlinkage long sys_swapon(const char __user * specialfile, int swap_flags) | |||
1381 | error = bd_claim(bdev, sys_swapon); | 1381 | error = bd_claim(bdev, sys_swapon); |
1382 | if (error < 0) { | 1382 | if (error < 0) { |
1383 | bdev = NULL; | 1383 | bdev = NULL; |
1384 | error = -EINVAL; | ||
1384 | goto bad_swap; | 1385 | goto bad_swap; |
1385 | } | 1386 | } |
1386 | p->old_block_size = block_size(bdev); | 1387 | p->old_block_size = block_size(bdev); |