My Analogix USB device has a Billboard interface, with bNumEndpoints=0.
When emulating the interface is NULL, and in runtime the array can *never* be
NULL, so I think this check was added in error.
The wacom-usb plugin was created in a simpler time, before we had the concept
of `FuDevice.proxy`. Switch to the shared code to modernize the code, and also
because setting the proxy conveys other semantics that we need to emulate the
device successfully in the future.
We go to great pains to set the parent to the MAX of the child delays, but we
don't actually set the children to have the new parent value.
This means if you update the child device without the parent in the transaction
we don't always wait for all the USB devices to come back -- which is what the
acquiesce delay is designed to do.
Fixes an intermittant device test for the Wacom USB tablet.
The Element Hub (and several other docks that use the CCGX5 DMC reference
design) is in "factory mode" out of the box, displaying a version of `0.0.0.0`
Detect factory mode and set a non-zero version -- using the "real" version if
possible by matching the CCG5 devx base firmware firmware.
The snap is converted into a confined version, but we need to make
sure that the snapd has promoted into a stable release so that fwupd
snap also works.
We should revert this after that happens.
Converting 'simple' non-nested formats like Intel Hex into nested formats like
DfuSe needs us to create a binary child firmware to avoid missing data.
Fixes https://github.com/fwupd/fwupd/issues/5493
We use GetReleases for all the *possible* releases that could be installed
(although the device might be in UPDATABLE_HIDDEN), and the legacy GetUpgrades
API just wants to know what can be done right now.
This is regenerated on every device hotplug event, and although infrequent
there is no point doing all that CPU-heavy requirement checking for no reason.
This allows us to only shut down the P2P daemon in the installed tests.
The easy fix would have been to use something like:
gdbus call --address unix:path=/run/fwupd.sock --object-path / --method org.freedesktop.fwupd.Quit'
...but the daemon does not implement an ObjectManager, which gdbus requires.
This worked correctly for so long because the p2p tests were being run after
the bus tests, so shutting down the system daemon had no effect.
Fedora 37 seems to have flipped the order for some reason -- and now it
*sometimes* matters that we were doing the worng thing...
The SMBIOS specification says:
Maximum size of SMBIOS Structure Table, pointed to by the
Structure Table Address, in bytes. The actual size is guaranteed
to be less or equal to the maximum size.
So, the firmware is actually allowed to return a DMI blob smaller than the
specified size.
Fixes https://github.com/fwupd/fwupd/issues/5486
This allows us to ignore all the delays when the device is emulated, with the
idea being to do dozens of device emulations in the CI tests.
Also, do not call fu_progress_sleep() when the device is emulated.
If the device does not replug, and we change the GUsbDevice because the phase
changed we don't want reprobe the hardware.
If we reprobe then the emulated device will request extra data compared to the
real device, which will cause emulation to fail.