Commit Graph

679 Commits

Author SHA1 Message Date
Mario Limonciello
02ccecb2be fix dfu plugin loading
failed to open plugin
/usr/lib/x86_64-linux-gnu/fwupd-plugins-2/libfu_plugin_dfu.so:
failed to open plugin:
/usr/lib/x86_64-linux-gnu/fwupd-plugins-2/libfu_plugin_dfu.so:
undefined symbol: dfu_device_upload
2016-12-13 13:19:55 -06:00
Mario Limonciello
f074b0d367 Fix udev plugin loading
failed to open plugin /usr/lib/x86_64-linux-gnu/fwupd-plugins-2/libfu_plugin_udev.so:
failed to open plugin: /usr/lib/x86_64-linux-gnu/fwupd-plugins-2/libfu_plugin_udev.so:
undefined symbol: g_udev_device_get_property
2016-12-13 13:19:51 -06:00
Mario Limonciello
e781bb9b64 trivial: fix cosmetic fallout from provider -> plugin
some code (such as libfwupd) still internally refers to provider,
but this will need to be more carefully massaged
2016-12-13 12:25:09 -06:00
Mario Limonciello
6a1cbc61b2 trivial: correct raspberry pi error message 2016-12-13 12:03:49 -06:00
Richard Hughes
6d9d985f1b trivial: Fix a gtk-doc header issue 2016-12-13 16:02:50 +00:00
Richard Hughes
4232185bec trivial: Remove some false-positive messages when using clang 2016-12-13 16:01:52 +00:00
Richard Hughes
ee54d32f4d trivial: Fix a Coverity false positive 2016-12-12 17:02:10 +00:00
Richard Hughes
59a9344c1e Move the UPower functionality to a plugin 2016-12-12 16:28:16 +00:00
Richard Hughes
e8fb74a341 Return the pending UEFI update when not on AC power
The user will not be notified about firmware security updates all the time they
are on battery power. It's better to handle this in the client prompting the
user to connect the AC power source.
2016-12-12 16:17:38 +00:00
Richard Hughes
7b8b202786 Add a set of vfuncs that are run before and after a device update 2016-12-12 16:15:03 +00:00
Richard Hughes
864363e139 Add support for Logitech Unifying devices
If you do not have Unifying hardware you can emulate writing firmware using:

$ fu-unifying-tool write file.hex -v --emulate=bootloader-nordic
2016-12-12 15:36:53 +00:00
Richard Hughes
31bfba3d1b trivial: Fix an error path when getting firmware results 2016-12-12 15:14:12 +00:00
Richard Hughes
cff38bcb3a Convert the providers to plugins to simplify code and for future features
This is a large commit that removes all the providers and turns them into
plugins. I think having both providers _and_ plugins was super confusing.

Plugins are loaded at runtime so you could in theory develop a new plugin
without putting it in the fwupd source tree, although there are no installed
headers or PC files as I'm not sure it's a good idea at this stage.

This commit moves all the per-provider docs, tests, notes, debug dumps and test
data to plugin-specific directories -- these also allows the plugin author to
"own" more of the source tree so we don't enforce fu- prefixes and the style
guide everywhere.

This allows us to run the same action on all the plugins in the future, so we
could have a prepare(FuPlugin, FuDevice) and cleanup(FuPlugin, FuDevice) run
on *all* plugins, so doing an update using one plugin would allow us to work
around hardware quirks in other plugins.

If I've broken your out-of-tree provider it's trivial to port to the new API
with sed and a fixed up build file. If you need help please let me know.
2016-12-12 12:31:23 +00:00
Richard Hughes
b4a24f6035 trivial: Post branch version bump 2016-12-12 12:31:23 +00:00
Richard Hughes
319a6bab12 Move the plugins into plugin-specific directories
This will allow us to add further documentation here in the future.
2016-12-12 11:52:03 +00:00
Richard Hughes
d8e8134bdf trivial: Move the libdfu test files to under libdfu 2016-12-12 11:17:11 +00:00
Richard Hughes
28bbab532a Unexport libebitdo
Nothing is ever going to use this except fwupd, so it makes no sense adding the
extra overhead.
2016-12-09 09:56:31 +00:00
Richard Hughes
70a6822231 trivial: Remove the now-unused Ebitdo parse program 2016-12-08 22:06:37 +00:00
Richard Hughes
20bf83a676 trivial: Remove empty file 2016-12-08 21:19:20 +00:00
Richard Hughes
bc93e4ab6e Make all providers and plugins share a GUsbContext
This means we don't have more that one thread just watching for the USB
hotplug events. To achieve this split up the coldplug into setup and coldplug
phases and run the enumerate just once in the daemon.
2016-12-08 19:51:55 +00:00
Paul Wise
e34654e17f Uncomment SystemdService parameter in the dbus service file. (#74)
Without this the fwupd process will leak into the dbus cgroup.
2016-11-23 08:04:28 +00:00
Richard Hughes
7419e9624a trivial: Use the correct index value when getting the local file descriptor
I assume GLib in F25 is more strict about invalid values.
2016-11-22 19:48:06 +00:00
Philip Withnall
bc339aa657 Fix redeclaration of polkit autocleanup functions
ifdef cannot be used to determine if a C symbol is defined, as it’s
evaluated by the preprocessor, before symbols are parsed. Instead, try
to detect whether polkit.h is suitably recent enough to define its own
auto-cleanup functions.

Signed-off-by: Richard Hughes <richard@hughsie.com>
2016-11-22 16:13:33 +00:00
Richard Hughes
013bb77ee9 Always make sure we're getting a C99 compiler
Spotted by pwithnall, many thanks.
2016-11-22 16:05:51 +00:00
Richard Hughes
1deda31cae Make libelf support optional 2016-11-22 15:39:57 +00:00
Richard Hughes
39148003a7 trivial: Add a Option ROM fuzzer to use with afl 2016-11-22 14:46:57 +00:00
Richard Hughes
467fdba7ce trivial: Never dump past the ROM size for corrupt option ROMs 2016-11-22 14:36:12 +00:00
Richard Hughes
f33d2c0d64 trivial: Use the entry point to detect NVIDIA ROMs 2016-11-22 14:36:12 +00:00
Richard Hughes
0023912e1c trivial: Be more helpful when failing to detect the firmware kind 2016-11-22 14:36:12 +00:00
Richard Hughes
fb049f75b7 trivial: Make the NULL padding detection safer 2016-11-22 14:36:12 +00:00
Richard Hughes
87764f0cc1 trivial: Refactor to create fu_rom_load_data() 2016-11-22 13:41:16 +00:00
Richard Hughes
0e77c525dd trivial: Fix the last commit to actually compile 2016-11-22 08:30:30 +00:00
Tsunghan Liu (Robert Liu)
a02bbb1c4e * close USB devices before error returns (#73) 2016-11-21 09:12:28 -06:00
Richard Hughes
102ddb8fda trivial: Remove some code that cannot be reached
Found using Coverity.
2016-11-09 20:14:15 +00:00
Richard Hughes
f3b1bc6c0c trivial: Check the return code when using g_file_get_contents()
Not actually a bug, but pointed out by Coverity.
2016-11-09 20:14:15 +00:00
Richard Hughes
c8c2d60d65 trivial: Fix error check when parsing Neo Freerunner descriptor
Found using Coverity.
2016-11-09 20:14:15 +00:00
Richard Hughes
dfb30d930a trivial: Fix a typo when matching device VID:PIDs
Found using Coverity.
2016-11-09 19:35:23 +00:00
Richard Hughes
8072bb6fb7 trivial: Fix pointless header check
It can never be NULL. Found using Coverity.
2016-11-09 19:33:47 +00:00
Richard Hughes
710bf295b2 trivial: Fix two missing break statements
Found using Coverity.
2016-11-09 19:32:26 +00:00
Richard Hughes
e686719e38 dell: Fix a possibly-impossible-to-hit buffer overrun
Found using Coverity.
2016-11-09 19:30:37 +00:00
Richard Hughes
dd7713d27d trivial: Fix a tiny resource leak if the signature file cannot be opened
Found using Coverity.
2016-11-09 19:28:38 +00:00
Richard Hughes
4417c062fe dell: Don't return the address of a stack variable
Found using Coverity.
2016-11-09 19:27:08 +00:00
Richard Hughes
fec2480330 trivial: Fix a critical warning on shutdown 2016-11-04 09:30:14 +00:00
Richard Hughes
b28daac301 libdfu: Use a heuristic for the start address if the firmware has no DfuSe footer
This fixes flashing into the 96Boards BLE Carbon.
2016-11-03 15:11:25 +00:00
Richard Hughes
bfef02dc43 trivial: Sync the example spec file with downstream 2016-10-31 08:40:23 +00:00
Mario Limonciello
155f054dff trivial: re-enable dell tpm mode switching for system ID 07a4 2016-10-27 13:09:46 -05:00
Mario Limonciello
11dee100af Clarify the test in --help and man page related to offline (#69) 2016-10-19 15:56:48 -05:00
Richard Hughes
0d7c113ea3 Merge pull request #72 from dell/ac-warning
Show a different error when checking for updates while on battery power
2016-10-19 20:41:02 +01:00
Mario Limonciello
54a5a21757 Show a different error when checking for updates while on battery power (#68) 2016-10-19 14:29:53 -05:00
Richard Hughes
1e8a7bcbd5 trivial: post release version bump 2016-10-19 15:12:06 +01:00