Commit Graph

1499 Commits

Author SHA1 Message Date
Mario Limonciello
80d9b7450c logitech_hidpp: set the bootloader protocol 2020-03-31 13:05:42 -05:00
Richard Hughes
6fa43550fc vli: Wait for the VL103 to timeout to fix detach
The default re-enumeration delay is not sufficient.
2020-03-31 09:34:15 +01:00
Richard Hughes
61d9449d31 ccgx: Show the UpdateMessage in the correct device mode 2020-03-31 08:59:27 +01:00
Richard Hughes
be12af78f0 ccgx: Add extra instance IDs to match specific firmware
The VID:PID of the device in HPI mode is shared between multiple vendors, and
so we need to use both the silicon ID and the application ID to match specific
firmware updates.
2020-03-31 08:59:27 +01:00
Mario Limonciello
97acc2bf74 thunderbolt: Rather than hardcoding to PCI slot numbers, use domain in GUID
This allows the PCI topology to change, but assumes that thunderbolt host controllers
are enumerated in the same order every time.
It won't matter if the first controller jumped from bus 5 to 7 and consequently the
second from 65 to 71, but rather that the first was enumerated followed by the second.
2020-03-28 09:52:38 -05:00
Mario Limonciello
e6d76a594c Revert "thunderbolt: Create a unique GUID including Thunderbolt controller path"
This reverts commit 7e38dffdcb.
2020-03-28 09:52:38 -05:00
Richard Hughes
eb326f7546 dell-dock: Port to fu_device_retry() 2020-03-28 12:46:03 +00:00
Richard Hughes
461149e636 nitrokey: Convert to use FuHidDevice 2020-03-28 12:46:03 +00:00
Richard Hughes
355d5d545d nitrokey: Port to fu_device_retry() 2020-03-28 12:46:03 +00:00
Richard Hughes
a3740518b2 vli: Port to fu_device_retry() 2020-03-28 12:46:03 +00:00
Richard Hughes
49797d7de4 ccgx: Reset the i2c bridge on status failure 2020-03-28 12:46:03 +00:00
Richard Hughes
8e86b1ec4c trivial: Fix the ThinkPad USB-C Dock Gen2 audio device parent 2020-03-27 14:25:17 +00:00
Richard Hughes
5d787b5958 trivial: Set up the parent GUIDs for the Lenovo Gen2 Dock 2020-03-27 13:57:09 +00:00
Richard Hughes
81da69e73d ccgx: Implement writing firmware to flash
Correctly attach into the alternate mode after the update has completed.

The vendor was appending two files to make LVFS distribution 'easier' but I'd
much rather use the same deliverables as Windows. This also allows us to
simplify the firmware loading.
2020-03-27 13:25:40 +00:00
Changhee (Ryan) Lee
338f5a4083 ccgx: Add i2c status check when reading or writing registers
Signed-off-by: Richard Hughes <richard@hughsie.com>
2020-03-27 13:25:40 +00:00
Changhee (Ryan) Lee
064c5cce19 ccgx: Add 5ms delay between read registers to avoid an i2c error
Signed-off-by: Richard Hughes <richard@hughsie.com>
2020-03-27 13:25:40 +00:00
Richard Hughes
464eacdc53 libfwupdplugin: Use fu_device_locker_close() 2020-03-26 15:23:10 -05:00
Richard Hughes
d66a445ada synaptics-mst: Use fu_device_locker_close() 2020-03-26 15:23:10 -05:00
Richard Hughes
87d39d06a3 ccgx: Do not store the silicon ID in the image address
First, it's a hack; second we actually need to store the start address for
flashing FW2 on asymmetric hardware...
2020-03-24 21:16:08 +00:00
Richard Hughes
bf5481e358 ccgx: Add device quirks for the Lenovo Hybrid Dock 2020-03-24 21:16:08 +00:00
Richard Hughes
9278e265b4 ccgx: Switch HID mode to HPI mode at startup 2020-03-24 21:16:08 +00:00
Richard Hughes
dab6bda2be ccgx: Clear the event queue when in startup 2020-03-24 21:16:08 +00:00
Richard Hughes
fd7f13f905 ccgx: Wait for hardware to settle when coming out of reset 2020-03-24 21:16:08 +00:00
Richard Hughes
3990a71401 ccgx: Do not mark the device as updatable when in boot mode 2020-03-24 21:16:08 +00:00
Richard Hughes
c6147bf340 ccgx: Verify the firmware app type when preparing firmware 2020-03-24 21:16:08 +00:00
Richard Hughes
754d85e282 ccgx: Set the update message when running in backup firmware 2020-03-24 21:16:08 +00:00
Richard Hughes
de61d27259 ccgx: Read the FwAppType from the hardware 2020-03-24 21:16:08 +00:00
Richard Hughes
2b45362e25 ccgx: Set the HPI version number for the current firmware 2020-03-24 21:16:08 +00:00
Richard Hughes
c6a671be7e ccgx: Get the silicon ID to map the flash parameters 2020-03-24 21:16:08 +00:00
Richard Hughes
11fa0a1e90 ccgx: Read the HPI device mode at startup 2020-03-24 21:16:08 +00:00
Richard Hughes
0a37232ba1 ccgx: Set up the HPI I²C config at startup 2020-03-24 21:16:08 +00:00
Richard Hughes
69b761ce64 trivial: Export fu_device_add_instance_id_full() for plugins to use
Sometimes we only want to add the instance ID to get the quirk matches, and it
is confusing to see the "fake" IDs in the 'fwupdmgr get-devices' output.
2020-03-24 14:43:31 +00:00
Richard Hughes
cff23f798f trivial: Autodetect the HID interface to use 2020-03-24 08:34:16 -05:00
Richard Hughes
62aa46cb83 ccgx: Create devices when in HID and I2C modes 2020-03-23 20:02:17 +00:00
Richard Hughes
46963b1118 csr: Allow truncated HID reads
The device is allowed to return short buffers during read operation. This fixes
a regression introduced in c04f5a3.

Fixes https://github.com/fwupd/fwupd/issues/1893
2020-03-23 13:40:34 +00:00
Emily
5f3a2c0bc1 vli: Only consider the high nibble when building the sub-version 2020-03-23 08:11:14 +00:00
Richard Hughes
ded9fef4b6 csr: Parse the firmware as a DFU file
This was changed to Intel hex in 7afd7cba0d,
probbaly due to a copy-paste mistake. Change it back to DFU.

Fixes https://github.com/fwupd/fwupd/issues/1890
2020-03-22 11:46:40 -05:00
Richard Hughes
811e75db4b Add support for EP963x hardware 2020-03-22 15:48:04 +00:00
Richard Hughes
c04f5a3e15 Add FuHidDevice abstraction
Quite a few plugins use HID commands to communicate with the hardware. At the
mement we have ~6 implementations of SET_REPORT and are soon to add one more.

Move this into common code.
2020-03-19 17:02:07 +00:00
Richard Hughes
dd34e51711 trivial: Fix up some argument names with additional docs 2020-03-19 06:43:42 +00:00
Richard Hughes
ed07a17509 vli: Correctly attach VL103 after a firmware update
This works around a silicon errata which makes the existing 0xB0 chip reset
non-functional.

ALso, as VL10x and VL103 are so different now, use different `->attach()` and
`->detach()` implementations for code sanity.

Based on a patch by Sherlock Chu <SherlockChu@via-labs.com>, many thanks.
2020-03-19 06:43:42 +00:00
Richard Hughes
ac48c7f45a trivial: Add a GObject property for FuVliDevice::kind 2020-03-19 06:43:42 +00:00
Richard Hughes
48d9fb8f74 ccgx: Parse the metadata block in the firmware image 2020-03-18 18:57:06 +00:00
Richard Hughes
b258e514c5 ccgx: Add a firmare parser for cyacd files
These are visually similar to Intel hex files, but different enough to demand
their own parser. Multiple images can be stored in one firmware file, with the
`addr` set to the SiliconID and the `idx` set to the position in the file.
2020-03-18 18:57:06 +00:00
Mario Limonciello
c0f1f1c7e3 trivial: logitech-hidpp: decrease the verbosity of some debugging 2020-03-17 18:43:08 -05:00
Mario Limonciello
15cb61b34e trivial: logical-hidpp: fix some debugging messages not working 2020-03-17 18:43:08 -05:00
Mario Limonciello
c6ae0d998b logitech: Correctly set the protocol
Fixes updates on signed receivers.
2020-03-17 18:43:08 -05:00
Richard Hughes
252b0c704e vli: Remove a dock device from the whitelist that is never going to be updated
This is an old EOL dock that does not respond well to probing -- leading to an
occasional multi-second startup deadlock on startup.
2020-03-16 11:56:35 +00:00
Richard Hughes
3dadb99c6c vli: Add some trivial debugging to help track down a bug 2020-03-16 11:56:35 +00:00
Richard Hughes
bd5e6f00d2 vli: Never add USB hub devices that are not upgradable
There's almost no point; you can't interact with them in any meaningful way.
2020-03-16 11:56:35 +00:00