Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.2/patches/2234986/?format=api
{ "id": 2234986, "url": "http://patchwork.ozlabs.org/api/1.2/patches/2234986/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20260508121539.4174601-5-libaokun@linux.alibaba.com/", "project": { "id": 8, "url": "http://patchwork.ozlabs.org/api/1.2/projects/8/?format=api", "name": "Linux ext4 filesystem development", "link_name": "linux-ext4", "list_id": "linux-ext4.vger.kernel.org", "list_email": "linux-ext4@vger.kernel.org", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260508121539.4174601-5-libaokun@linux.alibaba.com>", "list_archive_url": null, "date": "2026-05-08T12:15:26", "name": "[RFC,04/17] ext4: fix incorrect block bitmap free clusters update on metadata overlap", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "77236347b237c5f394bca83d69f7a56bf35ebb72", "submitter": { "id": 92757, "url": "http://patchwork.ozlabs.org/api/1.2/people/92757/?format=api", "name": "Baokun Li", "email": "libaokun@linux.alibaba.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20260508121539.4174601-5-libaokun@linux.alibaba.com/mbox/", "series": [ { "id": 503377, "url": "http://patchwork.ozlabs.org/api/1.2/series/503377/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/list/?series=503377", "date": "2026-05-08T12:15:22", "name": "ext4/lib-crc: LBS performance part 1 - incremental CRC32c for bitmap checksums", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/503377/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2234986/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2234986/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "\n <SRS0=qFRJ=DF=vger.kernel.org=linux-ext4+bounces-16364-patchwork-incoming=ozlabs.org@ozlabs.org>", "X-Original-To": [ "incoming@patchwork.ozlabs.org", "linux-ext4@vger.kernel.org" ], "Delivered-To": [ "patchwork-incoming@legolas.ozlabs.org", "patchwork-incoming@ozlabs.org" ], "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=linux.alibaba.com header.i=@linux.alibaba.com\n header.a=rsa-sha256 header.s=default header.b=ZiKMth1D;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=ozlabs.org\n (client-ip=2404:9400:2221:ea00::3; helo=mail.ozlabs.org;\n envelope-from=srs0=qfrj=df=vger.kernel.org=linux-ext4+bounces-16364-patchwork-incoming=ozlabs.org@ozlabs.org;\n receiver=patchwork.ozlabs.org)", "gandalf.ozlabs.org;\n arc=pass smtp.remote-ip=\"2600:3c0a:e001:db::12fc:5321\"\n arc.chain=subspace.kernel.org", "gandalf.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=linux.alibaba.com", "gandalf.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=linux.alibaba.com header.i=@linux.alibaba.com\n header.a=rsa-sha256 header.s=default header.b=ZiKMth1D;\n\tdkim-atps=neutral", "gandalf.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-ext4+bounces-16364-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org)", "smtp.subspace.kernel.org;\n\tdkim=pass (1024-bit key) header.d=linux.alibaba.com\n header.i=@linux.alibaba.com header.b=\"ZiKMth1D\"", "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=115.124.30.112", "smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=linux.alibaba.com", "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=linux.alibaba.com" ], "Received": [ "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1 raw public key)\n server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4gBp9M6Yr5z1yKd\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 08 May 2026 22:20:23 +1000 (AEST)", "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\n\tby gandalf.ozlabs.org (Postfix) with ESMTP id 4gBp9M5YxWz4wJg\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 08 May 2026 22:20:23 +1000 (AEST)", "by gandalf.ozlabs.org (Postfix)\n\tid 4gBp9M5SJ8z4wKD; Fri, 08 May 2026 22:20:23 +1000 (AEST)", "from sea.lore.kernel.org (sea.lore.kernel.org\n [IPv6:2600:3c0a:e001:db::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby gandalf.ozlabs.org (Postfix) with ESMTPS id 4gBp9J2lC3z4wJg\n\tfor <patchwork-incoming@ozlabs.org>; Fri, 08 May 2026 22:20:20 +1000 (AEST)", "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sea.lore.kernel.org (Postfix) with ESMTP id 0E0043091974\n\tfor <patchwork-incoming@ozlabs.org>; Fri, 8 May 2026 12:16:10 +0000 (UTC)", "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 6999B35F162;\n\tFri, 8 May 2026 12:16:09 +0000 (UTC)", "from out30-112.freemail.mail.aliyun.com\n (out30-112.freemail.mail.aliyun.com [115.124.30.112])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 442BD37FF76;\n\tFri, 8 May 2026 12:16:05 +0000 (UTC)", "from\n x31h02109.sqa.na131.tbsite.net(mailfrom:libaokun@linux.alibaba.com\n fp:SMTPD_---0X2XQgo7_1778242562 cluster:ay36)\n by smtp.aliyun-inc.com;\n Fri, 08 May 2026 20:16:02 +0800" ], "ARC-Seal": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1778242823; cv=pass;\n\tb=uR81uCv2WZpKHkVhUmvHUj74ExwMKDoo9ygoTlvWyITYc4cReAK3quDFAU4fIQ0x0wQ7qc4oLFgyy1ZqgDsz/N7ahdWSoqmy6y/vkGVdOBnQjsa3Z1L3wFZ3nPrqKyZPnXRekUPG3JtLq1k7+hiAfkHAkC51TIq7wK+gHDoon/ubQhE8eZPSRm4s7RmOkYJ8hVmqG6nPZ1oVltLpInzMcwly1r5oJ2Z2E96Dr7u4bzKIhiVqwAOH210xR1lj1rwc7FG2uMvDWbUztsBaAbxORcfh/+2SHHnvKOVsBM2Y/q8bSIBhtAgDzzKp9YnGge0oFLeiKRHbynjee6plc4+wLQ==", "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1778242569; cv=none;\n b=K9Uz0OMQtBu/fxbcusAeuD+EFvg6iKFhZLZK0fAdInykbSOn2Hgn7GB42iQRiTyGMXNqo0BFrGYOOPXrUp1iUorBOMfDmEqZoevNLJBjMFKwW0by/TUhf8LS+yI66dlK2rwr0jDavCqJP3PbXHKd0pZEFk5npmRS0cIYOaQGvuA=" ], "ARC-Message-Signature": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707;\n\tt=1778242823; c=relaxed/relaxed;\n\tbh=UjyILuNe0LAhrUwcQd6OrpHIO74QHE8aSygiu8ENNoo=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=SfaNyneJpcojFNbDMaKzsNefZ8FmVpHwIFwsfHWhWgpLCdF8RMgoqLDQs4Bddg8aSaBIhstdfEeSqGujP5WLpyw3HzgtC8IR979lsSt8kUNU3GzCXC5uRF9QWoZgqAR6C/isVxW8jbAflMfi+utd+UrrQv5MgoaBW29ukX4tRbkldHvKvJjNquMaIebk5Q2NKvtT0Mn54fQ3zlrHTO1uh2gKTkv8Pgzwdm43FrCq7bDCH1L3HXoWytRclg4JcHtWOTg7XFFX/aFK3gjgcdDXt1jsoMLajlERafA+jeRrmwFG0S7beHOWgINoJM/AEcZmIjdxYwWTIsa+qAxIVR3H2w==", "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1778242569; c=relaxed/simple;\n\tbh=eI+lnb4OIstw+TJ/gSUcTbk+6CPtXDvwn0TN344wuIA=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=ni/5Mmj2ipAKXuIUFWOny7Jty782J1O4IQcvQiOVEMn/rVgbYfHjYUt7uDkUVX52ubhhHaKM9cr5xcJ9pufPMAh/xEx+KqwblGLudf/59sK3n2YRww0aN+PRh4gVmg+NBd05Irlr3e45WJXi/eMquD/ieZEaqCUZ0Azfb4sLh5Y=" ], "ARC-Authentication-Results": [ "i=2; gandalf.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=linux.alibaba.com;\n dkim=pass (1024-bit key;\n unprotected) header.d=linux.alibaba.com header.i=@linux.alibaba.com\n header.a=rsa-sha256 header.s=default header.b=ZiKMth1D; dkim-atps=neutral;\n spf=pass (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-ext4+bounces-16364-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org) smtp.mailfrom=vger.kernel.org", "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=linux.alibaba.com;\n spf=pass smtp.mailfrom=linux.alibaba.com;\n dkim=pass (1024-bit key) header.d=linux.alibaba.com\n header.i=@linux.alibaba.com header.b=ZiKMth1D;\n arc=none smtp.client-ip=115.124.30.112" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=linux.alibaba.com; s=default;\n\tt=1778242563; h=From:To:Subject:Date:Message-ID:MIME-Version;\n\tbh=UjyILuNe0LAhrUwcQd6OrpHIO74QHE8aSygiu8ENNoo=;\n\tb=ZiKMth1DCl8veoBr+UFzIJ5EzNohOFnj4bjiPXxqtTwyff/Yg9egkJBaO/ylGUadrZtoxTt7oYSYDI1J2VMsMijbKI2/CCzQVW1OYoa6U8DxIgTHylqygdTZ7CnVQ3zbCf6erovoSOmXiin4X2b+2CBOydhNfCrvTX9FEGZ2a+Y=", "X-Alimail-AntiSpam": "\n AC=PASS;BC=-1|-1;BR=01201311R251e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=maildocker-contentspam033037026112;MF=libaokun@linux.alibaba.com;NM=1;PH=DS;RN=11;SR=0;TI=SMTPD_---0X2XQgo7_1778242562;", "From": "Baokun Li <libaokun@linux.alibaba.com>", "To": "linux-ext4@vger.kernel.org", "Cc": "linux-crypto@vger.kernel.org,\n\tebiggers@kernel.org,\n\tardb@kernel.org,\n\ttytso@mit.edu,\n\tadilger.kernel@dilger.ca,\n\tjack@suse.cz,\n\tyi.zhang@huawei.com,\n\tojaswin@linux.ibm.com,\n\tritesh.list@gmail.com,\n\tBaokun Li <libaokun@linux.alibaba.com>", "Subject": "[PATCH RFC 04/17] ext4: fix incorrect block bitmap free clusters\n update on metadata overlap", "Date": "Fri, 8 May 2026 20:15:26 +0800", "Message-ID": "<20260508121539.4174601-5-libaokun@linux.alibaba.com>", "X-Mailer": "git-send-email 2.43.7", "In-Reply-To": "<20260508121539.4174601-1-libaokun@linux.alibaba.com>", "References": "<20260508121539.4174601-1-libaokun@linux.alibaba.com>", "Precedence": "bulk", "X-Mailing-List": "linux-ext4@vger.kernel.org", "List-Id": "<linux-ext4.vger.kernel.org>", "List-Subscribe": "<mailto:linux-ext4+subscribe@vger.kernel.org>", "List-Unsubscribe": "<mailto:linux-ext4+unsubscribe@vger.kernel.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-Spam-Status": "No, score=-8.7 required=5.0 tests=ARC_SIGNED,ARC_VALID,\n\tDKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DMARC_PASS,\n\tHEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,\n\tSPF_PASS,UNPARSEABLE_RELAY,USER_IN_DEF_DKIM_WL autolearn=disabled\n\tversion=4.0.1", "X-Spam-Checker-Version": "SpamAssassin 4.0.1 (2024-03-25) on gandalf.ozlabs.org" }, "content": "In ext4_mb_mark_diskspace_used(), when the allocator detects that the\nallocated blocks overlap with filesystem metadata, it enters an error\nrecovery path that marks these blocks as used in the bitmap via\next4_mb_mark_context() with flags=0.\n\nWithout EXT4_MB_BITMAP_MARKED_CHECK, ext4_mb_mark_context() assumes all\nbits in the range will be flipped, so it sets changed=len unconditionally.\nHowever, in a corrupted filesystem, some of these metadata blocks may\nalready be marked as used (bit=1) in the bitmap. Since mb_set_bits() is\nidempotent (sets bits to 1 regardless of current state), bits that are\nalready set won't actually change, but the free clusters count is still\ndecremented by the full range length, leading to an inaccurate free\nclusters count.\n\nFix this by passing EXT4_MB_BITMAP_MARKED_CHECK, which correctly counts\nonly the bits that actually changed state.\n\nFixes: 2f94711b098b (\"ext4: call ext4_mb_mark_context in ext4_mb_mark_diskspace_used\")\nSigned-off-by: Baokun Li <libaokun@linux.alibaba.com>\n---\n fs/ext4/mballoc.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)", "diff": "diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c\nindex ed1bd00e11cd..ff2023c9f52c 100644\n--- a/fs/ext4/mballoc.c\n+++ b/fs/ext4/mballoc.c\n@@ -4228,7 +4228,7 @@ ext4_mb_mark_diskspace_used(struct ext4_allocation_context *ac, handle_t *handle\n \t\t\t\t\t ac->ac_b_ex.fe_group,\n \t\t\t\t\t ac->ac_b_ex.fe_start,\n \t\t\t\t\t ac->ac_b_ex.fe_len,\n-\t\t\t\t\t 0, NULL);\n+\t\t\t\t\t EXT4_MB_BITMAP_MARKED_CHECK, NULL);\n \t\tif (!err)\n \t\t\terr = -EFSCORRUPTED;\n \t\treturn err;\n", "prefixes": [ "RFC", "04/17" ] }