Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arch/arm64/src/imx9/imx9_lpi2c.c: Fix bus reset #317

Merged
merged 1 commit into from
Nov 25, 2024
Merged

Conversation

jlaitine
Copy link

imx9_lpi2c_reset didn't quite work. It tried to toggle scl line as GPIO, but the line was not even muxed properly.

Instead, set the bus to relaxed mode, and drive address 0 to the bus. This toggles the clock, and also generates start and stop sequences on the bus.

"Relaxed mode" is a new feature on the LPI2C block used in imx93.

@jlaitine jlaitine requested review from joukkone and pussuw November 25, 2024 10:39
imx9_lpi2c_reset didn't quite work. It tried to toggle scl line as GPIO, but the line was not even muxed properly.

Instead, set the bus to relaxed mode, and drive address 0 to the bus. This toggles the clock, and also generates start and stop sequences on the bus.

"Relaxed mode" is a new feature on the LPI2C block used in imx93.

Signed-off-by: Jukka Laitinen <[email protected]>
@jlaitine jlaitine merged commit 6c63585 into master Nov 25, 2024
11 checks passed
@jlaitine jlaitine deleted the imx9_fix_i2c_reset branch November 25, 2024 13:15
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.

3 participants