]> git.baikalelectronics.ru Git - kernel.git/commit
gpu/drm: Ingenic: Fix opaque pointer casted to wrong type
authorPaul Cercueil <paul@crapouillou.net>
Sat, 16 May 2020 21:50:50 +0000 (23:50 +0200)
committerPaul Cercueil <paul@crapouillou.net>
Sun, 17 May 2020 12:16:15 +0000 (14:16 +0200)
commitc04003a8e8a3cf3ae3db85b0cf124c9a10b0ea84
tree5501a3c52e0b77854f613ae426a407bef8d50a59
parentf4e98cca15f9a5b3f8edfb0c2782205e80d33851
gpu/drm: Ingenic: Fix opaque pointer casted to wrong type

The opaque pointer passed to the IRQ handler is a pointer to the
drm_device, not a pointer to our ingenic_drm structure.

It still worked, because our ingenic_drm structure contains the
drm_device as its first field, so the pointer received had the same
value, but this was not semantically correct.

Cc: stable@vger.kernel.org # v5.3
Fixes: c7eedec560a4 ("DRM: Add KMS driver for the Ingenic JZ47xx SoCs")
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20200516215057.392609-5-paul@crapouillou.net
Acked-by: Sam Ravnborg <sam@ravnborg.org>
drivers/gpu/drm/ingenic/ingenic-drm.c