Skip to content
Commit ff2a9941 authored by Tejun Heo's avatar Tejun Heo Committed by Linus Torvalds
Browse files

block: move bd_set_size() above rescan_partitions() in __blkdev_get()



02e35228 (block: rescan partitions on invalidated devices on
-ENOMEDIA too) relocated partition rescan above explicit bd_set_size()
to simplify condition check.  As rescan_partitions() does its own bdev
size setting, this doesn't break anything; however,
rescan_partitions() prints out the following messages when adjusting
bdev size, which can be confusing.

  sda: detected capacity change from 0 to 146815737856
  sdb: detected capacity change from 0 to 146815737856

This patch restores the original order and remove the warning
messages.

stable: Please apply together with 02e35228 (block: rescan
        partitions on invalidated devices on -ENOMEDIA too).

Signed-off-by: default avatarTejun Heo <tj@kernel.org>
Reported-by: default avatarTony Luck <tony.luck@gmail.com>
Tested-by: default avatarTony Luck <tony.luck@gmail.com>
Cc: stable@kernel.org
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent f4b10bc6
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment