[PATCH v2 0/3] bus: mhi: Add loopback driver

Sumit Kumar posted 3 patches 1 month, 2 weeks ago
drivers/bus/mhi/ep/Kconfig           |   8 +
drivers/bus/mhi/ep/Makefile          |   1 +
drivers/bus/mhi/ep/main.c            |  23 ++-
drivers/bus/mhi/ep/mhi_ep_loopback.c | 134 ++++++++++++++
drivers/bus/mhi/host/Kconfig         |   7 +
drivers/bus/mhi/host/Makefile        |   1 +
drivers/bus/mhi/host/mhi_loopback.c  | 347 +++++++++++++++++++++++++++++++++++
include/linux/mhi_ep.h               |  10 +
8 files changed, 525 insertions(+), 6 deletions(-)
[PATCH v2 0/3] bus: mhi: Add loopback driver
Posted by Sumit Kumar 1 month, 2 weeks ago
This series adds MHI loopback drivers to enable comprehensive testing and
validation of MHI data path functionality between host controllers and
endpoint devices. The drivers support configurable transfer sizes, TRE
chaining, and provide real-time status reporting for thorough testing.

Testing is initiated with sysfs entries from the host side and results are
reflected back in the sysfs entry.
The device side driver echoes back the data recieved.

Signed-off-by: Sumit Kumar <sumit.kumar@oss.qualcomm.com>
---
Changes in v2:
- Use __free(kfree) macro for buffers
- Removed NET layer socket buffer dependency, now using buffer and len
- Created a New Api for queuing buffers for clients which do not use skb
- Link to v1: https://lore.kernel.org/r/20250923-loopback_mhi-v1-0-8618f31f44aa@oss.qualcomm.com

---
Sumit Kumar (3):
      bus: mhi: host: Add loopback driver with sysfs interface
      bus: mhi: ep: Create mhi_ep_queue_buf API for raw buffer queuing
      bus: mhi: ep: Add loopback driver for data path testing

 drivers/bus/mhi/ep/Kconfig           |   8 +
 drivers/bus/mhi/ep/Makefile          |   1 +
 drivers/bus/mhi/ep/main.c            |  23 ++-
 drivers/bus/mhi/ep/mhi_ep_loopback.c | 134 ++++++++++++++
 drivers/bus/mhi/host/Kconfig         |   7 +
 drivers/bus/mhi/host/Makefile        |   1 +
 drivers/bus/mhi/host/mhi_loopback.c  | 347 +++++++++++++++++++++++++++++++++++
 include/linux/mhi_ep.h               |  10 +
 8 files changed, 525 insertions(+), 6 deletions(-)
---
base-commit: e6b9dce0aeeb91dfc0974ab87f02454e24566182
change-id: 20250903-loopback_mhi-dee55ff0d462

Best regards,
-- 
Sumit Kumar <sumit.kumar@oss.qualcomm.com>