Commit Graph

31 Commits

Author SHA1 Message Date
Ilya Guterman
46f5415eda dfu: Support MATEKF722SE quirk
MATEKF722SE has unconvetional behavior for dfu protocol, where the sector size
isn't specified and sector type is shiffted left by 1. This happens only for
one sector.

Sector parsing from MATEKF722SE:

 * `016Kg`
 * `64Kg`
 * `128Kg`
 * `048 e`
 * `528e`
 * `004 e`
2020-05-09 20:19:57 +01:00
Richard Hughes
4fec0302d2 dfu: Remove private headers that do not need to exist
These are a throwback to when we exported the DFU headers.
2019-10-14 15:24:08 -05:00
Richard Hughes
13ffa3e13f dfu: Use the generic fu_plugin_usb_device_added() function 2019-10-10 13:53:27 +01:00
Richard Hughes
5d064d92e0 dfu: Remove XTEA support
We don't support any hardware that actually uses this proposed standard, and
nowadays there is much better public-key encryption people can easily use.
2019-10-09 20:56:38 +01:00
Richard Hughes
dce91204c9 Fix some typos spotted using codespell 2019-04-08 12:47:53 +01:00
Richard Hughes
02c90d8a03 Remove the unused Emacs indenting headers from all source files
Fixes https://github.com/hughsie/fwupd/issues/636
2018-08-09 12:48:04 +01:00
Mario Limonciello
51308e648a Adjust all licensing to LGPL 2.1+ (Closes: #526) 2018-05-29 09:03:13 +01:00
Richard Hughes
524343ac63 trivial: Remove DfuMode
We can get all this information just from looking at the device state.
2017-12-04 17:00:22 +00:00
Richard Hughes
a2fff1f44e dfu: Remove DfuContext
Use the power of FuUsbDevice in DfuDevice to remove a lot of complicated code.
2017-12-04 17:00:22 +00:00
Richard Hughes
92ced1cfbf trivial: Move the detach and attach to the DFU client tool
This isn't used by the daemon and makes the DfuDevice client simpler.
2017-12-04 17:00:22 +00:00
Richard Hughes
1a16cc5e41 trivial: Remove the use of GCancellable in the dfu plugin
We're not using this, and we can simplify the code considerably now that the
library is not installed for external users.
2017-12-04 17:00:22 +00:00
Richard Hughes
49fafec020 Set environment variables to allow easy per-plugin debugging
This allows end-users testing a specific plugin to start fwupd with an extra
command line parameter, e.g. `--plugin-verbose=unifying` to output a lot of
debugging information to the console for that specific plugin.

This replaces a lot of ad-hoc environment variables with different naming
conventions.
2017-11-14 14:22:02 +00:00
Richard Hughes
d44a5ee56d dfu: Add support for XMEGA chips
Notably, bootloaders for this class of device export an incorrect DFU interface.

Additionally, allow setting the buffer size for the UPLOAD to a larger size
than the defined device transfer size, which allows us to return the full
packet from the larger XMEGA devices.
2017-11-07 12:40:25 +00:00
Richard Hughes
3e1e8227be dfu: Add support for one type of AVR32 device
Currently the only supported model is the AT32UC3A3256S, more to come...
2017-10-31 18:30:05 +00:00
Richard Hughes
d49f64f700 dfu: Split out the STM functionality to a new file 2017-10-31 18:30:05 +00:00
Richard Hughes
fc27df7ceb dfu: Add the ability to dump the raw DFU packets 2017-10-31 18:30:05 +00:00
Richard Hughes
9acf8cd16f dfu: Set up the DfuTarget when opening the DfuDevice
In the future we'll use this to set vendor-specific quirks.
2017-10-31 18:30:05 +00:00
Richard Hughes
66513c3b9d dfu: Don't show a debug message when the download timeout is zero 2017-10-26 20:49:10 +01:00
Richard Hughes
55d5fb1ab0 dfu: Remove redundant dfu_device_has_dfuse_support() 2017-10-26 20:49:10 +01:00
Richard Hughes
3dd875f975 dfu: Add some utility functions to dfu-common.h 2017-10-26 20:49:10 +01:00
Richard Hughes
3218de03b9 dfu: Add dfu_target_get_sector_default()
This allows us to get the first sector defined for the target.
2017-10-26 20:49:10 +01:00
Richard Hughes
c995a0218e dfu: Use the correct wDetachTimeOut when writing firmware
Although it makes things faster to ignore the timeout, it violates the DFU
specification which could break some devices.

Lets err on the side of caution for now, even if this means slowing down an
uncommon operation.

This reverts commit 144473c1f4.
2017-10-13 17:20:20 +01:00
Richard Hughes
8232d250a2 dfu: Do not try to verify the element write if upload is unsupported 2017-10-13 09:14:10 +01:00
Richard Hughes
144473c1f4 dfu: Do not use wDetachTimeOut when in DNLOAD_IDLE
This speeds up the DFU plugin to the same speed as using dfu-util.
2017-10-12 12:47:36 +01:00
Richard Hughes
4b9126ee7d dfu: Allow flashing when the target does not specify an alt-name 2017-10-12 12:47:10 +01:00
Richard Hughes
a1c7716cdc dfu: Fix uploading large firmware files
Fixes split into more than 0xff chunks were being truncated as uint8_t was the
wrong index type.
2017-10-12 09:13:27 +01:00
Richard Hughes
b73ff8a346 trivial: Use FwupdStatus in the dfu plugin 2017-09-28 09:23:52 +01:00
Richard Hughes
9e79223ecf trivial: C99ify more for-loops 2017-09-28 09:23:52 +01:00
Richard Hughes
b3c13461e9 trivial: Use the error domain from libfwupd
This means we don't need to convert the error code in the dfu plugin.
2017-09-08 13:33:34 +01:00
Richard Hughes
ef39e2e52f trivial: Remove all the DFU API versioning information 2017-09-08 10:32:22 +01:00
Richard Hughes
68480a2069 trivial: Move the libdfu sources to the dfu plugin 2017-09-07 18:39:23 +01:00