In the Linux kernel, the following vulnerability has been resolved:
fbdev: clear fb_info->mode before deleting a videomode
fbsetvar() can delete a mode from info->modelist when userspace passes FBACTIVATEINVMODE through FBIOPUTVSCREENINFO. The code checks that the mode being deleted is not the current info->var and that fbcon is not using it, but it does not check fb_info->mode.
fbinfo->mode may still point into the modelist entry being deleted. If the entry is freed, later mode sysfs reads through showmode() can dereference a stale pointer.
Clear fbinfo->mode before calling fbdelete_videomode() when it matches the mode being removed.