From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 52EC2314B9A for ; Wed, 24 Jun 2026 16:35:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782318930; cv=none; b=E27q4UdrkWSGSbIcbHzOBoEkiCIJgherqYY8I9y0MNBZq+ZiTwXACZ93kIDhTMmoiT5J7DHcT8SdOp1RRa8ADLlvAEBl61Y92YKW6Nz9rPpDTMH5C6Fe+xqQmyhHuw9tgHoSy3ps2MHcI2YbroX44Q5V4NxKJJiHO7SHyuOxVJ8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782318930; c=relaxed/simple; bh=h7VcMF6US4dkWbR6AOB8D7y5ySEW8of3neapMgCvyHw=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=uwV8DHm4Rnx6oko7ZObi7A664XyCrGN+WdZRvIpIkWdpUJIyuuJRcLbkWNi8WJGEpv6+BBVIFy4N9S6T9VR4DWX2Hce4O6A1IU3ZYKG8ed5N/614BYbESAo4K1T1k7L73dOpVQ7r3QUWeXl4fD+YoFUY9COXlFh6kB915QPELRY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=hZPWgYAO; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="hZPWgYAO" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 98E7D1F000E9; Wed, 24 Jun 2026 16:35:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1782318929; bh=j9tyVO7XY+AWMGWfnUeQ+9uGfb6vF4XwI5M5m9DCXR8=; h=From:To:Cc:Subject:Date:Reply-To; b=hZPWgYAOoiRIWe9rmZiVGtksN3geKNe1G8AcjB0El18okPwScvKNuoT4fBIu6eGU1 vTQX79lg1inQY+bSYnVVCvSR1IxI5oUSYvDf8YWKW8v7fTPyfKil2ccAIpeNa8z8+g QUqKlLZGRi7gHu21j7gdGSpeEbQjkcYltyB1LTxI= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-53018: f2fs: avoid reading already updated pages during GC Date: Wed, 24 Jun 2026 17:30:42 +0100 Message-ID: <2026062451-CVE-2026-53018-3797@gregkh> X-Mailer: git-send-email 2.54.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3922; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=Z7yykEMYgOjj/ttFSOYzgklWf/55303FDDfPR6ogpfg=; b=owGbwMvMwCRo6H6F97bub03G02pJDFk2rP/vHi/mWmO05dmM/gdsCn6n7OW5hYqVjud+vrzL6 XnfTIE5HbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCRwNMM8/Q/5J9qu6XwbFMB J7/N9gqBvOmVugwLZv/9OoGh4mbuE0HJ9jX6W58I765UAQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: f2fs: avoid reading already updated pages during GC We found the following issue during fuzz testing: page: refcount:3 mapcount:0 mapping:00000000b6e89c65 index:0x18b2dc pfn:0x161ba9 memcg:f8ffff800e269c00 aops:f2fs_meta_aops ino:2 flags: 0x52880000000080a9(locked|waiters|uptodate|lru|private|zone=1|kasantag=0x4a) raw: 52880000000080a9 fffffffec6e17588 fffffffec0ccc088 a7ffff8067063618 raw: 000000000018b2dc 0000000000000009 00000003ffffffff f8ffff800e269c00 page dumped because: VM_BUG_ON_FOLIO(folio_test_uptodate(folio)) page_owner tracks the page as allocated post_alloc_hook+0x58c/0x5ec prep_new_page+0x34/0x284 get_page_from_freelist+0x2dcc/0x2e8c __alloc_pages_noprof+0x280/0x76c __folio_alloc_noprof+0x18/0xac __filemap_get_folio+0x6bc/0xdc4 pagecache_get_page+0x3c/0x104 do_garbage_collect+0x5c78/0x77a4 f2fs_gc+0xd74/0x25f0 gc_thread_func+0xb28/0x2930 kthread+0x464/0x5d8 ret_from_fork+0x10/0x20 ------------[ cut here ]------------ kernel BUG at mm/filemap.c:1563! folio_end_read+0x140/0x168 f2fs_finish_read_bio+0x5c4/0xb80 f2fs_read_end_io+0x64c/0x708 bio_endio+0x85c/0x8c0 blk_update_request+0x690/0x127c scsi_end_request+0x9c/0xb8c scsi_io_completion+0xf0/0x250 scsi_finish_command+0x430/0x45c scsi_complete+0x178/0x6d4 blk_mq_complete_request+0xcc/0x104 scsi_done_internal+0x214/0x454 scsi_done+0x24/0x34 which is similar to the problem reported by syzbot: https://syzkaller.appspot.com/bug?extid=3686758660f980b402dc This case is consistent with the description in commit 9bf1a3f ("f2fs: avoid GC causing encrypted file corrupted"): Page 1 is moved from blkaddr A to blkaddr B by move_data_block, and after being written it is marked as uptodate. Then, Page 1 is moved from blkaddr B to blkaddr C, VM_BUG_ON_FOLIO was triggered in the endio initiated by ra_data_block. There is no need to read Page 1 again from blkaddr B, since it has already been updated. Therefore, avoid initiating I/O in this case. The Linux kernel CVE team has assigned CVE-2026-53018 to this issue. Affected and fixed versions =========================== Issue introduced in 4.19 with commit 6aa58d8ad20a3323f42274c25820a6f54192422d and fixed in 6.18.33 with commit 4623c251496b99c530ce225c05334f4eac8b933a Issue introduced in 4.19 with commit 6aa58d8ad20a3323f42274c25820a6f54192422d and fixed in 7.0.10 with commit b663ebb8a340eae5442e605b6acd2cff5677f016 Issue introduced in 4.19 with commit 6aa58d8ad20a3323f42274c25820a6f54192422d and fixed in 7.1 with commit 570e2ccc7cb35fe720106964e65060602d3d2ac4 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-53018 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: fs/f2fs/gc.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/4623c251496b99c530ce225c05334f4eac8b933a https://git.kernel.org/stable/c/b663ebb8a340eae5442e605b6acd2cff5677f016 https://git.kernel.org/stable/c/570e2ccc7cb35fe720106964e65060602d3d2ac4