]> git.baikalelectronics.ru Git - kernel.git/commit
block/partitions/efi.c: treat size mismatch as a warning, not an error
authorDoug Anderson <dianders@chromium.org>
Wed, 16 Oct 2013 20:46:57 +0000 (13:46 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 17 Oct 2013 04:35:53 +0000 (21:35 -0700)
commitce6c9dbf0f7685c0b317a2a275fc3d784e14b10c
tree3c1428036452d8b7a18b9f2cac8f1caefa23cf47
parent6b642bc25618ac0d9729c9fee7ee0da1f3e8a847
block/partitions/efi.c: treat size mismatch as a warning, not an error

In commit 87261aa16e20 ("partitions/efi: account for pmbr size in lba")
we started treating bad sizes in lba field of the partition that has the
0xEE (GPT protective) as errors.

However, we may run into these "bad sizes" in the real world if someone
uses dd to copy an image from a smaller disk to a bigger disk.  Since
this case used to work (even without using force_gpt), keep it working
and treat the size mismatch as a warning instead of an error.

Reported-by: Josh Triplett <josh@joshtriplett.org>
Reported-by: Sean Paul <seanpaul@chromium.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Acked-by: Davidlohr Bueso <davidlohr@hp.com>
Tested-by: Artem Bityutskiy <dedekind1@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
block/partitions/efi.c