mirror of
https://github.com/torvalds/linux.git
synced 2026-06-05 04:56:13 +02:00
i2c: pasemi: Enable the unjam machine
The I2C bus can get stuck under some conditions (desync between controller and device). The pasemi controllers include an unjam feature that is enabled on reset, but was being disabled by the driver. Keep it enabled by explicitly setting the UJM bit in the CTL register. This should help recover the bus from certain conditions, which would otherwise remain stuck forever. Signed-off-by: Hector Martin <marcan@marcan.st> Reviewed-by: Neal Gompa <neal@gompa.dev> Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Signed-off-by: Sven Peter <sven@svenpeter.dev> Link: https://lore.kernel.org/r/20250427-pasemi-fixes-v3-1-af28568296c0@svenpeter.dev Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
This commit is contained in:
parent
25909e19c2
commit
88fe3078b5
|
|
@ -71,7 +71,7 @@ static inline int reg_read(struct pasemi_smbus *smbus, int reg)
|
|||
|
||||
static void pasemi_reset(struct pasemi_smbus *smbus)
|
||||
{
|
||||
u32 val = (CTL_MTR | CTL_MRR | (smbus->clk_div & CTL_CLK_M));
|
||||
u32 val = (CTL_MTR | CTL_MRR | CTL_UJM | (smbus->clk_div & CTL_CLK_M));
|
||||
|
||||
if (smbus->hw_rev >= 6)
|
||||
val |= CTL_EN;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user