efi: EFI capsule support and peristent storage backend

The EFI capsule mechanism allows data blobs to be passed to the EFI
firmware. By setting the EFI_CAPSULE_POPULATE_SYSTEM_TABLE and the
EFI_CAPSULE_PERSIST_ACROSS_REBOOT flags, the firmware will place a
pointer to our data blob in the EFI System Table on the next boot.

We can get access to the array of EFI capsules when parsing the
configuration tables. Store a pointer to the table.

We can utilise this facility to save crash dumps, call traces, etc and
pick them after reboot.

Cc: Andi Kleen <ak@linux.intel.com>
Cc: Tony Luck <tony.luck@intel.com>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
6 files changed