part_efi: fix protective mbr struct allocation
authorHector Palacios <hector.palacios@digi.com>
Thu, 13 Feb 2014 08:48:24 +0000 (09:48 +0100)
committerChanho Park <chanho61.park@samsung.com>
Tue, 11 Aug 2015 13:22:50 +0000 (22:22 +0900)
commit6ec4ca75c237117d2512b4b6675c53640274cbfa
treeda7a25e1e7c76e358520f37e0baf586f82996574
parent1d25b26fe3acc57df131ad5bd0443413ef64608e
part_efi: fix protective mbr struct allocation

The calloc() call was allocating space for the sizeof the struct
pointer rather than for the struct contents.
Besides, since this buffer is passed to mmc for writing and some
platforms may use cache, the legacy_mbr struct should be cache-aligned.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
Tested-by: Lukasz Majewski <l.majewski@samsung.com>
disk/part_efi.c