Skip to content

fbdev: Fix a NULL pointer dereference in fb_release()

Javier Martinez Canillas dri-devel linux-fbdev lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 7 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2fbdev: Check in file_fb_info() if the fb_info was already been freeddrivers/video/fbdev/core/fbmem.c+7 -22 replies
2/2fbdev: Make fb_release() return -ENODEV if fbdev was unregistereddrivers/video/fbdev/core/fbmem.c+4 -15 replies

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchThomas Zimmermann
1/2A-b
2/2R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/2] fbdev: Fix a NULL pointer dereference in fb_release()

Hello,

This small series contains fixes for two bugs I found in fbmem.c, that may explain a bug reported in the rpi4 [0] when using simplefb and vc4 drivers.

I was not able to reproduce the mentioned bug, but looking at the code I think that it might explain the issue.

I've tested these patches in a rpi4 with both simplefb and vc4 drivers built-in and did not find any regression.

[0]: https://github.com/raspberrypi/linux/issues/5011

Best regards,
Javier

Javier Martinez Canillas (2):
fbdev: Check in file_fb_info() if the fb_info was already been freed
fbdev: Make fb_release() return -ENODEV if fbdev was unregistered

 drivers/video/fbdev/core/fbmem.c | 14 +++++++++++---
 1 file changed, 11 insertions(+), 3 deletions(-)
Signature · 1 line
2.35.1