Lucene search

K
cvelistLinuxCVELIST:CVE-2024-27041
HistoryMay 01, 2024 - 12:54 p.m.

CVE-2024-27041 drm/amd/display: fix NULL checks for adev->dm.dc in amdgpu_dm_fini()

2024-05-0112:54:04
Linux
www.cve.org
4
linux kernel
vulnerability
drm/amd/display
null checks
amdgpu_dm_fini
adev->dm.dc
dc_enable_dmub_notifications
commit 1e88eb1b2c25
config_drm_amd_dc_hdcp
dc_deinit_callbacks
dc_dmub_srv_destroy
linux verification center
static analysis tool
svace

AI Score

6.6

Confidence

Low

EPSS

0

Percentile

15.5%

In the Linux kernel, the following vulnerability has been resolved:

drm/amd/display: fix NULL checks for adev->dm.dc in amdgpu_dm_fini()

Since ‘adev->dm.dc’ in amdgpu_dm_fini() might turn out to be NULL
before the call to dc_enable_dmub_notifications(), check
beforehand to ensure there will not be a possible NULL-ptr-deref
there.

Also, since commit 1e88eb1b2c25 (“drm/amd/display: Drop
CONFIG_DRM_AMD_DC_HDCP”) there are two separate checks for NULL in
‘adev->dm.dc’ before dc_deinit_callbacks() and dc_dmub_srv_destroy().
Clean up by combining them all under one ‘if’.

Found by Linux Verification Center (linuxtesting.org) with static
analysis tool SVACE.

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c"
    ],
    "versions": [
      {
        "version": "81927e2808be",
        "lessThan": "e040f1fbe9ab",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "81927e2808be",
        "lessThan": "ca2eb375db76",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "81927e2808be",
        "lessThan": "1c62697e4086",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "81927e2808be",
        "lessThan": "2a3cfb9a24a2",
        "status": "affected",
        "versionType": "git"
      }
    ]
  },
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "affected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c"
    ],
    "versions": [
      {
        "version": "5.14",
        "status": "affected"
      },
      {
        "version": "0",
        "lessThan": "5.14",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.6.23",
        "lessThanOrEqual": "6.6.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.7.11",
        "lessThanOrEqual": "6.7.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.8.2",
        "lessThanOrEqual": "6.8.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.9",
        "lessThanOrEqual": "*",
        "status": "unaffected",
        "versionType": "original_commit_for_fix"
      }
    ]
  }
]

AI Score

6.6

Confidence

Low

EPSS

0

Percentile

15.5%