Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 362700
b: refs/heads/master
c: 8c58bf3
h: refs/heads/master
v: v3
  • Loading branch information
Richard Weinberger authored and Matt Fleming committed Apr 17, 2013
1 parent c82bc38 commit 5ec64be
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3668011d4ad556224f7c012c1e870a6eaa0e59da
refs/heads/master: 8c58bf3eec3b8fc8162fe557e9361891c20758f2
6 changes: 6 additions & 0 deletions trunk/Documentation/kernel-parameters.txt
Original file line number Diff line number Diff line change
Expand Up @@ -788,6 +788,12 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
edd= [EDD]
Format: {"off" | "on" | "skip[mbr]"}

efi_no_storage_paranoia [EFI; X86]
Using this parameter you can use more than 50% of
your efi variable storage. Use this parameter only if
you are really sure that your UEFI does sane gc and
fulfills the spec otherwise your board may brick.

eisa_irq_edge= [PARISC,HW]
See header of drivers/parisc/eisa.c.

Expand Down
14 changes: 13 additions & 1 deletion trunk/arch/x86/platform/efi/efi.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,15 @@ static int __init setup_add_efi_memmap(char *arg)
}
early_param("add_efi_memmap", setup_add_efi_memmap);

static bool efi_no_storage_paranoia;

static int __init setup_storage_paranoia(char *arg)
{
efi_no_storage_paranoia = true;
return 0;
}
early_param("efi_no_storage_paranoia", setup_storage_paranoia);


static efi_status_t virt_efi_get_time(efi_time_t *tm, efi_time_cap_t *tc)
{
Expand Down Expand Up @@ -1137,7 +1146,10 @@ efi_status_t efi_query_variable_store(u32 attributes, unsigned long size)
*/

if (!storage_size || size > remaining_size ||
(max_size && size > max_size) ||
(max_size && size > max_size))
return EFI_OUT_OF_RESOURCES;

if (!efi_no_storage_paranoia &&
((active_size + size + VAR_METADATA_SIZE > storage_size / 2) &&
(remaining_size - size < storage_size / 2)))
return EFI_OUT_OF_RESOURCES;
Expand Down

0 comments on commit 5ec64be

Please sign in to comment.