]> git.baikalelectronics.ru Git - kernel.git/commit
drm/sun4i: tcon-top: Fix return type warning
authorMaxime Ripard <maxime.ripard@bootlin.com>
Thu, 12 Jul 2018 08:08:18 +0000 (10:08 +0200)
committerMaxime Ripard <maxime.ripard@bootlin.com>
Thu, 12 Jul 2018 16:48:54 +0000 (18:48 +0200)
commit8e28e60e84abf643df82b6fddc0ccffe5e94101a
treecd7a7bddde069290dbb794dd8a60bd17f84458ad
parent7d675ebe9c7792e04b477f9e7b6846f456717998
drm/sun4i: tcon-top: Fix return type warning

When commit 4b95dba012da ("drm/sun4i: tcon-top: Cleanup clock handling")
was merged, the error handling path of the of_property_match_string was
changed to take into account the fact that the returned value of that
function wasn't an error pointer but an error code.

Unfortunately, this introduced a warning since the now returned value is an
integer, while the sun8i_tcon_top_register_gate function should return an
error pointer.

Fix that by calling ERR_PTR.

Cc: Jernej Skrabec <jernej.skrabec@siol.net>
Cc: Chen-Yu Tsai <wens@csie.org>
Fixes: 4b95dba012da ("drm/sun4i: tcon-top: Cleanup clock handling")
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reported-by: kbuild test robot <lkp@intel.com>
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180712080818.3571-1-maxime.ripard@bootlin.com
drivers/gpu/drm/sun4i/sun8i_tcon_top.c