Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp985030pxp; Wed, 16 Mar 2022 23:30:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkhbrk3PKBjALDlqOGKzvzq89T+3/wShuutU31Jj0ILuRKJ0QRw35mMugvabVBjyReqjuw X-Received: by 2002:a17:906:99c2:b0:6d7:4a6a:e35d with SMTP id s2-20020a17090699c200b006d74a6ae35dmr2800818ejn.633.1647498639312; Wed, 16 Mar 2022 23:30:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647498639; cv=none; d=google.com; s=arc-20160816; b=YBnTPLOTv2QlN0m6Qv3yvFWA8Qa3A8fM9cbNdd5ZcYHo2QDuCGn7JKFsqvvec07oTM lyH3yOOwhJGTMhQCphOj0hV3fwN6iRdmDcDBa6vBbdO73UMIN5h267ujbXINMPPJILfF +fu3VShRf42/pldn1TChcwJtbJYa3VrCIwhdVstKch77ZJwDpRlcTj5oALanGOWkakOf I/qg1M9oH3bdzWqak1umH/NAfUo5awQqOjFKsybtsaXryXaxrCoS81HCQnbLCknyINNN p4KFJTNg5GnYwPdBMRqKJ3Qdt7QkwrIoIQpcFCg7OU1vS8BnEwndngJpOEo4L9XtBts/ 4/tQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:mail-followup-to:message-id:subject:cc:to:from:date; bh=4fgFLu3LyupXi94sOnASRJxjZ0haucW4a24JMzRsVDI=; b=xEz7zjvry20wcl+tvBrNlcCVjDfr76sR0nJU5/e4WlR3dtil6nub0h7oI5Rlqmxv8l 52LvRz27NdPN2EIHhYJ8RRRRzCyoMwa4LkmKTfBGhq5vVMxuT8DnxP7J53n8Hz8u5z3W eVZrY/cx36QR3bCQD5oYPpBunJnYw0x76CwDiWb0uLSil5awbjyvxCwSPDxl8dpmw6My +Ll9lpo97t4Jo5102VXrXOIrZZH/Rg6AdnTXG5O3Qa22v/P/DsTEQSw8OYgdZ5X0b6b8 Hyt2pVsOF7ZGprZTh6acuHlgePwzHOpypgtuBpzp5v7iQsyQAMq3etex+eTLAqA9LGkU QnXw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cw11-20020a170906478b00b006db2639663esi2733609ejc.347.2022.03.16.23.30.14; Wed, 16 Mar 2022 23:30:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229582AbiCQG0J (ORCPT + 99 others); Thu, 17 Mar 2022 02:26:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229750AbiCQG0A (ORCPT ); Thu, 17 Mar 2022 02:26:00 -0400 Received: from out30-54.freemail.mail.aliyun.com (out30-54.freemail.mail.aliyun.com [115.124.30.54]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 243E6B7C78; Wed, 16 Mar 2022 23:18:54 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R181e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04357;MF=hsiangkao@linux.alibaba.com;NM=1;PH=DS;RN=17;SR=0;TI=SMTPD_---0V7QBtbp_1647497928; Received: from B-P7TQMD6M-0146.local(mailfrom:hsiangkao@linux.alibaba.com fp:SMTPD_---0V7QBtbp_1647497928) by smtp.aliyun-inc.com(127.0.0.1); Thu, 17 Mar 2022 14:18:51 +0800 Date: Thu, 17 Mar 2022 14:18:48 +0800 From: Gao Xiang To: Jeffle Xu Cc: dhowells@redhat.com, linux-cachefs@redhat.com, xiang@kernel.org, chao@kernel.org, linux-erofs@lists.ozlabs.org, gregkh@linuxfoundation.org, tao.peng@linux.alibaba.com, willy@infradead.org, linux-kernel@vger.kernel.org, joseph.qi@linux.alibaba.com, bo.liu@linux.alibaba.com, linux-fsdevel@vger.kernel.org, luodaowen.backend@bytedance.com, eguan@linux.alibaba.com, gerry@linux.alibaba.com, torvalds@linux-foundation.org Subject: Re: [Linux-cachefs] [PATCH v5 17/22] erofs: implement fscache-based data read for non-inline layout Message-ID: Mail-Followup-To: Jeffle Xu , dhowells@redhat.com, linux-cachefs@redhat.com, xiang@kernel.org, chao@kernel.org, linux-erofs@lists.ozlabs.org, gregkh@linuxfoundation.org, tao.peng@linux.alibaba.com, willy@infradead.org, linux-kernel@vger.kernel.org, joseph.qi@linux.alibaba.com, bo.liu@linux.alibaba.com, linux-fsdevel@vger.kernel.org, luodaowen.backend@bytedance.com, eguan@linux.alibaba.com, gerry@linux.alibaba.com, torvalds@linux-foundation.org References: <20220316131723.111553-1-jefflexu@linux.alibaba.com> <20220316131723.111553-18-jefflexu@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220316131723.111553-18-jefflexu@linux.alibaba.com> X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 16, 2022 at 09:17:18PM +0800, Jeffle Xu wrote: > This patch implements the data plane of reading data from bootstrap blob > file over fscache for non-inline layout. > > Be noted that compressed layout is not supported yet. > > Signed-off-by: Jeffle Xu > --- > fs/erofs/fscache.c | 94 +++++++++++++++++++++++++++++++++++++++++++++ > fs/erofs/inode.c | 6 ++- > fs/erofs/internal.h | 1 + > 3 files changed, 100 insertions(+), 1 deletion(-) > > diff --git a/fs/erofs/fscache.c b/fs/erofs/fscache.c > index 654414aa87ad..df56562f33c4 100644 > --- a/fs/erofs/fscache.c > +++ b/fs/erofs/fscache.c > @@ -4,6 +4,12 @@ > */ > #include "internal.h" > > +struct erofs_fscache_map { > + struct erofs_fscache_context *m_ctx; > + erofs_off_t m_pa, m_la, o_la; > + u64 m_llen; Can we directly use "struct erofs_map_blocks map"? So "erofs_fscache_get_map" can be avoided then. Thanks, Gao Xiang