]> git.baikalelectronics.ru Git - kernel.git/commit
drm: rcar-du: Fix NULL encoder pointer dereference
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Thu, 27 Nov 2014 12:49:07 +0000 (14:49 +0200)
committerDave Airlie <airlied@redhat.com>
Tue, 2 Dec 2014 22:28:48 +0000 (08:28 +1000)
commit64c78b42efcc4c68661f531751ce9be1c7afb07f
tree9b956e39a31847376ac0c490378c71901c117d4a
parent9c7f6e5f49f69de8b4302b650080d05e56f43900
drm: rcar-du: Fix NULL encoder pointer dereference

The DRM connector's encoder pointer is managed internally by the DRM
core and set to NULL when the DRM connector is disconnected from the
CRTC it was attached to. This results in a NULL pointer dereference in
the HDMI connector functions when trying to call the associated slave
encoder's operations.

Fix this by retrieving the slave encoder pointer from the R-Car
connector structure instead of the DRM connector structure.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/rcar-du/rcar_du_hdmicon.c