public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/6] i2c: spacemit: fix and introduce pio
@ 2025-09-25  2:02 Troy Mitchell
  2025-09-25  2:02 ` [PATCH v2 1/6] i2c: spacemit: ensure bus release check runs when wait_bus_idle() fails Troy Mitchell
                   ` (6 more replies)
  0 siblings, 7 replies; 28+ messages in thread
From: Troy Mitchell @ 2025-09-25  2:02 UTC (permalink / raw)
  To: Andi Shyti, Yixun Lan, Alex Elder, Troy Mitchell
  Cc: linux-i2c, linux-kernel, linux-riscv, spacemit, Troy Mitchell,
	Aurelien Jarno

Previously, there were a few latent issues in the I2C driver.

These did not manifest under interrupt mode, but they were
still present and could be triggered when running in PIO mode.

This series addresses those issues and adds support for PIO
mode transfers.

Signed-off-by: Troy Mitchell <troy.mitchell@linux.spacemit.com>
---
Changes in v2:
- Patch 1/6:
  Patch 3/6:
  Patch 4/6:
    - nothing
- Patch 2/6:
  - remove is_pio judgement in irq_handler()
- Patch 5/6:
  - fix wrong comment
  - In spacemit_i2c_conditionally_reset_bus(), once the condition is met inside the loop, it should 
    return directly instead of using break.
- Patch 6/6:
  - add is_pio judgement in irq_handler()
  - use a fixed timeout value when PIO
  - use readl_poll_timeout() in  spacemit_i2c_wait_bus_idle() when PIO

- Link to v1: https://lore.kernel.org/r/20250827-k1-i2c-atomic-v1-0-e59bea02d680@linux.spacemit.com

---
Troy Mitchell (6):
      i2c: spacemit: ensure bus release check runs when wait_bus_idle() fails
      i2c: spacemit: remove stop function to avoid bus error
      i2c: spacemit: disable SDA glitch fix to avoid restart delay
      i2c: spacemit: check SDA instead of SCL after bus reset
      i2c: spacemit: ensure SDA is released after bus reset
      i2c: spacemit: introduce pio for k1

 drivers/i2c/busses/i2c-k1.c | 221 +++++++++++++++++++++++++++++++++++---------
 1 file changed, 178 insertions(+), 43 deletions(-)
---
base-commit: f9a7e1f3eff519e88c91d87701d05cfd968d89de
change-id: 20250814-k1-i2c-atomic-f1a90cd34364

Best regards,
-- 
Troy Mitchell <troy.mitchell@linux.spacemit.com>


^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2025-09-28 11:22 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-25  2:02 [PATCH v2 0/6] i2c: spacemit: fix and introduce pio Troy Mitchell
2025-09-25  2:02 ` [PATCH v2 1/6] i2c: spacemit: ensure bus release check runs when wait_bus_idle() fails Troy Mitchell
2025-09-25  2:02 ` [PATCH v2 2/6] i2c: spacemit: remove stop function to avoid bus error Troy Mitchell
2025-09-25 20:11   ` Aurelien Jarno
2025-09-25  2:02 ` [PATCH v2 3/6] i2c: spacemit: disable SDA glitch fix to avoid restart delay Troy Mitchell
2025-09-25  2:02 ` [PATCH v2 4/6] i2c: spacemit: check SDA instead of SCL after bus reset Troy Mitchell
2025-09-25  2:02 ` [PATCH v2 5/6] i2c: spacemit: ensure SDA is released " Troy Mitchell
2025-09-25 20:43   ` Aurelien Jarno
2025-09-25  2:02 ` [PATCH v2 6/6] i2c: spacemit: introduce pio for k1 Troy Mitchell
2025-09-26 11:10   ` Yixun Lan
2025-09-26 13:13     ` Troy Mitchell
2025-09-26 14:28       ` Wolfram Sang
2025-09-27  1:24         ` Yixun Lan
2025-09-27  3:57           ` Troy Mitchell
2025-09-28  6:06     ` Troy Mitchell
2025-09-26 16:47   ` Aurelien Jarno
2025-09-27  4:05     ` Troy Mitchell
2025-09-27  1:45   ` Yixun Lan
2025-09-27  4:04     ` Troy Mitchell
2025-09-27 10:16       ` Yixun Lan
2025-09-27 10:24         ` Troy Mitchell
2025-09-27 10:56   ` Yixun Lan
2025-09-28  1:17     ` Troy Mitchell
2025-09-28  2:54       ` Yixun Lan
2025-09-28  8:09         ` Troy Mitchell
2025-09-28 11:22           ` Yixun Lan
2025-09-25 21:50 ` [PATCH v2 0/6] i2c: spacemit: fix and introduce pio Wolfram Sang
2025-09-26  1:47   ` Troy Mitchell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox