Skip to content

Fix I2C issues for DSI touch and V3 camera #5479

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

Merged
merged 3 commits into from
May 25, 2023

Conversation

6by9
Copy link
Contributor

@6by9 6by9 commented May 23, 2023

No description provided.

@6by9 6by9 force-pushed the rpi-6.1.y-i2c branch from 13879e9 to 1c4d08f Compare May 23, 2023 12:45
@6by9 6by9 changed the title WIP: Fix / log I2C issues for DSI touch and V3 camera Fix I2C issues for DSI touch and V3 camera May 23, 2023
@6by9 6by9 marked this pull request as ready for review May 23, 2023 12:45
@6by9 6by9 marked this pull request as draft May 23, 2023 13:21
@6by9
Copy link
Contributor Author

6by9 commented May 23, 2023

Convert back to a draft based on discussions for always cleanly flushing FIFOs through the normal code paths, and implementing the I2C_M_IGNORE_NAK flag.

On error condition, note the error return code, but still
handle the FIFOs in the normal way rather than relying on
C_CLEAR flushing everything cleanly.

Signed-off-by: Dave Stevenson <[email protected]>
@6by9 6by9 force-pushed the rpi-6.1.y-i2c branch 2 times, most recently from 29a7588 to 22a46eb Compare May 23, 2023 14:21
@6by9 6by9 marked this pull request as ready for review May 23, 2023 14:40
6by9 added 2 commits May 23, 2023 15:51
If a transaction is aborted immediately on ERR being reported,
then the bus is not returned to the STOP condition, and devices
generally get very upset.

Handle the ERR and CLKT conditions only when TA is not set.

Signed-off-by: Dave Stevenson <[email protected]>
Now that transfers aren't aborted immediately (and uncleanly) on
errors, and the FIFOs are always drained after all transfers, we
can implement I2C_M_IGNORE_NAK by ignoring the returned error
value.

Signed-off-by: Dave Stevenson <[email protected]>
@6by9 6by9 force-pushed the rpi-6.1.y-i2c branch from 22a46eb to 8053dca Compare May 23, 2023 14:52
@pelwell pelwell merged commit 8c4f88c into raspberrypi:rpi-6.1.y May 25, 2023
popcornmix added a commit to raspberrypi/rpi-firmware that referenced this pull request May 30, 2023
See: raspberrypi/linux#5482

kernel: Fix I2C issues for DSI touch and V3 camera
See: raspberrypi/linux#5479

kernel: pps: Compatibility hack should be X86-specific
See: raspberrypi/linux#5478
popcornmix added a commit to raspberrypi/firmware that referenced this pull request May 30, 2023
See: raspberrypi/linux#5482

kernel: Fix I2C issues for DSI touch and V3 camera
See: raspberrypi/linux#5479

kernel: pps: Compatibility hack should be X86-specific
See: raspberrypi/linux#5478
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.

2 participants