Hi,
This patchset brings support for Silicon Labs' CPC protocol as transport layer for Greybus. As an example, a SPI driver is added as physical layer and everything is bundled as a big kernel module. In the future, as we plan to support other physical layers like SDIO, CPC core will be its own module, and each physical layer CPC driver will be its own module as well.
CPC implements some of the features of Unipro that Greybus relies upon, like reliable transmission. CPC takes care of detecting transmission errors and retransmit frames if necessary. There's also a flow-control feature, preventing sending messages to full cports.
In addition to the host device over SPI part, there's also a class driver for a vendor protocol that enables Bluetooth on supported devices. This is mostly there to open the discussion on how a new protocol should be added to Greybus.
Damien Riégel (6): greybus: move host controller drivers comment in Makefile greybus: cpc: add core logic greybus: cpc: add SPI driver greybus: add API for async unidirectional transfer greybus: match device with bundle ID greybus: add class driver for Silabs Bluetooth
MAINTAINERS | 12 + drivers/greybus/Kconfig | 2 + drivers/greybus/Makefile | 4 +- drivers/greybus/core.c | 4 + drivers/greybus/cpc/Kconfig | 12 + drivers/greybus/cpc/Makefile | 6 + drivers/greybus/cpc/cpc.h | 135 +++++++ drivers/greybus/cpc/endpoint.c | 158 ++++++++ drivers/greybus/cpc/header.c | 212 ++++++++++ drivers/greybus/cpc/header.h | 81 ++++ drivers/greybus/cpc/host.c | 113 ++++++ drivers/greybus/cpc/protocol.c | 274 +++++++++++++ drivers/greybus/cpc/spi.c | 585 +++++++++++++++++++++++++++ drivers/greybus/operation.c | 52 +++ drivers/staging/greybus/Kconfig | 9 + drivers/staging/greybus/Makefile | 6 + drivers/staging/greybus/silabs-ble.c | 203 ++++++++++ include/linux/greybus.h | 7 +- include/linux/greybus/greybus_id.h | 2 + include/linux/greybus/operation.h | 4 + 20 files changed, 1877 insertions(+), 4 deletions(-) create mode 100644 drivers/greybus/cpc/Kconfig create mode 100644 drivers/greybus/cpc/Makefile create mode 100644 drivers/greybus/cpc/cpc.h create mode 100644 drivers/greybus/cpc/endpoint.c create mode 100644 drivers/greybus/cpc/header.c create mode 100644 drivers/greybus/cpc/header.h create mode 100644 drivers/greybus/cpc/host.c create mode 100644 drivers/greybus/cpc/protocol.c create mode 100644 drivers/greybus/cpc/spi.c create mode 100644 drivers/staging/greybus/silabs-ble.c