From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out30-99.freemail.mail.aliyun.com (out30-99.freemail.mail.aliyun.com [115.124.30.99]) (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 A957F385537; Thu, 22 Jan 2026 16:34:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=115.124.30.99 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769099662; cv=none; b=HvFaZJpibX+PnUTFaP/9yhy9HFKBUfg3m89LFENSJ2M1bc+ow9+IsaZZhOjQypTmABu6BdQHqml1ww7fbeAwMbFURHpW4a4g0dqR2GscV53GtMnDHR7K2rX6z20dJj8EPs+P49/+aV8fOhpL2XradY6O4Y/q7R79Q2QwqdQygLY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769099662; c=relaxed/simple; bh=Rw8FHVCOPLjJdXTdfE/oQmHIS3ulYs4yNB8D2Xh2LNE=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=hv5p8YcbjcfoMJDPDZH+Bco/fhHHpRfTbBtdwXbhtcBevlg//W+Jppkev8v89vlsi3pUtwU3uROWLad9lucGJBjWVut6IxpA3z/rm7JbgGmCWH/JHpF+BcjNsiDGLzEECx/WBY2d1xpwkkmqs4Ph2ClKp1BuE0rad6oFlmzxyQo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.alibaba.com; spf=pass smtp.mailfrom=linux.alibaba.com; dkim=pass (1024-bit key) header.d=linux.alibaba.com header.i=@linux.alibaba.com header.b=D7JrVd92; arc=none smtp.client-ip=115.124.30.99 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.alibaba.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.alibaba.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.alibaba.com header.i=@linux.alibaba.com header.b="D7JrVd92" DKIM-Signature:v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.alibaba.com; s=default; t=1769099645; h=Message-ID:Date:MIME-Version:Subject:To:From:Content-Type; bh=fEshHlJkCQ4C5gcLhmzynvNMcOXrwYWP9cPM3RD8ZZ8=; b=D7JrVd92SWOevwCUTrSvyJiN+bbzCRgtbTIkl8I2tTPYv0I+Mtsu5drCuFPdU9aspIUuF+ntT3oTJwNsWW4Kk95BxQoI73ouSaTgsRXM5Gool7sNTbmlOHtZuOovgGKoZvToyqzEEOaIAUrs8hW2s3KGSp08aNCt9zUp5IWwXb0= Received: from 30.180.182.138(mailfrom:hsiangkao@linux.alibaba.com fp:SMTPD_---0WxctVVp_1769099644 cluster:ay36) by smtp.aliyun-inc.com; Fri, 23 Jan 2026 00:34:05 +0800 Message-ID: Date: Fri, 23 Jan 2026 00:34:04 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v17 06/10] erofs: introduce the page cache share feature To: Hongbo Li Cc: hch@lst.de, djwong@kernel.org, amir73il@gmail.com, linux-fsdevel@vger.kernel.org, linux-erofs@lists.ozlabs.org, linux-kernel@vger.kernel.org, Chao Yu , Christian Brauner References: <20260122153406.660073-1-lihongbo22@huawei.com> <20260122153406.660073-7-lihongbo22@huawei.com> From: Gao Xiang In-Reply-To: <20260122153406.660073-7-lihongbo22@huawei.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 2026/1/22 23:34, Hongbo Li wrote: > From: Hongzhen Luo > > Currently, reading files with different paths (or names) but the same > content will consume multiple copies of the page cache, even if the > content of these page caches is the same. For example, reading > identical files (e.g., *.so files) from two different minor versions of > container images will cost multiple copies of the same page cache, > since different containers have different mount points. Therefore, > sharing the page cache for files with the same content can save memory. > > This introduces the page cache share feature in erofs. It allocate a > shared inode and use its page cache as shared. Reads for files > with identical content will ultimately be routed to the page cache of > the shared inode. In this way, a single page cache satisfies > multiple read requests for different files with the same contents. > > We introduce new mount option `inode_share` to enable the page > sharing mode during mounting. This option is used in conjunction > with `domain_id` to share the page cache within the same trusted > domain. > > Signed-off-by: Hongzhen Luo > Signed-off-by: Hongbo Li Reviewed-by: Gao Xiang Thanks, Gao Xiang