Forum | Documentation | Website | Blog

Skip to content
Snippets Groups Projects
  1. Jul 05, 2021
  2. Jul 02, 2021
    • Tom Rini's avatar
      Merge tag 'u-boot-amlogic-20210703' of https://source.denx.de/u-boot/custodians/u-boot-amlogic · 09576cdb
      Tom Rini authored
      - configs: libretech: set SPI mode to 0 to fix SPI NOR Flash probe
      09576cdb
    • Da Xue's avatar
      configs: libretech: set SPI mode to 0 · 8c6d8c32
      Da Xue authored
      
      Kconfig defaults to mode 3 if CONFIG_SF_DEFAULT_MODE is not set.
      It becomes an issue since meson_spifc does not support SPI_CPHA.
      Needed after commit e2e95e5e ("spi: Update speed/mode on change").
      
      Fixes: e2e95e5e ("spi: Update speed/mode on change")
      Signed-off-by: default avatarDa Xue <da@libre.computer>
      [narmstrong: reformated commit reference & added Fixes tag]
      Signed-off-by: default avatarNeil Armstrong <narmstrong@baylibre.com>
      8c6d8c32
    • Tom Rini's avatar
      Merge tag 'efi-2021-07-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi · 62c7e40a
      Tom Rini authored
      Pull request for efi-2021-07-rc6
      
      Bug fixes:
      
      * improve specification compliance of UEFI capsule updates
      * allow capsule update on-disk without checking OsIndications
      * provide parameter checks for QueryVariableInfo()
      62c7e40a
    • Da Xue's avatar
      autoboot: fix MENUKEY · 760d2f9e
      Da Xue authored
      
      replace CONFIG_AUTOBOOT_USE_MENUKEY with CONFIG_AUTOBOOT_MENUKEY
      
      Signed-off-by: default avatarDa Xue <da@libre.computer>
      760d2f9e
    • Ilias Apalodimas's avatar
      efi_loader: Allow capsule update on-disk without checking OsIndications · 0fa5020c
      Ilias Apalodimas authored
      
      Although U-Boot supports capsule update on-disk, it's lack of support for
      SetVariable at runtime prevents applications like fwupd from using it.
      
      In order to perform the capsule update on-disk the spec says that the OS
      must copy the capsule to the \EFI\UpdateCapsule directory and set a bit in
      the OsIndications variable.  The firmware then checks for the
      EFI_OS_INDICATIONS_FILE_CAPSULE_DELIVERY_SUPPORTED bit in OsIndications
      variable, which is set by the submitter to trigger processing of the
      capsule on the next reboot.
      
      Let's add a config option which ignores the bit and just relies on the
      capsule being present. Since U-Boot deletes the capsule while processing
      it, we won't end up applying it multiple times.
      
      Note that this is allowed for all capsules. In the future, once
      authenticated capsules are fully supported, we can limit the functionality
      to those only.
      
      Signed-off-by: default avatarapalos <ilias.apalodimas@linaro.org>
      
      Reword Kconfig description.
      Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      
      Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      0fa5020c
    • Heinrich Schuchardt's avatar
      efi_loader: clear OsIndications · 149108a3
      Heinrich Schuchardt authored
      
      After each reboot we must clear flag
      EFI_OS_INDICATIONS_FILE_CAPSULE_DELIVERY_SUPPORTED in variable
      OsIndications.
      
      Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      149108a3
    • Masami Hiramatsu's avatar
      efi_loader: Improve the parameter check for QueryVariableInfo() · 417a3c24
      Masami Hiramatsu authored
      
      Improve efi_query_variable_info() to check the parameter settings and
      return correct error code according to the UEFI Specification 2.9,
      and the Self Certification Test (SCT) II Case Specification, June
      2017, chapter 4.1.4 QueryVariableInfo().
      
      Reported-by: default avatarKazuhiko Sakamoto <sakamoto.kazuhiko@socionext.com>
      Signed-off-by: default avatarMasami Hiramatsu <masami.hiramatsu@linaro.org>
      Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      417a3c24
    • Heinrich Schuchardt's avatar
      efi_loader: missing parentheses in query_console_size · abd62e4d
      Heinrich Schuchardt authored
      
      After if we should use parentheses to keep the code readable.
      
      Fixes: a95f4c88 ("efi_loader: NULL dereference in EFI console")
      Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      abd62e4d
    • Ilias Apalodimas's avatar
      efi_loader: Always install FMPs · 6e0184b8
      Ilias Apalodimas authored
      
      We only install FMPs if a CapsuleUpdate is requested.  Since we now have an
      ESRT table which relies on FMPs to build the required information, it
      makes more sense to unconditionally install them. This will allow userspace
      applications (e.g fwupd) to make use of the ERST and provide us with files
      we can use to run CapsuleUpdate on-disk
      
      Signed-off-by: default avatarIlias Apalodimas <ilias.apalodimas@linaro.org>
      Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      6e0184b8
    • Ilias Apalodimas's avatar
      efi_loader: Force a single FMP instance per hardware store · b891ff18
      Ilias Apalodimas authored
      
      Chapter 23 of the EFI spec (rev 2.9) says:
      "A specific updatable hardware firmware store must be represented by
      exactly one FMP instance".
      This is not the case for us, since both of our FMP protocols can be
      installed at the same time because they are controlled by a single
      'dfu_alt_info' env variable.
      So make the config options depend on each other and allow the user to
      install one of them at any given time.  If we fix the meta-data provided
      by the 'dfu_alt_info' in the future,  to hint about the capsule type
      (fit or raw) we can revise this and enable both FMPs to be installed, as
      long as they target different firmware hardware stores
      
      Note that we are not using a Kconfig 'choice' on purpose, since we
      want to allow both of those to be installed and tested in sandbox
      
      Signed-off-by: default avatarIlias Apalodimas <ilias.apalodimas@linaro.org>
      Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      b891ff18
    • Masami Hiramatsu's avatar
      efi: Fix to use null handle to create new handle for efi_fmp_raw · 3ef77223
      Masami Hiramatsu authored
      
      When running the efidebug capsule disk-update command, the efi_fmp_raw
      protocol installation fails with 2 (EFI_INVALID_PARAMETER) as below.
      This is because the code passes efi_root instead of the handle local var.
      
      => efidebug capsule disk-update
      EFI: Call: efi_install_multiple_protocol_interfaces( &handle, &efi_guid_firmware_management_protocol, &efi_fmp_fit, NULL)
        EFI: Entry efi_install_multiple_protocol_interfaces(00000000fbaf5988)
          EFI: Call: efi_install_protocol_interface( handle, protocol, EFI_NATIVE_INTERFACE, protocol_interface)
            EFI: Entry efi_install_protocol_interface(00000000fbaf5988, 86c77a67-0b97-4633-a187-49104d0685c7, 0, 00000000fbfa6ee8)
              EFI: new handle 00000000fbb37520
            EFI: Exit: efi_install_protocol_interface: 0
          EFI: 0 returned by efi_install_protocol_interface( handle, protocol, EFI_NATIVE_INTERFACE, protocol_interface)
        EFI: Exit: efi_install_multiple_protocol_interfaces: 0
      EFI: 0 returned by efi_install_multiple_protocol_interfaces( &handle, &efi_guid_firmware_management_protocol, &efi_fmp_fit, NULL)
      EFI: Call: efi_install_multiple_protocol_interfaces( &efi_root, &efi_guid_firmware_management_protocol, &efi_fmp_raw, NULL)
        EFI: Entry efi_install_multiple_protocol_interfaces(00000000fbfec648)
          EFI: Call: efi_install_protocol_interface( handle, protocol, EFI_NATIVE_INTERFACE, protocol_interface)
            EFI: Entry efi_install_protocol_interface(00000000fbfec648, 86c77a67-0b97-4633-a187-49104d0685c7, 0, 00000000fbfa6f18)
              EFI: handle 00000000fbaf8520
            EFI: Exit: efi_install_protocol_interface: 2
          EFI: 2 returned by efi_install_protocol_interface( handle, protocol, EFI_NATIVE_INTERFACE, protocol_interface)
        EFI: Exit: efi_install_multiple_protocol_interfaces: 2
      EFI: 2 returned by efi_install_multiple_protocol_interfaces( &efi_root, &efi_guid_firmware_management_protocol, &efi_fmp_raw, NULL)
      Command failed, result=1
      
      To fix this issue, pass the handle local var which is set NULL right
      before installing efi_fmp_raw as same as the installing efi_fmp_fit.
      (In both cases, the local reference to the handle will be just discarded)
      
      Signed-off-by: default avatarMasami Hiramatsu <masami.hiramatsu@linaro.org>
      Signed-off-by: default avatarIlias Apalodimas <ilias.apalodimas@linaro.org>
      Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      3ef77223
  3. Jun 30, 2021
    • Tom Rini's avatar
      Revert "TEST: USB_HOST not USB" · b7ad721c
      Tom Rini authored
      
      This reverts commit 4e1903a6.
      
      This local commit was not intended to be pushed out.
      
      Signed-off-by: default avatarTom Rini <trini@konsulko.com>
      b7ad721c
    • Tom Rini's avatar
      TEST: USB_HOST not USB · 4e1903a6
      Tom Rini authored
      
      Signed-off-by: default avatarTom Rini <trini@konsulko.com>
      4e1903a6
    • Marek Vasut's avatar
      spi: Update speed/mode on change · e2e95e5e
      Marek Vasut authored
      
      The spi_get_bus_and_cs() may be called on the same bus and chipselect
      with different frequency or mode. This is valid usecase, but the code
      fails to notify the controller of such a configuration change. Call
      spi_set_speed_mode() in case bus frequency or bus mode changed to let
      the controller update the configuration.
      
      The problem can easily be triggered using the sspi command:
      => sspi 0:0@1000
      => sspi 0:0@2000
      Without this patch, both transfers happen at 1000 Hz. With this patch,
      the later transfer happens correctly at 2000 Hz.
      
      Signed-off-by: default avatarMarek Vasut <marex@denx.de>
      Cc: Jagan Teki <jagan@amarulasolutions.com>
      Cc: Patrick Delaunay <patrick.delaunay@foss.st.com>
      e2e95e5e
  4. Jun 29, 2021
  5. Jun 28, 2021
  6. Jun 25, 2021
  7. Jun 24, 2021
  8. Jun 23, 2021
Loading