From nobody Thu Apr 2 15:42:31 2026 Received: from mxhk.zte.com.cn (mxhk.zte.com.cn [160.30.148.34]) (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 A14FD2BD587 for ; Wed, 11 Feb 2026 07:40:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=160.30.148.34 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770795662; cv=none; b=lSzRNsFuyikJAzAI8juxGxHd2sRSrQTjLjAuXgwAu+BJjNDOu4snylDeKt/Ww3WXoxlF2hyJICrUpYId/baMJ5vIlMrVLPk2MSuJ5dwlhTEHy0ttZWtDC9B/rSCV6R1o3giVwMJbtahf+lXdrFb+AH/hifjvTULra9KtY+gN/rc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770795662; c=relaxed/simple; bh=y1GVgPFinG3HamE/zPmpNSY1JqvPYXfUS2V9tmUCKOU=; h=Message-ID:Date:Mime-Version:From:To:Cc:Subject:Content-Type; b=bjDA9V5WvKY7OHA7kecU002yG7PEgjrGIcd1wC3McZ6zcDfHEvqOZMt3hrd8hWzgYrw2mZz5vq8zcS+9KblFCz4FHjpxahpghTm58SnjyX1cxVDM6VccYbK5Y3CipBWpH/9mr9AgVBIv99p9Mq9Ru8lJkC/g4wnEaczolvAO2sw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=zte.com.cn; spf=pass smtp.mailfrom=zte.com.cn; arc=none smtp.client-ip=160.30.148.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=zte.com.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=zte.com.cn Received: from mse-fl1.zte.com.cn (unknown [10.5.228.132]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mxhk.zte.com.cn (FangMail) with ESMTPS id 4f9r2W734yz5B11P; Wed, 11 Feb 2026 15:40:51 +0800 (CST) Received: from xaxapp02.zte.com.cn ([10.88.97.241]) by mse-fl1.zte.com.cn with SMTP id 61B7eeAI045696; Wed, 11 Feb 2026 15:40:41 +0800 (+08) (envelope-from fan.yu9@zte.com.cn) Received: from mapi (xaxapp02[null]) by mapi (Zmail) with MAPI id mid32; Wed, 11 Feb 2026 15:40:43 +0800 (CST) X-Zmail-TransId: 2afa698c327bc49-e12cb X-Mailer: Zmail v1.0 Message-ID: <20260211154043158VVS6WEc8yD82HcqScmYUn@zte.com.cn> Date: Wed, 11 Feb 2026 15:40:43 +0800 (CST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 From: To: , Cc: , , , , , , , Subject: =?UTF-8?B?W1BBVENIXSB1YmlmczogcHJldmVudCBjb3JydXB0ZWQgZGF0YSB3cml0ZSB2aWEgZXJyb3JfcmVtb3ZlX2ZvbGlv?= X-MAIL: mse-fl1.zte.com.cn 61B7eeAI045696 X-TLS: YES X-SPF-DOMAIN: zte.com.cn X-ENVELOPE-SENDER: fan.yu9@zte.com.cn X-SPF: None X-SOURCE-IP: 10.5.228.132 unknown Wed, 11 Feb 2026 15:40:52 +0800 X-Fangmail-Anti-Spam-Filtered: true X-Fangmail-MID-QID: 698C3283.001/4f9r2W734yz5B11P Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Jinpeng Cui When a memory corruption event triggers memory_failure, ext4 releases refer= ences to the affected dirty pages, ensuring that no corrupted data is written to disk. However, ubifs currentl= y lacks the error_remove_folio capability and therefore cannot release references to faulty private memory. As a resu= lt, corrupted data may eventually be written to flash storage. Add generic_error_remove_folio support to ubifs, preventing corrupted memor= y data from being persisted to flash. Signed-off-by: Jinpeng Cui Signed-off-by: Fan Yu Cc: Shengming Hu Reviewed-by: Zhihao Cheng --- fs/ubifs/file.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/ubifs/file.c b/fs/ubifs/file.c index 3dc3ca1..34445b7 100644 --- a/fs/ubifs/file.c +++ b/fs/ubifs/file.c @@ -1631,6 +1631,7 @@ static int ubifs_symlink_getattr(struct mnt_idmap *id= map, .dirty_folio =3D ubifs_dirty_folio, .migrate_folio =3D filemap_migrate_folio, .release_folio =3D ubifs_release_folio, + .error_remove_folio =3D generic_error_remove_folio, }; const struct inode_operations ubifs_file_inode_operations =3D { -- 1.8.3.1