From: Tomasz Stanislawski Date: Fri, 25 Sep 2015 12:48:29 +0000 (+0200) Subject: drm: exynos: mixer: fix using usleep() in atomic context X-Git-Tag: v4.4-rc1~44^2~12^2~19 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=02b3de431111014643c48a326b46d127df061658;p=platform%2Fkernel%2Flinux-exynos.git drm: exynos: mixer: fix using usleep() in atomic context This patch fixes calling usleep_range() after taking reg_slock using spin_lock_irqsave(). The mdelay() is used instead. Waiting in atomic context is not the best idea in general. Hopefully, waiting occurs only when Video Processor fails to reset correctly. Signed-off-by: Tomasz Stanislawski Signed-off-by: Inki Dae --- diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c index 7f81cce..ecf956c 100644 --- a/drivers/gpu/drm/exynos/exynos_mixer.c +++ b/drivers/gpu/drm/exynos/exynos_mixer.c @@ -652,7 +652,7 @@ static void vp_win_reset(struct mixer_context *ctx) /* waiting until VP_SRESET_PROCESSING is 0 */ if (~vp_reg_read(res, VP_SRESET) & VP_SRESET_PROCESSING) break; - usleep_range(10000, 12000); + mdelay(10); } WARN(tries == 0, "failed to reset Video Processor\n"); }