mirror of
https://github.com/torvalds/linux.git
synced 2026-11-27 17:02:17 +00:00
Pointer dev_priv->mmio, which was checked for NULL at via_do_init_map(),
is passed to via_do_cleanup_map() and is dereferenced there without check.
The patch adds the condition in via_dma_cleanup() which prevents potential NULL
pointer dereference.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Fixes: 22f579c621 ("drm: Add via unichrome support")
Signed-off-by: Alisa Khabibrakhmanova <[email protected]>
Signed-off-by: Daniel Vetter <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]