diff options
author | Chen-Yu Tsai <wens@csie.org> | 2017-09-08 11:00:16 +0200 |
---|---|---|
committer | Maxime Ripard <maxime.ripard@free-electrons.com> | 2017-09-08 22:18:41 +0200 |
commit | d57294c1f8bad1bf5432105814ddb57a1bef6337 (patch) | |
tree | 8fa95e5e8300e2c87f5326e0573a22eadd32e5a1 /drivers/gpu/drm/sun4i | |
parent | MAINTAINERS: sun4i-drm is now maintained in drm-misc (diff) | |
download | linux-d57294c1f8bad1bf5432105814ddb57a1bef6337.tar.xz linux-d57294c1f8bad1bf5432105814ddb57a1bef6337.zip |
drm/sun4i: tcon: Unconditionally reset the TCON
When binding the TCON, we were checking the reset control status and
asserting reset if it wasn't in reset. The check failed to account for
the reset control API returning error codes if the status callback was
not implemented.
Since we want the TCON to be reset in all cases, use reset_control_reset
to force a reset instead.
Fixes: 9026e0d122ac ("drm: Add Allwinner A10 Display Engine support")
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20170908090016.32224-1-wens@csie.org
Diffstat (limited to 'drivers/gpu/drm/sun4i')
-rw-r--r-- | drivers/gpu/drm/sun4i/sun4i_tcon.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c index d9791292553e..36cf1a0acc65 100644 --- a/drivers/gpu/drm/sun4i/sun4i_tcon.c +++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c @@ -530,10 +530,7 @@ static int sun4i_tcon_bind(struct device *dev, struct device *master, } /* Make sure our TCON is reset */ - if (!reset_control_status(tcon->lcd_rst)) - reset_control_assert(tcon->lcd_rst); - - ret = reset_control_deassert(tcon->lcd_rst); + ret = reset_control_reset(tcon->lcd_rst); if (ret) { dev_err(dev, "Couldn't deassert our reset line\n"); return ret; |