drm/sun4i: crtc: Propagate layer initialization error
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ dcd215801b0279f0a021516526cf7c0b67d5302e · < 65bc02fec98e4e1d7d59d86cf2ddf8fd73dacb89| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
drm/sun4i: crtc: Propagate layer initialization error
sun4i_crtc_init() returns plain NULL when layer initialization fails, while all its other error paths return an error pointer. The only caller, sun4i_tcon_bind(), checks the result with IS_ERR() and happily continues with tcon->crtc set to NULL. sun4i_rgb_init() and sun4i_lvds_init() then dereference it in drm_crtc_mask(), which oopses.
Return the error pointer instead.
From the CVE record · Linux
The sun4i CRTC initialization path returns NULL when layer initialization fails, but its caller checks only for error pointers and continues. Subsequent RGB or LVDS initialization can dereference NULL and crash the kernel. The input does not establish whether an attacker can trigger this, or specify access or user-interaction requirements.
Engineers running Linux kernels with the drm/sun4i driver should check their versions; affected versions are not specified.