Commit Graph

4748 Commits

Author SHA1 Message Date
Richard Hughes
94e3d24f55 bcm57xx: Make hotplug more reliable
Although hotpluggging PCIe cards isn't common, it's how I'm testing this in the
device test enclosure. Add a tiny delay to wait for the kernel to populate the
net class on hotplug.
2020-10-29 14:01:25 +00:00
Richard Hughes
a78b13fb71 Use a different Device ID for the OptionROM devices
We want to continue to dedupe the ID, and the priority should be decided on the
GUID match.

Fixes https://github.com/fwupd/fwupd/issues/2510 in a different way
2020-10-29 14:01:25 +00:00
Richard Hughes
e98845d6cf Revert "Fix regression when filtering different priorities"
This reverts commit f630678b6f.
2020-10-29 14:01:25 +00:00
Jonas Witschel
267dbd1612 contrib/ci: switch TPM simulator from ibmswtpm to swtpm
Upstream tpm2-tss is moving from ibmswtpm to swtpm as the default TPM
simulator. ibmswtpm still works fine and will be kept around for the
foreseeable future, but adapt to the upstream decision in case ibmswtpm should
ever get dropped from the official Arch Linux repositories (currently there are
no plans to do so).
2020-10-28 07:50:11 -05:00
Richard Hughes
8087b2c9e0 trivial: Set the 'downloading' state when starting the download
For small files we might not get progress callbacks and so we stay in IDLE
status forever.

Fixes https://github.com/fwupd/fwupd/issues/2522
2020-10-27 19:36:18 +00:00
Richard Hughes
ded5410f6d Delete unused EFI variables when deploying firmware
Unconditionally delete FWUPDATE_VERBOSE and FWUPDATE_DEBUG_LOG when deploying
the update using fwupdtool or fwupd and leave it to fwupdate.

If you want to debug the efi binary you then have to use fwupdate and squirt
the .cap file rather than using all the other layers.
2020-10-27 17:05:01 +00:00
Richard Hughes
6d257cbe7f Fix probe warning for the Logitech Unifying device
The same plugin name was being added to the device from the quirk file more than
once, and so we enumerated the device *again* and tried to add a duplicate
device -- the device list correctly refusing to do so.

Check the plugin name does not already exist before adding it, and add a self
test to catch this for the future.
2020-10-27 15:43:17 +00:00
Richard Hughes
49c2a78c99 Include the amount of NVRAM size in use in the LVFS failure report 2020-10-27 13:58:40 +00:00
Mario Limonciello
8aa5d41eb7 Add external interface messages 2020-10-26 12:05:20 -05:00
Richard Hughes
2409b302a6 trivial: Fix typo in HSI document 2020-10-26 15:17:39 +00:00
Mario Limonciello
6fc11ec089 trivial: fu-main: adjust polkit install flow
The authentication happens earlier in `fu_main_install_with_helper`
so no need to make recursive calls from `fu_main_authorize_install_cb`
into `fu_main_authorize_install_queue`.

Just simplify the code in the non-polkit case.
2020-10-26 10:05:41 -05:00
Richard Hughes
a2d8b94bf1 trivial: post release version bump 2020-10-26 11:52:16 +00:00
Richard Hughes
f90cda6f0b Release fwupd 1.5.0 2020-10-26 11:50:11 +00:00
Emily Miller
f9ad963bcf vli: Add support for Hyper hardware 2020-10-26 10:08:00 +00:00
Richard Hughes
f630678b6f Fix regression when filtering different priorities
We need to check if the device is in the remove timeout before unconditionally
replacing a device on insert.

Fixes https://github.com/fwupd/fwupd/issues/2510
2020-10-26 08:43:27 +00:00
Mario Limonciello
13d077353b Revert "fu-engine: Set a device when checking requirements for fu_engine_get_result_from_component"
This reverts commit e4d52866d1.
2020-10-24 07:07:26 +01:00
Mario Limonciello
381c27ca44 trivial: Split check for signed metadata when no polkit
Checking this requirement at daemon startup meant that trust was
evaluated before releases could actually be checked.

It's only important to check at install time.
2020-10-24 07:07:26 +01:00
Jingle Wu
3460e0a5ed elantp: Modify the correct input for the iap reg.
1. Modify the correct input for the iap reg (byte -> word).
2. Add new HWID for ThinkPad X1 Carbon Gen 9.
2020-10-23 08:56:48 +01:00
Mario Limonciello
e4d52866d1 fu-engine: Set a device when checking requirements for fu_engine_get_result_from_component
The trust flags are only checked if check_requirements is called, which
only happens when a device has been set.
2020-10-23 06:59:08 +01:00
Richard Hughes
cb0e614027 trivial: Do not list unsupported devices in switch-branch 2020-10-22 20:05:44 +01:00
Richard Hughes
e80547e8fc Record the TPM version when reporting a UEFI update
Fixes https://github.com/fwupd/fwupd/issues/2391
2020-10-22 16:16:23 +01:00
Richard Hughes
b814af80ef synaptics-cxaudio: Retry the HID SetReport to fix flashing the TB3 dock
Upon restarting the upstream VLI USB hub the cxaudio device re-enumerated okay
but would not service HID requests for 100ms, returning 'endpoint stalled'.

To make this more reliable retry the SetRequest up to 10 times after a short
delay to make enumeration reliable.
2020-10-22 14:36:05 +01:00
Richard Hughes
d9b97e308b Add a flag to retry the HID request up to 10 times
This is something that we now need in two plugins, so move it into common code.
2020-10-22 14:36:05 +01:00
Richard Hughes
3b577c5de3 bcm57xx: Fix trivial warnings when building on Win32 2020-10-22 13:55:14 +01:00
Richard Hughes
1fd1a8047e optionrom: Add the fuzzing functionality as a meson target 2020-10-22 13:22:34 +01:00
Richard Hughes
b619245897 trivial: Write up some release notes for the next release 2020-10-22 12:45:08 +01:00
Vincent Huang
a9d8074c61 synaptics-prometheus: add pids to quirk file 2020-10-22 08:21:30 +01:00
Richard Hughes
b7e406c217 ata: Add OUI quirk for Corsair 2020-10-21 20:18:27 +01:00
Mario Limonciello
02f2cc311e Add switch-branch support to fwupdtool 2020-10-21 12:00:55 -05:00
Richard Hughes
0d778dbd50 vli: Set the parent of the USB2 recovery for cosmetic reasons 2020-10-21 17:48:36 +01:00
Richard Hughes
07326182ca vli: Do not expose the shared-SPI devices on the USB2 recovery device 2020-10-21 17:48:25 +01:00
Mario Limonciello
b15f4ab4b1 elantp: Trivial whitespace fixes 2020-10-21 16:54:13 +01:00
Mario Limonciello
0ad124a02b elantp: Match all i2c-hid devices in quirk
In the plugin probe routine, check whether they are actually i2c-hid touchpad
by looking at PID.

Fixes #2494
2020-10-21 16:54:13 +01:00
Richard Hughes
f6a765d251 vli: Remove one of the catch-all PD VID:PID matches
This is already supported using the &APP_ GUID for the Lenovo USB-C Mini dock.
2020-10-21 16:25:12 +01:00
Mario Limonciello
7db8e88d98 When PK is disabled only allow trusted payloads
Loosen the requirement of the user ID to match root for the following
actions:
* Install release
* Activate firmware

For install release action, reject CAB files not signed by LVFS
2020-10-20 15:24:08 -05:00
Richard Hughes
a2a8f8ea70 Add fu_byte_array_set_size()
The GLib g_byte_array_set_size() function does not zero the contents if the
array size is larger, which leads to unpredictable output when using valgrind.
2020-10-20 19:54:07 +01:00
Richard Hughes
92769bfba1 trivial: Use fu_device_sleep_with_progress() in one more place 2020-10-20 18:21:27 +01:00
Richard Hughes
d7e3f09cbf trivial: Show what the device does support if the protocol match fails 2020-10-20 18:21:04 +01:00
Mario Limonciello
c3a8173a12 Show an error when a plugin is missing dependencies (Fixes: #1526)
```
$ sudo mv /usr/lib/x86_64-linux-gnu/libtss2-esys.so.0.0.0 /usr/lib/x86_64-linux-gnu/libtss2-esys.so.0.0.0.renamed
$ sudo fwupdtool get-devices --plugins=uefi
14:15:48:0735 FuEngine             cannot load: failed to open plugin /usr/local/lib/x86_64-linux-gnu/fwupd-plugins-3/libfu_plugin_uefi.so: libtss2-esys.so.0: cannot open shared object file: No such file or directory
Loading…                 [-                                      ]14:15:48:0753 FuEngine             failed to update history database: device ID b6c08fb9e5384d9d101853cc1ca20cf0ce2df2e2 was not found
Loading…                 [***************************************]
WARNING: Plugin depdendencies missing
No detected devices
```
2020-10-20 10:57:21 -05:00
Richard Hughes
04d0a1b863 vli: Use the tokenization data for the Intel HEX file 2020-10-20 16:27:15 +01:00
Richard Hughes
6a29672bc3 Do more processing when tokenizing the Intel HEX file 2020-10-20 16:27:15 +01:00
Richard Hughes
c7283ea61e uefi: Drop efivar dependency 2020-10-19 16:13:21 +01:00
Richard Hughes
f019971c00 redfish: Drop efivar dependency 2020-10-19 16:13:21 +01:00
Mario Limonciello
68df30bd2b dell: Drop efivar dependency
Since we removed the ability to turn on/off force power this is dead code, and
an unnecessary dependency.
2020-10-19 16:13:21 +01:00
Richard Hughes
81b5defaa6 uefi: Use fu_efivar_get_data() to fix setting BootNext correctly
Fixes https://github.com/fwupd/fwupd/issues/2169
2020-10-19 16:13:21 +01:00
Richard Hughes
43053d2a13 Do not include fullstops in the --help output
Fixes https://github.com/fwupd/fwupd/issues/2487
2020-10-19 00:43:49 +01:00
Richard Hughes
377feea500 Only show the HSI for sane chassis types
Fixes https://github.com/fwupd/fwupd/issues/2440
2020-10-18 20:24:10 +01:00
Richard Hughes
9f93b8bc66 trivial: Add fu_smbios_get_integer() helper 2020-10-18 20:24:10 +01:00
Richard Hughes
f2a3e01f96 Simplify fu_device_list_wait_for_replug() for sanity
Rather than using a recursive GMainLoop, just run a single iteration of the
mainloop every 1ms while we're waiting.

This simplifies the device lifecycle dramatically as we don't have to worry
about reentrant removals. It's also a lot simpler to debug as we know the only
way to return is the timeout elapsing or FWUPD_DEVICE_FLAG_WAIT_FOR_REPLUG being
unset.

If multiple devices got removed and we're waiting for one to re-appear, also
wait for all devices to come back before returning to the main loop.

In the worst case, this causes the device list to wait the full removal_delay
for the device rather than returning when the first device matches. This allows
us to simplify the hub update when we reboot the entire device and various
devices from different plugins come back in an unpredictable order.

Fixes the other half of https://github.com/fwupd/fwupd/issues/2376
2020-10-18 07:35:46 +01:00
Richard Hughes
ae5858ff58 vli: Get the new firmware version when updating the PD device
To do this without rebooting the device implement VliUsbhubPdDevice->reload()
like the other FuVliUsbhubDevice child devices.

Fixes half of https://github.com/fwupd/fwupd/issues/2376
2020-10-18 07:35:46 +01:00