GCVE Workshop - 22 September 2026 (14:00-18:00), Luxembourg Before The Vulnopticon Conference - Registration

CVE-2025-40310 (GCVE-0-2025-40310)

Vulnerability from cvelistv5 – Published: 2025-12-08 00:46 – Updated: 2026-05-11 21:46
VLAI
Title
amd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw
Summary
In the Linux kernel, the following vulnerability has been resolved: amd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw There is race in amdgpu_amdkfd_device_fini_sw and interrupt. if amdgpu_amdkfd_device_fini_sw run in b/w kfd_cleanup_nodes and kfree(kfd), and KGD interrupt generated. kernel panic log: BUG: kernel NULL pointer dereference, address: 0000000000000098 amdgpu 0000:c8:00.0: amdgpu: Requesting 4 partitions through PSP PGD d78c68067 P4D d78c68067 kfd kfd: amdgpu: Allocated 3969056 bytes on gart PUD 1465b8067 PMD @ Oops: @002 [#1] SMP NOPTI kfd kfd: amdgpu: Total number of KFD nodes to be created: 4 CPU: 115 PID: @ Comm: swapper/115 Kdump: loaded Tainted: G S W OE K RIP: 0010:_raw_spin_lock_irqsave+0x12/0x40 Code: 89 e@ 41 5c c3 cc cc cc cc 66 66 2e Of 1f 84 00 00 00 00 00 OF 1f 40 00 Of 1f 44% 00 00 41 54 9c 41 5c fa 31 cO ba 01 00 00 00 <fO> OF b1 17 75 Ba 4c 89 e@ 41 Sc 89 c6 e8 07 38 5d RSP: 0018: ffffc90@1a6b0e28 EFLAGS: 00010046 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000018 0000000000000001 RSI: ffff8883bb623e00 RDI: 0000000000000098 ffff8883bb000000 RO8: ffff888100055020 ROO: ffff888100055020 0000000000000000 R11: 0000000000000000 R12: 0900000000000002 ffff888F2b97da0@ R14: @000000000000098 R15: ffff8883babdfo00 CS: 010 DS: 0000 ES: 0000 CRO: 0000000080050033 CR2: 0000000000000098 CR3: 0000000e7cae2006 CR4: 0000000002770ce0 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 0000000000000000 DR6: 00000000fffeO7FO DR7: 0000000000000400 PKRU: 55555554 Call Trace: <IRQ> kgd2kfd_interrupt+@x6b/0x1f@ [amdgpu] ? amdgpu_fence_process+0xa4/0x150 [amdgpu] kfd kfd: amdgpu: Node: 0, interrupt_bitmap: 3 YcpxFl Rant tErace amdgpu_irq_dispatch+0x165/0x210 [amdgpu] amdgpu_ih_process+0x80/0x100 [amdgpu] amdgpu: Virtual CRAT table created for GPU amdgpu_irq_handler+0x1f/@x60 [amdgpu] __handle_irq_event_percpu+0x3d/0x170 amdgpu: Topology: Add dGPU node [0x74a2:0x1002] handle_irq_event+0x5a/@xcO handle_edge_irq+0x93/0x240 kfd kfd: amdgpu: KFD node 1 partition @ size 49148M asm_call_irq_on_stack+0xf/@x20 </IRQ> common_interrupt+0xb3/0x130 asm_common_interrupt+0x1le/0x40 5.10.134-010.a1i5000.a18.x86_64 #1
Severity
No CVSS data available.
Impacted products
Vendor Product Version CPE status
Linux Linux Affected: 74c5b85da75475c73a8f040397610fbfcc2c3e78 , < 93f8d67ef8b50334a26129df4da5a4cb60ad4090 (git)
Affected: 74c5b85da75475c73a8f040397610fbfcc2c3e78 , < bc9e789053abe463f8cf74eee5fc2f157c11a79f (git)
Affected: 74c5b85da75475c73a8f040397610fbfcc2c3e78 , < 2f89a2d15550b653caaeeab7ab68c4d7583fd4fe (git)
Affected: 74c5b85da75475c73a8f040397610fbfcc2c3e78 , < 99d7181bca34e96fbf61bdb6844918bdd4df2814 (git)
guessed Create a notification for this product.
Linux Linux Affected: 6.5
Unaffected: 0 , < 6.5 (semver)
Unaffected: 6.6.117 , ≤ 6.6.* (semver)
Unaffected: 6.12.58 , ≤ 6.12.* (semver)
Unaffected: 6.17.8 , ≤ 6.17.* (semver)
Unaffected: 6.18 , ≤ * (original_commit_for_fix)
guessed Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/gpu/drm/amd/amdkfd/kfd_device.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "93f8d67ef8b50334a26129df4da5a4cb60ad4090",
              "status": "affected",
              "version": "74c5b85da75475c73a8f040397610fbfcc2c3e78",
              "versionType": "git"
            },
            {
              "lessThan": "bc9e789053abe463f8cf74eee5fc2f157c11a79f",
              "status": "affected",
              "version": "74c5b85da75475c73a8f040397610fbfcc2c3e78",
              "versionType": "git"
            },
            {
              "lessThan": "2f89a2d15550b653caaeeab7ab68c4d7583fd4fe",
              "status": "affected",
              "version": "74c5b85da75475c73a8f040397610fbfcc2c3e78",
              "versionType": "git"
            },
            {
              "lessThan": "99d7181bca34e96fbf61bdb6844918bdd4df2814",
              "status": "affected",
              "version": "74c5b85da75475c73a8f040397610fbfcc2c3e78",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/gpu/drm/amd/amdkfd/kfd_device.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.5"
            },
            {
              "lessThan": "6.5",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.117",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.58",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.17.*",
              "status": "unaffected",
              "version": "6.17.8",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.18",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.117",
                  "versionStartIncluding": "6.5",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.58",
                  "versionStartIncluding": "6.5",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.17.8",
                  "versionStartIncluding": "6.5",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.18",
                  "versionStartIncluding": "6.5",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\namd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw\n\nThere is race in amdgpu_amdkfd_device_fini_sw and interrupt.\nif amdgpu_amdkfd_device_fini_sw run in b/w kfd_cleanup_nodes and\n  kfree(kfd), and KGD interrupt generated.\n\nkernel panic log:\n\nBUG: kernel NULL pointer dereference, address: 0000000000000098\namdgpu 0000:c8:00.0: amdgpu: Requesting 4 partitions through PSP\n\nPGD d78c68067 P4D d78c68067\n\nkfd kfd: amdgpu: Allocated 3969056 bytes on gart\n\nPUD 1465b8067 PMD @\n\nOops: @002 [#1] SMP NOPTI\n\nkfd kfd: amdgpu: Total number of KFD nodes to be created: 4\nCPU: 115 PID: @ Comm: swapper/115 Kdump: loaded Tainted: G S W OE K\n\nRIP: 0010:_raw_spin_lock_irqsave+0x12/0x40\n\nCode: 89 e@ 41 5c c3 cc cc cc cc 66 66 2e Of 1f 84 00 00 00 00 00 OF 1f 40 00 Of 1f 44% 00 00 41 54 9c 41 5c fa 31 cO ba 01 00 00 00 \u003cfO\u003e OF b1 17 75 Ba 4c 89 e@ 41 Sc\n\n89 c6 e8 07 38 5d\n\nRSP: 0018: ffffc90@1a6b0e28 EFLAGS: 00010046\n\nRAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000018\n0000000000000001 RSI: ffff8883bb623e00 RDI: 0000000000000098\nffff8883bb000000 RO8: ffff888100055020 ROO: ffff888100055020\n0000000000000000 R11: 0000000000000000 R12: 0900000000000002\nffff888F2b97da0@ R14: @000000000000098 R15: ffff8883babdfo00\n\nCS: 010 DS: 0000 ES: 0000 CRO: 0000000080050033\n\nCR2: 0000000000000098 CR3: 0000000e7cae2006 CR4: 0000000002770ce0\n0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000\n0000000000000000 DR6: 00000000fffeO7FO DR7: 0000000000000400\n\nPKRU: 55555554\n\nCall Trace:\n\n\u003cIRQ\u003e\n\nkgd2kfd_interrupt+@x6b/0x1f@ [amdgpu]\n\n? amdgpu_fence_process+0xa4/0x150 [amdgpu]\n\nkfd kfd: amdgpu: Node: 0, interrupt_bitmap: 3 YcpxFl Rant tErace\n\namdgpu_irq_dispatch+0x165/0x210 [amdgpu]\n\namdgpu_ih_process+0x80/0x100 [amdgpu]\n\namdgpu: Virtual CRAT table created for GPU\n\namdgpu_irq_handler+0x1f/@x60 [amdgpu]\n\n__handle_irq_event_percpu+0x3d/0x170\n\namdgpu: Topology: Add dGPU node [0x74a2:0x1002]\n\nhandle_irq_event+0x5a/@xcO\n\nhandle_edge_irq+0x93/0x240\n\nkfd kfd: amdgpu: KFD node 1 partition @ size 49148M\n\nasm_call_irq_on_stack+0xf/@x20\n\n\u003c/IRQ\u003e\n\ncommon_interrupt+0xb3/0x130\n\nasm_common_interrupt+0x1le/0x40\n\n5.10.134-010.a1i5000.a18.x86_64 #1"
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-05-11T21:46:52.918Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/93f8d67ef8b50334a26129df4da5a4cb60ad4090"
        },
        {
          "url": "https://git.kernel.org/stable/c/bc9e789053abe463f8cf74eee5fc2f157c11a79f"
        },
        {
          "url": "https://git.kernel.org/stable/c/2f89a2d15550b653caaeeab7ab68c4d7583fd4fe"
        },
        {
          "url": "https://git.kernel.org/stable/c/99d7181bca34e96fbf61bdb6844918bdd4df2814"
        }
      ],
      "title": "amd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2025-40310",
    "datePublished": "2025-12-08T00:46:35.862Z",
    "dateReserved": "2025-04-16T07:20:57.185Z",
    "dateUpdated": "2026-05-11T21:46:52.918Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2025-40310",
      "date": "2026-09-16",
      "epss": "0.00186",
      "percentile": "0.08414"
    },
    "nvd": "{\"cve\":{\"id\":\"CVE-2025-40310\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-12-08T01:16:03.347\",\"lastModified\":\"2026-06-17T09:21:38.253\",\"vulnStatus\":\"Deferred\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\namd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw\\n\\nThere is race in amdgpu_amdkfd_device_fini_sw and interrupt.\\nif amdgpu_amdkfd_device_fini_sw run in b/w kfd_cleanup_nodes and\\n  kfree(kfd), and KGD interrupt generated.\\n\\nkernel panic log:\\n\\nBUG: kernel NULL pointer dereference, address: 0000000000000098\\namdgpu 0000:c8:00.0: amdgpu: Requesting 4 partitions through PSP\\n\\nPGD d78c68067 P4D d78c68067\\n\\nkfd kfd: amdgpu: Allocated 3969056 bytes on gart\\n\\nPUD 1465b8067 PMD @\\n\\nOops: @002 [#1] SMP NOPTI\\n\\nkfd kfd: amdgpu: Total number of KFD nodes to be created: 4\\nCPU: 115 PID: @ Comm: swapper/115 Kdump: loaded Tainted: G S W OE K\\n\\nRIP: 0010:_raw_spin_lock_irqsave+0x12/0x40\\n\\nCode: 89 e@ 41 5c c3 cc cc cc cc 66 66 2e Of 1f 84 00 00 00 00 00 OF 1f 40 00 Of 1f 44% 00 00 41 54 9c 41 5c fa 31 cO ba 01 00 00 00 \u003cfO\u003e OF b1 17 75 Ba 4c 89 e@ 41 Sc\\n\\n89 c6 e8 07 38 5d\\n\\nRSP: 0018: ffffc90@1a6b0e28 EFLAGS: 00010046\\n\\nRAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000018\\n0000000000000001 RSI: ffff8883bb623e00 RDI: 0000000000000098\\nffff8883bb000000 RO8: ffff888100055020 ROO: ffff888100055020\\n0000000000000000 R11: 0000000000000000 R12: 0900000000000002\\nffff888F2b97da0@ R14: @000000000000098 R15: ffff8883babdfo00\\n\\nCS: 010 DS: 0000 ES: 0000 CRO: 0000000080050033\\n\\nCR2: 0000000000000098 CR3: 0000000e7cae2006 CR4: 0000000002770ce0\\n0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000\\n0000000000000000 DR6: 00000000fffeO7FO DR7: 0000000000000400\\n\\nPKRU: 55555554\\n\\nCall Trace:\\n\\n\u003cIRQ\u003e\\n\\nkgd2kfd_interrupt+@x6b/0x1f@ [amdgpu]\\n\\n? amdgpu_fence_process+0xa4/0x150 [amdgpu]\\n\\nkfd kfd: amdgpu: Node: 0, interrupt_bitmap: 3 YcpxFl Rant tErace\\n\\namdgpu_irq_dispatch+0x165/0x210 [amdgpu]\\n\\namdgpu_ih_process+0x80/0x100 [amdgpu]\\n\\namdgpu: Virtual CRAT table created for GPU\\n\\namdgpu_irq_handler+0x1f/@x60 [amdgpu]\\n\\n__handle_irq_event_percpu+0x3d/0x170\\n\\namdgpu: Topology: Add dGPU node [0x74a2:0x1002]\\n\\nhandle_irq_event+0x5a/@xcO\\n\\nhandle_edge_irq+0x93/0x240\\n\\nkfd kfd: amdgpu: KFD node 1 partition @ size 49148M\\n\\nasm_call_irq_on_stack+0xf/@x20\\n\\n\u003c/IRQ\u003e\\n\\ncommon_interrupt+0xb3/0x130\\n\\nasm_common_interrupt+0x1le/0x40\\n\\n5.10.134-010.a1i5000.a18.x86_64 #1\"}],\"affected\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"affectedData\":[{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"unaffected\",\"programFiles\":[\"drivers/gpu/drm/amd/amdkfd/kfd_device.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"74c5b85da75475c73a8f040397610fbfcc2c3e78\",\"lessThan\":\"93f8d67ef8b50334a26129df4da5a4cb60ad4090\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"74c5b85da75475c73a8f040397610fbfcc2c3e78\",\"lessThan\":\"bc9e789053abe463f8cf74eee5fc2f157c11a79f\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"74c5b85da75475c73a8f040397610fbfcc2c3e78\",\"lessThan\":\"2f89a2d15550b653caaeeab7ab68c4d7583fd4fe\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"74c5b85da75475c73a8f040397610fbfcc2c3e78\",\"lessThan\":\"99d7181bca34e96fbf61bdb6844918bdd4df2814\",\"versionType\":\"git\",\"status\":\"affected\"}]},{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"affected\",\"programFiles\":[\"drivers/gpu/drm/amd/amdkfd/kfd_device.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"6.5\",\"status\":\"affected\"},{\"version\":\"0\",\"lessThan\":\"6.5\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.6.117\",\"lessThanOrEqual\":\"6.6.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.12.58\",\"lessThanOrEqual\":\"6.12.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.17.8\",\"lessThanOrEqual\":\"6.17.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"6.18\",\"lessThanOrEqual\":\"*\",\"versionType\":\"original_commit_for_fix\",\"status\":\"unaffected\"}]}]}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/2f89a2d15550b653caaeeab7ab68c4d7583fd4fe\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/93f8d67ef8b50334a26129df4da5a4cb60ad4090\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/99d7181bca34e96fbf61bdb6844918bdd4df2814\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/bc9e789053abe463f8cf74eee5fc2f157c11a79f\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}",
    "redhat_vex": {
      "aggregate_severity": "None",
      "current_release_date": "2026-06-30T10:15:13+00:00",
      "cve": "CVE-2025-40310",
      "id": "CVE-2025-40310",
      "initial_release_date": "2025-12-08T00:00:00+00:00",
      "product_status:known_not_affected": "274",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: amd/amdkfd: resolve a race in amdgpu_amdkfd_device_fini_sw",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2025/cve-2025-40310.json",
      "version": "3"
    },
    "suse_vex": {
      "aggregate_severity": "moderate",
      "current_release_date": "2026-09-11T01:53:55Z",
      "cve": "CVE-2025-40310",
      "id": "CVE-2025-40310",
      "initial_release_date": "2025-12-09T00:24:24Z",
      "product_status:first_fixed": "2",
      "product_status:known_affected": "461",
      "product_status:known_not_affected": "368",
      "product_status:recommended": "384",
      "source": "SUSE CSAF VEX",
      "status": "interim",
      "title": "SUSE CVE CVE-2025-40310",
      "url": "https://ftp.suse.com/pub/projects/security/csaf-vex/cve-2025-40310.json",
      "version": "36"
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…

Related by attack behaviour

Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.


Loading…