1. 12 1月, 2015 1 次提交
    • S
      efi: Expose underlying UEFI firmware platform size to userland · 2859dff9
      Steve McIntyre 提交于
      In some cases (e.g. Intel Bay Trail machines), the kernel will happily
      run in 64-bit even if the underlying UEFI firmware platform is
      32-bit. That's great, but it's difficult for userland utilities like
      grub-install to do the right thing in such a situation.
      
      The kernel already knows about the size of the firmware via
      efi_enabled(EFI_64BIT). Add an extra sysfs interface
      /sys/firmware/efi/fw_platform_size to expose that information to
      userland for low-level utilities to use.
      Signed-off-by: NSteve McIntyre <steve@einval.com>
      Cc: Matthew Garrett <mjg59@srcf.ucam.org>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      2859dff9
  2. 08 1月, 2015 1 次提交
  3. 04 10月, 2014 3 次提交
  4. 19 7月, 2014 3 次提交
    • L
      efi: Autoload efivars · 28d54022
      Lee, Chun-Yi 提交于
      The original patch is from Ben Hutchings's contribution to debian
      kernel. Got Ben's permission to remove the code of efi-pstore.c and
      send to linux-efi:
      https://github.com/BlankOn/linux-debian/blob/master/debian/patches/features/all/efi-autoload-efivars.patch
      
      efivars is generally useful to have on EFI systems, and in some cases
      it may be impossible to load it after a kernel upgrade in order to
      complete a boot loader update. At the same time we don't want to waste
      memory on non-EFI systems by making them built-in.
      
      Instead, give them module aliases as if they are platform drivers, and
      register a corresponding platform device whenever EFI runtime services
      are available.  This should trigger udev to load them.
      Signed-off-by: NLee, Chun-Yi <jlee@suse.com>
      Cc: Ben Hutchings <ben@decadent.org.uk>
      Tested-by: NArd Biesheuvel <ard.biesheuvel@linaro.org>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      28d54022
    • D
      efi: Introduce EFI_PARAVIRT flag · 9f27bc54
      Daniel Kiper 提交于
      Introduce EFI_PARAVIRT flag. If it is set then kernel runs
      on EFI platform but it has not direct control on EFI stuff
      like EFI runtime, tables, structures, etc. If not this means
      that Linux Kernel has direct access to EFI infrastructure
      and everything runs as usual.
      
      This functionality is used in Xen dom0 because hypervisor
      has full control on EFI stuff and all calls from dom0 to
      EFI must be requested via special hypercall which in turn
      executes relevant EFI code in behalf of dom0.
      Signed-off-by: NDaniel Kiper <daniel.kiper@oracle.com>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      9f27bc54
    • D
      efi: Use early_mem*() instead of early_io*() · abc93f8e
      Daniel Kiper 提交于
      Use early_mem*() instead of early_io*() because all mapped EFI regions
      are memory (usually RAM but they could also be ROM, EPROM, EEPROM, flash,
      etc.) not I/O regions. Additionally, I/O family calls do not work correctly
      under Xen in our case. early_ioremap() skips the PFN to MFN conversion
      when building the PTE. Using it for memory will attempt to map the wrong
      machine frame. However, all artificial EFI structures created under Xen
      live in dom0 memory and should be mapped/unmapped using early_mem*() family
      calls which map domain memory.
      Signed-off-by: NDaniel Kiper <daniel.kiper@oracle.com>
      Cc: Leif Lindholm <leif.lindholm@linaro.org>
      Cc: Mark Salter <msalter@redhat.com>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      abc93f8e
  5. 10 7月, 2014 1 次提交
  6. 19 6月, 2014 1 次提交
    • C
      efi: Fix compiler warnings (unused, const, type) · 6fb8cc82
      Catalin Marinas 提交于
      This patch fixes a few compiler warning in the efi code for unused
      variable, discarding const qualifier and wrong pointer type:
      
      drivers/firmware/efi/fdt.c|66 col 22| warning: unused variable ‘name’ [-Wunused-variable]
      drivers/firmware/efi/efi.c|368 col 3| warning: passing argument 3 of ‘of_get_flat_dt_prop’ from incompatible pointer type [enabled by default]
      drivers/firmware/efi/efi.c|368 col 8| warning: assignment discards ‘const’ qualifier from pointer target type [enabled by default]
      Signed-off-by: NCatalin Marinas <catalin.marinas@arm.com>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      6fb8cc82
  7. 01 5月, 2014 1 次提交
  8. 05 3月, 2014 2 次提交
  9. 21 12月, 2013 2 次提交
  10. 05 9月, 2013 2 次提交
  11. 17 4月, 2013 1 次提交
    • T
      efi: split efisubsystem from efivars · a9499fa7
      Tom Gundersen 提交于
      This registers /sys/firmware/efi/{,systab,efivars/} whenever EFI is enabled
      and the system is booted with EFI.
      
      This allows
       *) userspace to check for the existence of /sys/firmware/efi as a way
          to determine whether or it is running on an EFI system.
       *) 'mount -t efivarfs none /sys/firmware/efi/efivars' without manually
          loading any modules.
      
      [ Also, move the efivar API into vars.c and unconditionally compile it.
        This allows us to move efivars.c, which now only contains the sysfs
        variable code, into the firmware/efi directory. Note that the efivars.c
        filename is kept to maintain backwards compatability with the old
        efivars.ko module. With this patch it is now possible for efivarfs
        to be built without CONFIG_EFI_VARS - Matt ]
      
      Cc: Seiji Aguchi <seiji.aguchi@hds.com>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: Mike Waychison <mikew@google.com>
      Cc: Kay Sievers <kay@vrfy.org>
      Cc: Jeremy Kerr <jk@ozlabs.org>
      Cc: Matthew Garrett <mjg59@srcf.ucam.org>
      Cc: Chun-Yi Lee <jlee@suse.com>
      Cc: Andy Whitcroft <apw@canonical.com>
      Cc: Tobias Powalowski <tpowa@archlinux.org>
      Signed-off-by: NTom Gundersen <teg@jklm.no>
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      a9499fa7