Richard Hughes
855ece352d
Check the alignment when reading in raw firmware
2022-04-28 14:15:49 +01:00
Richard Hughes
3553336eff
trivial: Don't print a critical warning in fu_common_sum8_bytes()
...
If the size if zero, the buffer may be NULL.
Fixes: https://oss-fuzz.com/testcase-detail/5453386322935808
2022-04-28 07:24:00 +01:00
Richard Hughes
f3ec632492
trivial: Add some new helper API for future functionality
2022-04-26 14:30:28 +01:00
Richard Hughes
492563d5f2
trivial: Ignore the return value of g_strlcpy() when safe
2022-04-23 10:30:50 +01:00
Richard Hughes
a1517e4875
dfu: Use the correct icon automatically for USB webcams
2022-04-23 08:56:58 +01:00
Richard Hughes
519110b70e
Support firmware with uSWID header version 2
...
This allows multiple coSWID objects to be saved into a uSWID firmware,
and adds support for Zlib compressed payloads.
2022-04-18 17:48:52 +01:00
Richard Hughes
2d5186622c
Add FuProgress to ->prepare and ->cleanup
...
Some plugins were creating local versions (which were not attached to
the daemon progress in any way) as a workaround as they needed to do
actions that took a long time to complete.
2022-04-15 16:50:06 +01:00
Richard Hughes
a8497ad5c2
trivial: Allow invalidating backends when subsystems change
2022-04-15 16:49:48 +01:00
Richard Hughes
58fd419fb8
Do not clear the instance-id hash during ->setup()
...
Some plugins rely on adding more instance IDs after the device has been
added.
2022-04-15 06:49:51 +01:00
Richard Hughes
0b7af7d54b
trivial: Ignore the return value of setenv() in most cases
...
This makes Coverity happy.
2022-04-13 15:08:12 +01:00
Richard Hughes
0d7d8b3240
trivial: Always call va_end() even in the error path
2022-04-13 15:08:12 +01:00
Richard Hughes
2883b577dc
trivial: Fix a potential OOB write that can't actually happen
2022-04-13 15:08:12 +01:00
Mario Limonciello
65e3bc57c5
trivial: fix a logic error in obsolete calculation
2022-04-12 12:23:16 -05:00
Mario Limonciello
3006d238d6
Automatically obsolete negative duplicate attributes
...
To a user there is no point to explicitly showing two failures for
encrypted RAM if the system supports SME and TSME both.
To show them a single failure, de-duplicate the attributes by appstream
ID during depsolve.
If the plugin didn't explicitly set obsoletes and two attributes are both
failures and both share the same appstream ID obsolete one of them.
2022-04-12 11:59:49 -05:00
Richard Hughes
f4fb625fba
Set the context automatically when setting the device proxy
2022-04-11 15:36:13 +01:00
Sergii Dmytruk
4795ab3122
trivial: libfwupd,libfwupdplugin: fix typos in several comments
...
Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
2022-04-11 15:31:03 +01:00
Richard Hughes
633571fa99
trivial: Fix some 'Comparison of narrow type with wide type in loop condition'
2022-04-05 14:45:42 +01:00
Richard Hughes
91e9f359c3
Add a plugin for the CH341A device
2022-04-03 16:29:30 +01:00
Mario Limonciello
55af9a8238
trivial: return an error string rather than HSI number for missing data
2022-04-03 09:06:00 -05:00
Richard Hughes
18f3b927e0
Add some default size values to the CFI device
2022-04-01 19:35:36 +01:00
Richard Hughes
f042bbd42c
Add fu_common_reverse_uint8() for future functionality
2022-03-31 16:34:27 +01:00
Richard Hughes
356bd2fa5e
Use the CFI manufacturer ID to set the vendor
2022-03-31 15:44:54 +01:00
Richard Hughes
ea9dd851af
trivial: Add a missing possible CFI quirk key
2022-03-31 15:44:54 +01:00
Richard Hughes
dcd39d80a7
Add the CFI quirks in setup() so the device can be open
2022-03-31 12:47:13 +01:00
Richard Hughes
b3e1b74d21
trivial: Use the proxy physical ID automatically
2022-03-31 09:59:33 +01:00
Richard Hughes
691166d203
trivial: Use a short string form for the CFI commands
2022-03-30 18:45:49 +01:00
Richard Hughes
04f00e8a17
trivial: Never return the invalid value from fu_progress_get_percentage()
2022-03-30 18:42:01 +01:00
Richard Hughes
16edfd345e
Correctly probe USB-2 hubs with more than 7 ports
...
See https://github.com/fwupd/fwupd/pull/4426#discussion_r836155609
2022-03-30 07:09:26 +01:00
Richard Hughes
5817ef3b4f
Emit 0% in FuProgress to show the child has started
...
This prevents showing the 'old' percentage until the first sub-task has
completed for some device firmware updates.
2022-03-29 20:04:26 +01:00
Richard Hughes
c1ff3e67af
trivial: Fix a small memory leak when getting the udev parent
2022-03-25 21:12:53 +00:00
Richard Hughes
41bc319331
trivial: Fix -Wundef warning when compiling without libcbor
2022-03-18 10:38:12 +00:00
Richard Hughes
da37d93eb0
trivial: Remove some long dead docs about fu_plugin_device_add_delay()
2022-03-16 09:18:29 +00:00
Richard Hughes
8b62bf6b64
Set the context in the right place more often
2022-03-16 09:18:29 +00:00
Richard Hughes
945002f7a3
Fix build for MacOS
...
This is more for curiosity than anything else.
2022-03-15 14:37:28 +00:00
Richard Hughes
92515d193a
Add coSWID and uSWID parsers to libfwupdplugin
...
These parse the structures as defined in:
* https://datatracker.ietf.org/doc/draft-ietf-sacm-coswid/
* https://github.com/hughsie/python-uswid
2022-03-15 14:37:02 +00:00
Richard Hughes
6b5d933e99
Do not show unconnected or unreachable devices in the client tools
...
Fixes https://github.com/fwupd/fwupd/issues/4378
2022-03-15 14:08:17 +00:00
Richard Hughes
e8f0d76da7
Do not leak child processes when cancelling
...
See https://github.com/fwupd/fwupd/pull/4372
2022-03-15 14:01:45 +00:00
Richard Hughes
b4e88bae49
trivial: Move the UNREACHABLE inhibit to common code
2022-03-15 11:29:00 +00:00
Daniel Campello
61226b49f3
fwupdplugin-self-test: fix spawn tests for qemu
...
Wrap the spawned script with an explicit call to the /bin/sh
interpreter needed when running tests in a cross compiled enviroment.
Also increase the timeout for the spawned script to execute to give
enough time for the print to happen in the much slower virtualized
environment.
Change-Id: I71ed377e1bc8db4be4c522cdb9562c1662df7266
2022-03-09 17:32:40 -07:00
Richard Hughes
66cb93c4e2
trivial: Make clear sizes are in hex
2022-03-07 12:38:33 +00:00
Richard Hughes
94d572375f
trivial: Clarify the unit for the device remove delay
2022-03-03 11:26:17 +00:00
Richard Hughes
c4ca026294
Allow devices to build instance IDs more easily
...
Provide a device instance builder that allows plugins to easily
create multiple instance IDs based on parent attributes.
Also fix a lot of the instance ID orders, so that we add more generic
IDs first, and more specific IDs after.
2022-03-03 09:13:29 +00:00
Mario Limonciello
d04f2468c0
trivial: switch from path to full_path for meson 0.56+
2022-02-28 08:34:48 -06:00
Mario Limonciello
6896e0ab52
trivial: switch from meson.source_root to meson.project_source_root
...
The former is deprecated in meson 0.56 or later.
2022-02-28 08:34:48 -06:00
Mario Limonciello
661990ed98
Convert build system to use meson tristate features
...
tristate features will automatically disable if dependencies marked
as required are missing.
Packagers can manually override using `auto_features`.
Link: https://mesonbuild.com/Build-options.html#features
2022-02-28 08:34:48 -06:00
Daniel Campello
bcaeda34ad
Backfill SHA256 when generating metadata from cab files
...
This change allows for the computation of SHA256 checksum when
generating metadata from cabinet file. This is particularly used when
working with the directory type of remote config.
Change-Id: I1a6e90a76b79cdae97d68d799a5cea81430da03f
2022-02-25 10:31:03 +00:00
Richard Hughes
adfef91731
trivial: Strip leading and trailing spaces from the vendor name
2022-02-24 17:07:44 +00:00
Richard Hughes
e3583793ed
trivial: Fix two potential critical warnings when finding devices
2022-02-24 17:07:32 +00:00
Richard Hughes
f3a13f89dd
Allow specifing the DeviceIntegrity flag from metadata
2022-02-22 19:12:06 +00:00
Richard Hughes
758d5d8c6f
Add a flag to indicate the device is signed or unsigned
...
Devices without either flag are unknown.
2022-02-22 19:12:06 +00:00