]> git.baikalelectronics.ru Git - kernel.git/commit
drm/rockchip: rgb: don't count non-existent devices when determining subdrivers
authorHeiko Stuebner <heiko.stuebner@theobroma-systems.com>
Tue, 21 Jan 2020 22:48:28 +0000 (23:48 +0100)
committerHeiko Stuebner <heiko@sntech.de>
Wed, 11 Mar 2020 08:44:14 +0000 (09:44 +0100)
commitffd8ab8022a224cc905be442c41c016adb92d91b
tree00f649e0b27b87e3c22d3cf83e31c864f890b80c
parent2f2d12b36d0cd2d8ac301ee1d28a10b8464c8845
drm/rockchip: rgb: don't count non-existent devices when determining subdrivers

rockchip_drm_endpoint_is_subdriver() may also return error codes.
For example if the target-node is in the disabled state, so no
platform-device is getting created for it.

In that case current code would count that as external rgb device,
which in turn would make probing the rockchip-drm device fail.

So only count the target as rgb device if the function actually
returns 0.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200121224828.4070067-1-heiko@sntech.de
drivers/gpu/drm/rockchip/rockchip_rgb.c