Skip to content

buses: add capability-driven I2C validation - #571

Draft
Srikanth Muppandam (smuppand) wants to merge 2 commits into
qualcomm-linux:mainfrom
smuppand:feature/i2c-capability-validation
Draft

buses: add capability-driven I2C validation#571
Srikanth Muppandam (smuppand) wants to merge 2 commits into
qualcomm-linux:mainfrom
smuppand:feature/i2c-capability-validation

Conversation

@smuppand

Copy link
Copy Markdown
Contributor

Summary

Enhance the Buses suite with capability-driven I2C validation across Qualcomm Linux platforms without relying on static board, SoC, adapter, or driver mappings.

Depends on the platform runtime foundation PR.

Changes

  • Correlate enabled Qualcomm I2C controllers with runtime adapters and clients.
  • Discover expected driver support through modalias resolution and registered bus drivers.
  • Treat built-in and loadable kernel drivers consistently.
  • Validate actual driver binding through sysfs driver links.
  • Report waiting_for_supplier, DT status, runtime resources, child nodes, and mux channels for unbound clients.
  • Retain structured controller, adapter, client, and registered-driver artifacts.
  • Print concise per-object failure diagnostics to stdout for LAVA and serial-console debugging.
  • Preserve optional i2cdetect and i2c-msm-test checks with clean SKIP handling when unavailable.
  • Disable runtime package recovery because image-validation suites must use image-provided components.

Result classification

  • No runtime I2C capability: SKIP
  • Healthy controllers, adapters, and declared clients: PASS
  • DT-declared client present but unbound or malformed: FAIL
  • Optional diagnostic utility absent: corresponding check is SKIP

Add shared runtime inventory and validation primitives for I2C, PCIe, USB, device-tree health, firmware discovery, and QRTR topology. Keep capability detection dynamic across platforms and expose bounded diagnostics for consumer suites.

Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
Correlate enabled I2C controllers, runtime adapters, DT clients, alias-resolved driver support, and actual bindings without board-specific mappings. Preserve the optional legacy path and print per-object diagnostics for malformed or unbound clients.

Add distro-aware i2c-tools recovery for supported host distributions, read-only adapter capability checks, and explicitly requested address scan, register read, and transactional write-and-restore operations with bounded execution and validation.

Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
@smuppand
Srikanth Muppandam (smuppand) force-pushed the feature/i2c-capability-validation branch from fdb6267 to 5956956 Compare September 6, 2026 05:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant