CVE-2026-139562: staging: sm750fb: free cmap on framebuffer release
In the Linux kernel, the following vulnerability has been resolved:
staging: sm750fb: free cmap on framebuffer release
The cmap is allocated by lynxfbsetfbinfo() but never freed, so it is leaked when the framebuffer is torn down. This happens on every unbind, and on the registerframebuffer() error path in sm750fbframebufferalloc().
Add a lynxfbunsetfbinfo() cleanup counterpart to lynxfbsetfbinfo() which deallocates the cmap, and call it on teardown. In the alloc error path it is only called once lynxfbsetfbinfo() has succeeded, so the cmap is only freed when it was actually allocated.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
Add lynxfb_unset_fbinfo() to deallocate the cmap allocated by lynxfb_set_fbinfo(), and call it during framebuffer teardown after lynxfb_set_fbinfo() has succeeded.
Event History
Frequently Asked Questions
When does the memory leak occur?
The leak occurs whenever the sm750fb framebuffer is torn down after an unbind. It also occurs if register_framebuffer() fails in sm750fb_framebuffer_alloc() after lynxfb_set_fbinfo() has allocated the color map.
What is required to trigger the issue?
The affected sm750fb framebuffer must be initialized so that lynxfb_set_fbinfo() allocates its cmap, followed by framebuffer teardown or the specified registration error path. The provided data does not describe a remote or unprivileged attacker trigger.
How can I determine whether a system is affected?
Check whether the running Linux kernel includes one of the referenced stable fixes. Systems using the sm750fb driver that repeatedly unbind the framebuffer or encounter framebuffer registration failures are the relevant exposure cases.