Commit Graph

15 Commits

Author SHA1 Message Date
Richard Hughes
8a71bd128f vli: Add no-guid-matching for all VLI devices
We need to detect different USB 3.x hubs on the ThinkPad Basic, Pro and Ultra
docking stations.
2020-05-15 16:38:18 +01:00
Richard Hughes
cddf5b5b89 Only auto-add counterpart GUIDs when required
Doing this unconditionally means we accidentally 'bleed' one device mode into
another in a non-obvious way. For instance, a device might have two operating
modes with different GUIDs. If firmware is supplied for both modes in the same
cabinet archive then we might accidentally match the 'wrong' firmware when
the daemon has observed a mode switch and added the counterpart GUIDs.

We only really need the counterpart GUIDs when switching between Jabra, 8bitdo
and DFU devices where the DFU bootloader VID:PID is not manually tagged with
`CounterpartGuid` in a quirk file. In the general case lets keep it simple to
avoid difficult to find bugs.
2020-04-08 13:55:39 +01: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
ac48c7f45a trivial: Add a GObject property for FuVliDevice::kind 2020-03-19 06:43:42 +00:00
Richard Hughes
aebd90baad vli: Fix VL103 reboot from ROM mode to FW mode
The logic was wrong; we should have been using command 0xB0 for attach back to
FW mode for both VL10x and VL103. Using a generic reset on VL103 always reset
the device back into bootloader mode as the ROM signatures were being written
by command 0xC0.

As now attach and detach have different code paths, there's no point having a
`FuVliDevice->reset()` vfunc, and so we can make everything a little simpler at
the same time.
2020-03-10 10:46:01 +00:00
Richard Hughes
e4661788ec vli: Set the device progress correctly when erasing a PD device 2020-02-06 20:38:19 +00:00
Richard Hughes
4359ea9017 vli: Set all standalone PD devices to not do SPI auto-detection 2020-02-06 20:38:19 +00:00
Richard Hughes
e01c4cc8cb vli: Add the DEV instance ID to all devices
In some composite dock hardware there are two USB devices exported to the host,
both with the same VID:PID values. We need to use the device type (e.g. VL812B3)
to differenciate the devices and install the correct fw on the correct device.
2020-02-04 15:52:07 +00:00
Richard Hughes
5bf8c1a23b vli: Set more of the firmware max sizes automatically
With data from VIA, many thanks.
2020-01-02 13:24:13 +00:00
Richard Hughes
727938427b vli: Add a SpiAutoDetect quirk for some of the PD devices
It seems command 0xc0 is not supported on this hardware.
2020-01-02 13:24:13 +00:00
Richard Hughes
a24752d661 vli: Add support for standalone Single PD devices 2020-01-02 13:24:13 +00:00
Richard Hughes
52a7d0bd34 vli: Move generic SPI functionality into the FuVliDevice base class
To implement the SPI commands, objects can derive from FuVliDevice and
implement the new vfuncs. This allows us to override the implementation for
minor API changes.
2020-01-02 13:24:13 +00:00
Richard Hughes
e2a9b15f16 vli: Allow setting the device kind from a quirk 2020-01-02 13:24:13 +00:00
Richard Hughes
3243374d41 vli: Move the SPI command quirking from FuVliUsbhubDevice down to FuVliDevice 2020-01-02 13:24:13 +00:00
Richard Hughes
b02d9988ad vli: Add a FuVliDevice as a subclass to FuVliUsbhubDevice
At the moment this doe not do anything clever, but other device types will
derive from the base class in the future.
2020-01-02 13:24:13 +00:00