# CVE-2025-40125: linux: In the Linux kernel, the following vulnerability has been resolved:  blk-mq: check kobject state_in_sysfs before dele...

CVE-2025-40125 is fixed in 64 products on 1 platform, first by ALAS2023-2025-1253, released October 27, 2025. It is not reported as exploited. Patch Radar priority: Routine.

- Web page: https://patchblox.com/security/cve/CVE-2025-40125
- Priority: Routine
- CVSS: 5.5 (IMPORTANT)
- EPSS: 0.0023
- CISA KEV: not listed
- Exploited (vendor report): no
- Publicly disclosed: no
- Published: Oct 27, 2025

## Description

In the Linux kernel, the following vulnerability has been resolved:  blk-mq: check kobject state_in_sysfs before deleting in blk_mq_unregister_hctx  In __blk_mq_update_nr_hw_queues() the return value of blk_mq_sysfs_register_hctxs() is not checked. If sysfs creation for hctx fails, later changing the number of hw_queues or removing disk will trigger the following warning:    kernfs: can not remove 'nr_tags', no directory   WARNING: CPU: 2 PID: 637 at fs/kernfs/dir.c:1707 kernfs_remove_by_name_ns+0x13f/0x160   Call Trace:    remove_files.isra.1+0x38/0xb0    sysfs_remove_group+0x4d/0x100    sysfs_remove_groups+0x31/0x60    __kobject_del+0x23/0xf0    kobject_del+0x17/0x40    blk_mq_unregister_hctx+0x5d/0x80    blk_mq_sysfs_unregister_hctxs+0x94/0xd0    blk_mq_update_nr_hw_queues+0x124/0x760    nullb_update_nr_hw_queues+0x71/0xf0 [null_blk]    nullb_device_submit_queues_store+0x92/0x120 [null_blk]  kobjct_del() was called unconditionally even if sysfs creation failed. Fix it by checkig the kobject creation statusbefore deleting it.

## Where it's fixed

| Platform | Product | Fixed in | Fix | Released |
|---|---|---|---|---|
| Linux | bpftool amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | bpftool ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | bpftool ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | bpftool-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | bpftool6.12 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | bpftool6.12-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-debuginfo-common-aarch64 amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-debuginfo-common-x86_64 amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-devel amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-headers amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-libbpf amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-libbpf-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-libbpf-devel amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-libbpf-static amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-livepatch-6.1.156-177.286 amzn 2023 | 1:1.0-0.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-livepatch-6.12.53-69.119 amzn 2023 | 1:1.0-0.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel-modules-extra amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-modules-extra-common amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-tools amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-tools-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-tools-devel amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | kernel-uek ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-container ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-container ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-container-debug ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-container-debug ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-core ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-core ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-core ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-core ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-devel ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-devel ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-modules ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-modules ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-modules-extra ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-debug-modules-extra ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-devel ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-devel ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-doc ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-doc ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-modules ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-modules ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-modules-extra ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-modules-extra ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek-tools ol 8 | 0:5.4.17-2136.350.3.1.el7uek | [ELSA-2025-28049](https://patchblox.com/security/data/fix/linux/elsa-2025-28049.md) | Dec 12, 2025 |
| Linux | kernel-uek64k ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-core ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-core ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-devel ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-devel ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-modules ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-modules ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-modules-extra ol 8 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel-uek64k-modules-extra ol 9 | 0:5.15.0-315.196.5.1.el9uek | [ELSA-2025-28048](https://patchblox.com/security/data/fix/linux/elsa-2025-28048.md) | Dec 12, 2025 |
| Linux | kernel6.12 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-debuginfo-common-aarch64 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-debuginfo-common-x86_64 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-devel amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-headers amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-libbpf amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-libbpf-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-libbpf-devel amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-libbpf-static amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-modules-extra amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-modules-extra-common amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-tools amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-tools-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | kernel6.12-tools-devel amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | linux Debian 12.15 (bookworm) | 6.1.158-1 | [DEBIAN-CVE-2025-40125](https://patchblox.com/security/data/fix/linux/debian-cve-2025-40125.md) | Nov 12, 2025 |
| Linux | linux Debian 13.5 (trixie) | 6.12.57-1 | [DEBIAN-CVE-2025-40125](https://patchblox.com/security/data/fix/linux/debian-cve-2025-40125.md) | Nov 12, 2025 |
| Linux | linux Debian 14 | 6.17.6-1 | [DEBIAN-CVE-2025-40125](https://patchblox.com/security/data/fix/linux/debian-cve-2025-40125.md) | Nov 12, 2025 |
| Linux | perf amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | perf-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | perf6.12 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | perf6.12-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | python3-perf amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | python3-perf-debuginfo amzn 2023 | 1:6.1.156-177.286.amzn2023 | [ALAS2023-2025-1253](https://patchblox.com/security/data/fix/linux/alas2023-2025-1253.md) | Oct 27, 2025 |
| Linux | python3-perf6.12 amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |
| Linux | python3-perf6.12-debuginfo amzn 2023 | 1:6.12.53-69.119.amzn2023 | [ALAS2023-2025-1254](https://patchblox.com/security/data/fix/linux/alas2023-2025-1254.md) | Oct 27, 2025 |

---

Data as of 2026-11-09T01:18:40Z UTC. Source: Patchblox Patch Radar (https://patchblox.com/security/patch-radar). Patchblox finds out-of-date software on Windows, macOS and Linux and updates it through release rings: https://patchblox.com/demo

Free to use with attribution: show "Data: Patchblox Patch Radar" with a link to https://patchblox.com/security/patch-radar. Terms, including what needs a written agreement: https://patchblox.com/security/patch-radar/use-the-data

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.
