Commit Graph

23 Commits

Author SHA1 Message Date
Richard Hughes
9e79223ecf trivial: C99ify more for-loops 2017-09-28 09:23:52 +01:00
Richard Hughes
c1c2fec6f5 Add optional icons to each device
This allows us to show the devices in a GUI with a nice icon. Some of the icon
mappings are not perfect and I'll be asking the GNOME designers for some
additions to the icon specification.

Custom vendor icons can also be specified, and /usr/share/fwupd/icons would be
a good place to put them. If vendor icons are used they should show a physical
device with the branding, rather than just the vendor logo.
2017-09-11 17:27:35 +01:00
Richard Hughes
9bfcfd88cf Ensure more devices set the device summary
This helps users identify what the device actually does.
2017-09-11 15:10:50 +01:00
Richard Hughes
4edeeda345 ebitdo: Use FuDeviceLocker 2017-09-07 19:00:51 +01:00
Mario Limonciello
c2ed0cb2bc trivial: update remaining use of ALLOW_ONLINE to UPDATABLE 2017-08-31 12:59:26 -05:00
Richard Hughes
a785a1c2f6 Remove the confusing ALLOW_OFFLINE and ALLOW_ONLINE flags
Over the months the original meaning of ALLOW_OFFLINE and ALLOW_ONLINE have be
lost, and there is now a confusing mixture of uses in the source tree. With this
commit we make it clear the UPDATABLE flag is used to specify when the device is
updatable (e.g. from the desktop live session, or from the systemd offline
updates mode, or both) and the NEEDS_REBOOT flag lets us know when the update
is actually going to be done.

For instance, a UEFI UpdateCapsule can be *scheduled* from either the desktop
or from the update mode (but the latter would be a bit weird), but does require
a reboot. Some devices might only be updatable outside the live session, for
instance a hard drive update or a GPU update -- there's just too much going on
with a live session and we want to tightly control what's running during the
firmware flash.

This also means we don't have to "retry" the update when scheduling an update
that really can be scheduled whenever, but just requires a reboot to apply.
2017-08-26 18:09:21 +01:00
Richard Hughes
c788134f75 trivial: Ensure that all the C source files include 'config.h' 2017-08-23 18:26:29 +01:00
Richard Hughes
a8909ec45b trivial: Remove the FuDevice plugin symlinks 2017-08-14 10:29:55 +01:00
Chris Lee
f519834bb9 Make flashing ebitdo devices actually work
When my SNES30 controller was in bootloader mode, it wouldn't update,
and when it was in controller mode, it tried and failed. Now, it prints
out the instructions on how to reset the device if it's in controller
mode, and if it's in bootloader mode, it successfully installs the
firmware update from the .DAT file.
2017-08-02 06:43:09 +01:00
Mario Limonciello
c29b398ad0 trivial: fix various spelling errors 2017-07-17 13:07:05 -05:00
Richard Hughes
fd381cc96e Add the ability to restrict the firmware installation to specific vendor IDs
This allows us to fix https://github.com/hughsie/lvfs-website/issues/4
2017-06-12 20:22:25 +01:00
Richard Hughes
0fe22ff010 ebitdo: Ensure the version is set on the device in non-bootloader mode 2017-06-05 09:03:44 +01:00
Richard Hughes
a9adbf5d22 ebitdo: 8bitdo has started using a new VID 2017-06-05 08:46:50 +01:00
Richard Hughes
741f3310ab ebitdo: Ensure device is closed if fu_device_ebitdo_open() did not complete
It's not expected users have to call fu_device_ebitdo_close() if opening failed.
2017-05-08 12:44:26 +01:00
Richard Hughes
1fdb335025 Remove the automake build system 2017-04-13 18:42:08 +01:00
Richard Hughes
57746cb839 Add the Meson build system as an alternate to autotools
Automake and autoconf are impossible to fully understand and Meson now provides
everything we need for a much smaller, faster, and more understandable build.

See http://mesonbuild.com/ for more information.
2017-04-12 16:35:18 +01:00
Richard Hughes
932eb397d2 trivial: Fix 'make distcheck' 2017-01-10 22:10:50 +00:00
Richard Hughes
23b9c9d78d trivial: Use the per-plugin cache for the runtime device
There is no point having two hash tables doing the same thing...
2017-01-10 16:09:38 +00:00
Richard Hughes
b721d4326f ebitdo: Subclass FuDevice like the altos plugin
This makes things much simpler.
2017-01-10 14:02:16 +00:00
Richard Hughes
c7ea2a2369 trivial: Fix up two compile warnings 2017-01-07 22:10:14 +00:00
Richard Hughes
561c457149 trivial: Use unique profiling IDs in plugins 2016-12-15 12:55:21 +00:00
Richard Hughes
4232185bec trivial: Remove some false-positive messages when using clang 2016-12-13 16:01:52 +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