fwupd/plugins/ccgx
2020-06-09 10:37:26 +01:00
..
ccgx-ids.quirk ccgx: Get the silicon ID to map the flash parameters 2020-03-24 21:16:08 +00:00
ccgx.quirk ccgx: modify install duration for dmc device 2020-06-09 10:37:26 +01:00
fu-ccgx-common.c ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-common.h ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-common.c ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-common.h ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-device.c ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-device.h ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-firmware.c ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-dmc-firmware.h ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
fu-ccgx-firmware.c ccgx: Fix a potential division by zero 2020-05-22 15:34:16 +01:00
fu-ccgx-firmware.h ccgx: Implement writing firmware to flash 2020-03-27 13:25:40 +00:00
fu-ccgx-hid-device.c ccgx: Retry the HID disconnect up to 5 times 2020-04-07 19:50:43 +01:00
fu-ccgx-hid-device.h ccgx: Create devices when in HID and I2C modes 2020-03-23 20:02:17 +00:00
fu-ccgx-hpi-common.c ccgx: Show a better error message on failure 2020-04-07 12:50:28 -05:00
fu-ccgx-hpi-common.h ccgx: Show a better error message on failure 2020-04-07 12:50:28 -05:00
fu-ccgx-hpi-device.c Fix various build issues with -Wdiscarded-qualifiers 2020-05-07 16:15:30 +01:00
fu-ccgx-hpi-device.h ccgx: Create devices when in HID and I2C modes 2020-03-23 20:02:17 +00:00
fu-plugin-ccgx.c ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
meson.build ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00
README.md ccgx: Add support for HP DMC dock devices 2020-06-05 13:35:54 +01:00

Cypress support

Introduction

This plugin can flash firmware on Cypress CCGx USB-C controller family of devices used in dock solutions.

Supported devices:

  • Lenovo Gen2 Dock
  • Lenovo Hybrid Dock
  • HP USB-C Dock G5
  • HP USB-C/A Universal Dock G2

Device Flash

There are four kinds of flash layout. Single image firmware is not currently supported in this plugin.

Symmetric Firmware

In symmetric firmware topology, FW1 and FW2 are both primary (main) firmware with identical sizes and functionality. We can only update FW1 from FW2 or FW2 from FW1. This does mean we need to update just one time as booting from either firmware slot gives a fully functional device.

After updating the "other" firmware we can just use CY_PD_DEVICE_RESET_CMD_SIG to reboot into the new firmware, and no further action is required.

Asymmetric Firmware

In asymmetric firmware topology, FW1 is backup and FW2 is primary (main) firmware with different firmware sizes. The backup firmware may not support all dock functionality.

To update primary, we thus need to update twice:

Case 1: FW2 is running

  • Update FW1 -> Jump to backup FW CY_PD_JUMP_TO_ALT_FW_CMD_SIG -> reboot
  • Update FW2 -> Reset device CY_PD_DEVICE_RESET_CMD_SIG -> reboot -> FW2

Case 2: FW1 is running (recovery case)

  • Update FW2 -> Reset device CY_PD_DEVICE_RESET_CMD_SIG -> reboot -> FW2

The CY_PD_JUMP_TO_ALT_FW_CMD_SIG command is allowed only in asymmetric FW, but CY_PD_DEVICE_RESET_CMD_SIG is allowed in both asymmetric FW and symmetric FW.

DMC(Dock Management Controller) Composite Firmware

In composite firmware topology, a single firmware image contains metadata and firmware images of multiple devices including DMC itself in a dock system.

Firmware Format

There are two kinds of firmware format.

Cyacd firmware format

The daemon will decompress the cabinet archive and extract several firmware blobs in cyacd file format. See https://community.cypress.com/docs/DOC-10562 for more details.

DMC composite firmware format

The daemon will decompress the cabinet archive and extract several firmware blobs in a combined image file format. See 4.4.1 Single Composite (Combined) Dock Image at https://www.cypress.com/file/387471/download for more details.

This plugin supports the following protocol ID:

  • com.cypress.ccgx

GUID Generation

These devices use the standard USB DeviceInstanceId values, e.g.

  • USB\VID_17EF&PID_A38F
  • USB\VID_03F0&PID_046B

For cyacd firmware device, They additionally add other instance IDs which corresponds to the silicon ID, application ID and device mode, e.g.

  • USB\VID_17EF&PID_A38F&SID_1234
  • USB\VID_17EF&PID_A38F&SID_1234&APP_5678
  • USB\VID_17EF&PID_A38F&SID_1234&APP_5678&MODE_FW2

Vendor ID Security

The vendor ID is set from the USB vendor, for example set to USB:0x17EF