]> git.baikalelectronics.ru Git - kernel.git/commit
efi: Enforce minimum alignment of 1 page on allocations.
authorRoy Franz <roy.franz@linaro.org>
Sun, 22 Sep 2013 22:45:30 +0000 (15:45 -0700)
committerMatt Fleming <matt.fleming@intel.com>
Wed, 25 Sep 2013 11:34:36 +0000 (12:34 +0100)
commiteb0a0a5e4b28216e474963a302089773f9d884fa
tree8e1d0ea4c9af90e91a58ef24e52f4c7d08a95f40
parent072f4eb2b3e237e2fbfd9c196252db7ab885e667
efi: Enforce minimum alignment of 1 page on allocations.

The efi_high_alloc() and efi_low_alloc() functions
use the EFI_ALLOCATE_ADDRESS option to the EFI
function allocate_pages(), which requires a minimum
of page alignment, and rejects all other requests.
The existing code could fail to allocate depending
on allocation size, as although repeated allocation
attempts were made, none were guaranteed to be page
aligned.

Signed-off-by: Roy Franz <roy.franz@linaro.org>
Acked-by: Mark Salter <msalter@redhat.com>
Reviewed-by: Grant Likely <grant.likely@linaro.org>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
drivers/firmware/efi/efi-stub-helper.c