Bug 2324417 (CVE-2024-50156) - CVE-2024-50156 kernel: drm/msm: Avoid NULL dereference in msm_disp_state_print_regs()
Summary: CVE-2024-50156 kernel: drm/msm: Avoid NULL dereference in msm_disp_state_prin...
Keywords:
Status: NEW
Alias: CVE-2024-50156
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On: 2324458
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-11-07 17:01 UTC by OSIDB Bzimport
Modified: 2024-11-18 06:37 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2024-11-07 17:01:47 UTC
In the Linux kernel, the following vulnerability has been resolved:

drm/msm: Avoid NULL dereference in msm_disp_state_print_regs()

If the allocation in msm_disp_state_dump_regs() failed then
`block->state` can be NULL. The msm_disp_state_print_regs() function
_does_ have code to try to handle it with:

  if (*reg)
    dump_addr = *reg;

...but since "dump_addr" is initialized to NULL the above is actually
a noop. The code then goes on to dereference `dump_addr`.

Make the function print "Registers not stored" when it sees a NULL to
solve this. Since we're touching the code, fix
msm_disp_state_print_regs() not to pointlessly take a double-pointer
and properly mark the pointer as `const`.

Patchwork: https://patchwork.freedesktop.org/patch/619657/


Note You need to log in before you can comment on or make changes to this bug.