Commit Graph

154 Commits

Author SHA1 Message Date
Richard Hughes
fc2da47b69 Remove fu_strtoull_full() 2022-06-14 14:36:52 -05:00
Richard Hughes
377bcb718f Remove the 'common' prefix from the volume creation methods 2022-06-14 14:36:52 -05:00
Richard Hughes
4105768a01 Remove the 'common' prefix when parsing version numbers 2022-06-14 14:36:52 -05:00
Richard Hughes
3e0a4dc1c3 Be smarter and include less header files per source file 2022-06-14 14:36:52 -05:00
Richard Hughes
067d7d8088 Split out the path helpers to a new source file 2022-06-14 14:36:52 -05:00
Richard Hughes
7f86ffab6f Split out the dump helpers to a new source file 2022-06-14 14:36:52 -05:00
Richard Hughes
425fedcca1 trivial: Remove fu_byte_array_set_size_full() 2022-06-14 14:36:52 -05:00
Richard Hughes
ed1b13da28 Split out the memory helpers to a new source file 2022-06-14 14:36:52 -05:00
Richard Hughes
4b1313b406 Split out the GByte helpers to a new source file 2022-06-14 14:36:52 -05:00
Richard Hughes
9d33c29e92 Split out the string helpers to a new source file 2022-06-14 14:36:52 -05:00
Richard Hughes
3fe9c0de34 Split out the CRC and sum functions to new source files 2022-06-14 14:36:52 -05:00
Richard Hughes
e60a877c46 uefi-capsule: Do not generate a capsule header for the FMP GUID
In theory, hardware with FMP should have fw_type=0x4 in the ESRT which
sets `_NO_CAPSULE_HEADER_FIXUP` -- but in reality that is not always
the case.
2022-06-14 14:11:26 +01:00
Richard Hughes
e6b487e762 Add FuProgress to ->startup() and ->coldplug()
This allows us to profile the daemon startup so we can find any plugins
taking an inordinate amount of time to start.
2022-06-04 20:21:50 +01:00
Richard Hughes
dc91d59f8e Remove the recently added fu_progress_add_step_full()
Just break API instead.
2022-06-03 13:47:11 -05:00
Richard Hughes
f9e6aa16a3 Remove some deprecated API 2022-06-03 13:47:11 -05:00
Richard Hughes
5ef0ae182d Add a 'name' attribute to each FuProgress step
This allows us to print better warning strings, and in the future
would allow us to profile each operation in a meaningful way.

Also, add context to some of the progress steps as required.
2022-06-01 15:05:43 +01:00
Klemens Nanni
9d67fecabb trivial: Typofix fwupdate(1) NAME 2022-05-27 08:54:11 -05:00
Richard Hughes
5ceabcda1a trivial: Remove the class structs for types that use G_DECLARE_FINAL_TYPE 2022-05-21 12:19:50 +01:00
Richard Hughes
b7bf0a7611 Do not fallback to audio-card
Let the frontend choose the most appropriate icon if unspecified.
2022-04-25 14:49:30 +01:00
Mario Limonciello
0432cfe537 trivial: uefi: drop unnecessary HAVE_HSI declaration
This appears to have been from before a vfunc was added and isn't
necessary.
2022-04-18 10:01:02 -05: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
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
bef1d742b3 Allow Capsule-on-Disk to work in more cases 2022-04-12 09:57:44 +01:00
Richard Hughes
4bdd1d40e1 uefi-capsule: Use GByteArray to make code more modern 2022-04-08 07:23:48 +01:00
Richard Hughes
92944f5074 Add the runtime fwupd-efi version as a firmware requirement 2022-04-07 16:55:46 +01:00
Richard Hughes
3640d22fb2 Use the GLib functions to convert to UCS2
UTF-16 is a superset of UCS-2 and so we can just use the GLib versions
instead of rolling our own versions.
2022-04-07 15:41:09 +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
Jeremy Soller
09f3a627c2 trivial: Add HP Dev One quirk with no-ux-capsule flag 2022-04-01 11:18:12 -05:00
Richard Hughes
8b62bf6b64 Set the context in the right place more often 2022-03-16 09:18:29 +00:00
Richard Hughes
2e92dc02d1 uefi: Do not add the Windows compat ID
This is just confusing vendors and doesn't match any of the other IDs.
2022-03-01 12:52:12 +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
Richard Hughes
f3a13f89dd Allow specifing the DeviceIntegrity flag from metadata 2022-02-22 19:12:06 +00:00
Richard Hughes
c8e5f92f27 uefi-capsule: Add a private flag for devices that never want a header 2022-02-21 22:52:45 -06:00
Richard Hughes
50b52aef0d trivial: Do not install test data for -Dtests=false 2022-02-16 19:38:45 +00:00
Yuan-Chen Cheng
4642e7694e fall back to signed EFI app as secure boot is off.
Some distribution hopes to not install the not-signed EFI app by default.
However, for the corner case, the user might still want to use not-signed
one (maybe to work around bugs or do testing). This implements
a logic that uses the not-signed EFI app as the secure boot is off, and
if it does not exist, then we fall back to using the signed one.

Also drop fwupd-unsigned from Recommends of fwupd in debian/control.
2022-02-15 08:15:56 -06:00
Richard Hughes
b5e7a0be16 Do not use gettext before calling setlocale 2022-02-09 16:56:47 +00:00
Norbert Kamiński
7fdf7c60ee fu-uefi-common.h: Fix efivar compatibility with FreeBSD
Signed-off-by: Norbert Kamiński <norbert.kaminski@3mdeb.com>
2022-01-21 16:24:37 +00:00
Richard Hughes
e74d38bfd3 Fix compiling with new versions of efivar
Fixes https://github.com/fwupd/fwupd/issues/4181
2022-01-17 15:27:05 +00:00
Mario Limonciello
64e7ea25b1 Fix the logic for removable fallback path in uefi-capsule
The logic was built on the presumption of Ubuntu core which doesn't
have /etc/os-release.  Since other distributions do have /etc/os-release
adjust the logic to instead build the path explicitly.
2022-01-15 07:09:04 -06:00
Richard Hughes
73f6767d87 trivial: Show why more devices are not marked as updatable 2022-01-13 16:04:31 +00:00
Richard Hughes
ca43733a8c Show why devices are not marked as updatable
At the moment a lot of the failures are only visible when running the
daemon in verbose mode, and the inhibit functionalit provides us a way
to unset FWUPD_DEVICE_FLAG_UPDATABLE from multiple places, as well as
setting the update error for the user to see why.
2022-01-13 12:40:56 +00:00
Mario Limonciello
f57a6637c9 trivial: fix man page sections
They're marked in the man page as section 8 but installed into 1.
They should be installed into 1 as they're not admin tools.
2022-01-04 14:17:43 -06:00
Richard Hughes
e17a107ce1 trivial: Cast the g_signal_connect() object to allow static analysis
This is useful when using https://gitlab.freedesktop.org/tartan/tartan
2022-01-03 22:46:23 +00:00
Richard Hughes
2e99055d1e trivial: Add some more annotations for language bindings 2022-01-03 22:46:23 +00:00
Richard Hughes
f76880182f Do not allow UEFI updates when the lid is closed
Most vendors do not mirror the firmware update to an external display,
and some don't behave correctly when the lid is shut and the machine is
docked. Add this quirk just for Lenovo for now.

Fixes https://github.com/fwupd/firmware-lenovo/issues/181
2021-12-29 19:18:26 +00:00
Richard Hughes
8e6a3f6bbb Allow devices to opt-in to metadata-provided vendor strings 2021-12-22 15:34:36 +00:00
Philipp Wendler
935e92d079 uefi-capsule: clarify UDisks requirement for ESP autodetection
The ESP is autodetected only if UDisks is available,
but this was not explicitly documented so far.

Fixes #4103
2021-12-17 14:35:08 -06:00
Richard Hughes
8fc8539146 trivial: Remove some unused variables 2021-12-10 16:00:07 +00:00