[PATCH] drm: gma500: Replace 120ms mdelay calls in mdfld_dsi_pkg_sender.c
Phillip Potter
phil at philpotter.co.uk
Mon Oct 1 15:36:55 UTC 2018
Replace all 120ms mdelay macro calls with msleep function calls. As msleep is
not suitable for < 20ms sleeps, also remove comment from mdelay(5) call.
Signed-off-by: Phillip Potter <phil at philpotter.co.uk>
---
diff --git a/drivers/gpu/drm/gma500/mdfld_dsi_pkg_sender.c b/drivers/gpu/drm/gma500/mdfld_dsi_pkg_sender.c
index c50534c923df..a9c4116aad8a 100644
--- a/drivers/gpu/drm/gma500/mdfld_dsi_pkg_sender.c
+++ b/drivers/gpu/drm/gma500/mdfld_dsi_pkg_sender.c
@@ -322,13 +322,11 @@ static int send_pkg_prepare(struct mdfld_dsi_pkg_sender *sender, u8 data_type,
/*wait for 120 milliseconds in case exit_sleep_mode just be sent*/
if (unlikely(cmd == MIPI_DCS_ENTER_SLEEP_MODE)) {
- /*TODO: replace it with msleep later*/
- mdelay(120);
+ msleep(120);
}
if (unlikely(cmd == MIPI_DCS_EXIT_SLEEP_MODE)) {
- /*TODO: replace it with msleep later*/
- mdelay(120);
+ msleep(120);
}
return 0;
}
@@ -351,14 +349,11 @@ static int send_pkg_done(struct mdfld_dsi_pkg_sender *sender, u8 data_type,
/*update panel status*/
if (unlikely(cmd == MIPI_DCS_ENTER_SLEEP_MODE)) {
sender->panel_mode |= MDFLD_DSI_PANEL_MODE_SLEEP;
- /*TODO: replace it with msleep later*/
- mdelay(120);
+ msleep(120);
} else if (unlikely(cmd == MIPI_DCS_EXIT_SLEEP_MODE)) {
sender->panel_mode &= ~MDFLD_DSI_PANEL_MODE_SLEEP;
- /*TODO: replace it with msleep later*/
- mdelay(120);
+ msleep(120);
} else if (unlikely(cmd == MIPI_DCS_SOFT_RESET)) {
- /*TODO: replace it with msleep later*/
mdelay(5);
}
More information about the dri-devel
mailing list