{
  "id": "CVE-2026-31566",
  "url": "https://poc.griffinguard.io/cve/CVE-2026-31566",
  "published_at": "2026-04-24T14:35:46.74Z",
  "title": "drm/amdgpu: Fix fence put before wait in amdgpu_amdkfd_submit_ib",
  "vendor": "Linux",
  "product": "Linux",
  "cvss": {
    "score": 7.8,
    "source": "cna",
    "vector": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
  },
  "kev": {
    "in_kev": false,
    "added_at": null,
    "days_after_publication": null
  },
  "first_poc": null,
  "poc_repo_count": 0,
  "exploit_count": 0,
  "suspicious_repo_count": 0,
  "edge_device": null,
  "description": "In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amdgpu: Fix fence put before wait in amdgpu_amdkfd_submit_ib\n\namdgpu_amdkfd_submit_ib() submits a GPU job and gets a fence\nfrom amdgpu_ib_schedule(). This fence is used to wait for job\ncompletion.\n\nCurrently, the code drops the fence reference using dma_fence_put()\nbefore calling dma_fence_wait().\n\nIf dma_fence_put() releases the last reference, the fence may be\nfreed before dma_fence_wait() is called. This can lead to a\nuse-after-free.\n\nFix this by waiting on the fence first and releasing the reference\nonly after dma_fence_wait() completes.\n\nFixes the below:\ndrivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c:697 amdgpu_amdkfd_submit_ib() warn: passing freed memory 'f' (line 696)\n\n(cherry picked from commit 8b9e5259adc385b61a6590a13b82ae0ac2bd3482)",
  "cwe": "CWE-416",
  "cpes": [
    "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:6.0:-:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc1:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc2:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc3:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc4:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc5:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc6:*:*:*:*:*:*",
    "cpe:2.3:o:linux:linux_kernel:7.0:rc7:*:*:*:*:*:*"
  ],
  "cvss_by_source": {
    "cna": 7.8,
    "nvd": 7.8
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c bc7760c107dc08ef3e231d72c492e67b0a86848b",
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c e23602eb0779760544314ed3905fa6a89a4e4070",
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c 138e42be35ff2ce6572ae744de851ea286cf3c69",
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c 39820864eacd886f1a6f817414fb8f9ea3e9a2b4",
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c 42d248726a0837640452b71c5a202ca3d35239ec",
          "\u003e= 9ae55f030dc523fc4dc6069557e4a887ea815453, \u003c 7150850146ebfa4ca998f653f264b8df6f7f85be"
        ],
        "fixed_in": [
          "bc7760c107dc08ef3e231d72c492e67b0a86848b",
          "e23602eb0779760544314ed3905fa6a89a4e4070",
          "138e42be35ff2ce6572ae744de851ea286cf3c69",
          "39820864eacd886f1a6f817414fb8f9ea3e9a2b4",
          "42d248726a0837640452b71c5a202ca3d35239ec",
          "7150850146ebfa4ca998f653f264b8df6f7f85be"
        ]
      },
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "6.0"
        ],
        "fixed_in": [
          "0",
          "6.1.168",
          "6.6.131",
          "6.12.80",
          "6.18.21",
          "6.19.11",
          "7.0"
        ]
      }
    ],
    "upgrade": [
      "Upgrade Linux to bc7760c107dc08ef3e231d72c492e67b0a86848b or e23602eb0779760544314ed3905fa6a89a4e4070 or 138e42be35ff2ce6572ae744de851ea286cf3c69 or 39820864eacd886f1a6f817414fb8f9ea3e9a2b4 or 42d248726a0837640452b71c5a202ca3d35239ec or 7150850146ebfa4ca998f653f264b8df6f7f85be or later.",
      "Upgrade Linux to 0 or 6.1.168 or 6.6.131 or 6.12.80 or 6.18.21 or 6.19.11 or 7.0 or later."
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
