]> git.karo-electronics.de Git - linux-beck.git/commitdiff
drm: exynos: mixer: fix using usleep() in atomic context
authorTomasz Stanislawski <t.stanislaws@samsung.com>
Fri, 25 Sep 2015 12:48:29 +0000 (14:48 +0200)
committerInki Dae <daeinki@gmail.com>
Mon, 26 Oct 2015 06:10:12 +0000 (15:10 +0900)
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 <t.stanislaws@samsung.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
drivers/gpu/drm/exynos/exynos_mixer.c

index 7f81cce966d4b49e17516cbc76c1974124fa1b65..ecf956c7020a53ea6f05ed83d78e7e87cd2b7a1f 100644 (file)
@@ -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");
 }