In the Linux kernel, the following vulnerability has been resolved:
netfs: Call invalidate_cache only if implemented
Many filesystems such as NFS and Ceph do not implement the
invalidate_cache method. On those filesystems, if writing to the
cache (NETFS_WRITE_TO_CACHE) fails for some reason, the kernel
crashes like this:
BUG: kernel NULL pointer dereference, address: 0000000000000000 #PF: supervisor instruction fetch in kernel mode #PF: errorcode(0x0010) - not-present page PGD 0 P4D 0 Oops: Oops: 0010 [#1] SMP PTI CPU: 9 UID: 0 PID: 3380 Comm: kworker/u193:11 Not tainted 6.13.3-cm4all1-hp #437 Hardware name: HP ProLiant DL380 Gen9/ProLiant DL380 Gen9, BIOS P89 10/17/2018 Workqueue: eventsunbound netfswritecollectionworker RIP: 0010:0x0 Code: Unable to access opcode bytes at 0xffffffffffffffd6. RSP: 0018:ffff9b86e2ca7dc0 EFLAGS: 00010202 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 7fffffffffffffff RDX: 0000000000000001 RSI: ffff89259d576a18 RDI: ffff89259d576900 RBP: ffff89259d5769b0 R08: ffff9b86e2ca7d28 R09: 0000000000000002 R10: ffff89258ceaca80 R11: 0000000000000001 R12: 0000000000000020 R13: ffff893d158b9338 R14: ffff89259d576900 R15: ffff89259d5769b0 FS: 0000000000000000(0000) GS:ffff893c9fa40000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: ffffffffffffffd6 CR3: 000000054442e003 CR4: 00000000001706f0 Call Trace: <TASK> ? _die+0x1f/0x60 ? pagefaultoops+0x15c/0x460 ? trytowakeup+0x2d2/0x530 ? excpagefault+0x5e/0x100 ? asmexcpagefault+0x22/0x30 netfswritecollectionworker+0xe9f/0x12b0 ? xspollcheckreadable+0x3f/0x80 ? xsstreamdatareceiveworkfn+0x8d/0x110 processonework+0x134/0x2d0 workerthread+0x299/0x3a0 ? _pfxworkerthread+0x10/0x10 kthread+0xba/0xe0 ? _pfxkthread+0x10/0x10 retfromfork+0x30/0x50 ? _pfxkthread+0x10/0x10 retfromfork_asm+0x1a/0x30 </TASK> Modules linked in: CR2: 0000000000000000
This patch adds the missing NULL check.
[
{
"digest": {
"function_hash": "115306432762890404643323271335466821323",
"length": 1905.0
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-1527e31d",
"target": {
"file": "fs/netfs/write_collect.c",
"function": "netfs_write_collection_worker"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@344b7ef248f420ed4ba3a3539cb0a0fc18df9a6c",
"signature_type": "Function"
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"253190829739632914664865289836521131834",
"233548909284131472544954919250929679408",
"277492700711973610917846258234791585369",
"337216038527819590157744702742209505891"
]
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-449c3c58",
"target": {
"file": "fs/netfs/write_collect.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0def1a40c3e76a468f8f66aa572caed44ec37277",
"signature_type": "Line"
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"253190829739632914664865289836521131834",
"233548909284131472544954919250929679408",
"277492700711973610917846258234791585369",
"337216038527819590157744702742209505891"
]
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-46de6582",
"target": {
"file": "fs/netfs/write_collect.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@344b7ef248f420ed4ba3a3539cb0a0fc18df9a6c",
"signature_type": "Line"
},
{
"digest": {
"function_hash": "115306432762890404643323271335466821323",
"length": 1905.0
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-58d5c0c9",
"target": {
"file": "fs/netfs/write_collect.c",
"function": "netfs_write_collection_worker"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@0def1a40c3e76a468f8f66aa572caed44ec37277",
"signature_type": "Function"
},
{
"digest": {
"threshold": 0.9,
"line_hashes": [
"253190829739632914664865289836521131834",
"233548909284131472544954919250929679408",
"277492700711973610917846258234791585369",
"337216038527819590157744702742209505891"
]
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-5baf966f",
"target": {
"file": "fs/netfs/write_collect.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@c2d5d14a7bcbb045d0cd0095cefe95f2a4b91159",
"signature_type": "Line"
},
{
"digest": {
"function_hash": "115306432762890404643323271335466821323",
"length": 1905.0
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2025-22002-6866c9e3",
"target": {
"file": "fs/netfs/write_collect.c",
"function": "netfs_write_collection_worker"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@c2d5d14a7bcbb045d0cd0095cefe95f2a4b91159",
"signature_type": "Function"
}
]