diff options
| author | Hugo Villeneuve <[email protected]> | 2024-01-16 21:30:01 +0000 |
|---|---|---|
| committer | Greg Kroah-Hartman <[email protected]> | 2024-01-28 03:09:10 +0000 |
| commit | b35f8dbbce818b02c730dc85133dc7754266e084 (patch) | |
| tree | 9329f4af1293169cc9760f5b2604e3dc803e4f18 /scripts/generate_rust_target.rs | |
| parent | serial: max310x: fail probe if clock crystal is unstable (diff) | |
| download | kernel-b35f8dbbce818b02c730dc85133dc7754266e084.tar.gz kernel-b35f8dbbce818b02c730dc85133dc7754266e084.zip | |
serial: max310x: prevent infinite while() loop in port startup
If there is a problem after resetting a port, the do/while() loop that
checks the default value of DIVLSB register may run forever and spam the
I2C bus.
Add a delay before each read of DIVLSB, and a maximum number of tries to
prevent that situation from happening.
Also fail probe if port reset is unsuccessful.
Fixes: 10d8b34a4217 ("serial: max310x: Driver rework")
Cc: [email protected]
Signed-off-by: Hugo Villeneuve <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'scripts/generate_rust_target.rs')
0 files changed, 0 insertions, 0 deletions
