Skip to content
i2c: Add support for Qualcomm Generic Interface (GENI) I2C controller

Add Support for the Qualcomm Generic Interface (GENI) I2C interface
found on newer Qualcomm SoCs.

The Generic Interface (GENI) is a firmware based Qualcomm Universal
Peripherals (QUP) Serial Engine (SE) Wrapper which can support multiple
bus protocols depending on the firmware type loaded at early boot time
based on system configuration.

It also supports the "I2C Master Hub" which is a single function Wrapper
that only FIFO mode I2C.

It replaces the fixed-function QUP Wrapper found on older SoCs.

The geni-se.h containing the generic GENI Serial Engine registers defines
is imported from Linux.

Only FIFO mode is implemented, neither SE DMA nor GPI DMA are implemented.

Finally enable the driver in the default Qualcomm defconfig.

To: Tom Rini <trini@konsulko.com>
To: Heiko Schocher <hs@denx.de>
To: Caleb Connolly <caleb.connolly@linaro.org>
To: Sumit Garg <sumit.garg@linaro.org>
Cc:  <u-boot@lists.denx.de>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>

---
Changes in v2:
- Fixed commit msg, removed useless debug, switched to dev_err() in probe
- Fixed some possible issues & typos and W=1 build warning
- Link to v1: https://lore.kernel.org/r/20240419-topic-sm8x50-i2c-v1-0-67651e27f23a@linaro.org

---
Neil Armstrong (2):
      i2c: Add support for Qualcomm Generic Interface (GENI) I2C controller
      configs: qcom_defconfig: enable GENI I2C Driver

 configs/qcom_defconfig     |   1 +
 drivers/i2c/Kconfig        |  10 +
 drivers/i2c/Makefile       |   1 +
 drivers/i2c/geni_i2c.c     | 575 +++++++++++++++++++++++++++++++++++++++++++++
 include/soc/qcom/geni-se.h | 265 +++++++++++++++++++++
 5 files changed, 852 insertions(+)
---
base-commit: b2511143fba4c0631446c968fb4c0d962b01d850
change-id: 20240419-topic-sm8x50-i2c-b51e576d5f57

Best regards,