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

drivers: display: fix ili9xxx write size #68378

Merged
merged 3 commits into from
Feb 2, 2024
Merged

drivers: display: fix ili9xxx write size #68378

merged 3 commits into from
Feb 2, 2024

Conversation

danieldegrasse
Copy link
Collaborator

This PR resolves an issue I noticed when performing additional testing of #64587, which does not break the display driver but can result in longer write times for the ILI9xxx display when using display buffer descriptors with a buf_size not equal to the requested write area. The MIPI DBI driver bases the amount of data to write on the buf_size field of the display buffer descriptor, so if this is not equal to the desc->height * desc->width * diplay_bytes_per_pixel more data will be written then strictly necessary.

Clarify write size used by mipi_write_display, so that implementers of
MIPI drivers know to use the buf_size field of the display buffer
descriptor to determine write size.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Fix usage of MIPI buffer descriptor in ili9xxx driver. Previously, the
buffer descriptor size was being set to display buffer size. For cases
where the write height/width  was not equal to the size of the buffer, this
resulted in additional data being written that was not needed. To
resolve this, calculate the mipi descriptor buffer size in the driver

Also, remove the unconditional setting of mipi_desc.height, as this
would override the previous (correct) setting.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Check the return code of mipi_dbi_reset, and do not delay for the reset
wait time unless the mipi controller has issued a hardware reset to the
display.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
@dleach02 dleach02 merged commit b6feb56 into zephyrproject-rtos:main Feb 2, 2024
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants