[PATCH v2] drm/sun4i: Clear encoder->bridge if a bridge is not found
Maxime Ripard
maxime.ripard at free-electrons.com
Thu Sep 1 16:46:19 UTC 2016
On Thu, Sep 01, 2016 at 02:13:32PM +0800, Chen-Yu Tsai wrote:
> The KMS helpers (drm_atomic_helper_check_modeset/mode_fixup) pass
> encoder->bridge directly to drm_bridge_mode_fixup, which expects a
> valid pointer, or NULL (in which case it just returns).
>
> Clear encoder->bridge if a bridge is not found, instead of keeping
> the ERR_PTR value.
>
> Since other drm_bridge functions also follow this pattern of checking
> for a non-NULL pointer, we can drop the ifs around the calls and just
> pass the pointer directly.
>
> Fixes: 894f5a9f4b4a ("drm/sun4i: Add bridge support")
> Signed-off-by: Chen-Yu Tsai <wens at csie.org>
Applied, thanks!
Maxime
--
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20160901/50fb977c/attachment-0001.sig>
More information about the dri-devel
mailing list