Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp201020rwi; Fri, 14 Oct 2022 00:13:07 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7CCRUdZgZpkJraQr+kEO/kaKwuVbPQZtaj88hYltTo5gpZL4QnPjTUIIJF1Tr9adV7rIhr X-Received: by 2002:a17:903:1112:b0:178:a030:5f72 with SMTP id n18-20020a170903111200b00178a0305f72mr4076919plh.12.1665731587262; Fri, 14 Oct 2022 00:13:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665731587; cv=none; d=google.com; s=arc-20160816; b=DHlCIIkZlcQMTAbc53hDeZVS5GuCnXt5q76W/rJK4q62lVcigwbP3Rw6B4+HfIsypY MmGEThwDO+IPtyZxW6J5SQqcwtCLXQXPIqomlU8A1poluAFMx9b74VNkCPJQmfDXF5l0 Jqc5+p/y36aeCD4V+gA3xc+biJc2iTz5zzLOAzfLQGtCSWVc1GZLwiY7OU/UP6OKIkyd b2i/MSg1B16kVNjG7H/Ff5jIePD6HARn76IADMjokh0xa6Zz7MDTM2M8FREpNlFbbvDX C7ZI54wkTYJZP7V4f4ZUNp9tZhzOYiopkxdT7bt7rceNK3nl/B65bwa861YGLjAhw6OI BAow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=uaqwNZE8mefgKFTlam8z0WThEpW9uMJM47CeTisDf9Y=; b=w6a8aDJcld631MKACSzFjoa44AiG8qyrxU+8elxZh9s+OXFboDWrJDBAWdWMh+JZRL dP0TnxYtm3omgf9VzKfmDEOixyhqtep+lFbfOxiJt6QAAQry3b4uqT4PpAtngMYs1zhE gsGZYoaYD2h3dnY7X09Q+HGblF9N2n2Vo/7CoK30vSdLMjuwEWPf1d+564urZt0Q0/7d 360v6fwzXp2PxxGpahvl7pEQXQa1Dqef+OxqqhAwhRDEi552S+7oNoQF3bN89XD4QXlF +hMpLZM+bk8CGqd9xbma2op4wmtAKfZ1nN9smi3skEF/S2xiV3TLpcM21Bx6hXMTO6cj Hdyg== 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 n28-20020a635c5c000000b004404705691dsi1977645pgm.487.2022.10.14.00.12.54; Fri, 14 Oct 2022 00:13:07 -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 S229783AbiJNGbt (ORCPT + 99 others); Fri, 14 Oct 2022 02:31:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39946 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229751AbiJNGbr (ORCPT ); Fri, 14 Oct 2022 02:31:47 -0400 Received: from out30-45.freemail.mail.aliyun.com (out30-45.freemail.mail.aliyun.com [115.124.30.45]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B780532B9D; Thu, 13 Oct 2022 23:31:46 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R111e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046051;MF=jefflexu@linux.alibaba.com;NM=1;PH=DS;RN=8;SR=0;TI=SMTPD_---0VS6XyKN_1665729101; Received: from 30.221.130.30(mailfrom:jefflexu@linux.alibaba.com fp:SMTPD_---0VS6XyKN_1665729101) by smtp.aliyun-inc.com; Fri, 14 Oct 2022 14:31:43 +0800 Message-ID: Date: Fri, 14 Oct 2022 14:31:41 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.3.0 Subject: Re: [PATCH V2 1/5] cachefiles: introduce object ondemand state Content-Language: en-US To: Jia Zhu , dhowells@redhat.com, xiang@kernel.org Cc: linux-cachefs@redhat.com, linux-erofs@lists.ozlabs.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, yinxin.x@bytedance.com References: <20221014030745.25748-1-zhujia.zj@bytedance.com> <20221014030745.25748-2-zhujia.zj@bytedance.com> From: JeffleXu In-Reply-To: <20221014030745.25748-2-zhujia.zj@bytedance.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-11.2 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,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 10/14/22 11:07 AM, Jia Zhu wrote: > Previously, @ondemand_id field was used not only to identify ondemand > state of the object, but also to represent the index of the xarray. > This commit introduces @state field to decouple the role of @ondemand_id > and adds helpers to access it. > > Signed-off-by: Jia Zhu > Reviewed-by: Xin Yin > --- > fs/cachefiles/internal.h | 22 ++++++++++++++++++++++ > fs/cachefiles/ondemand.c | 21 +++++++++------------ > 2 files changed, 31 insertions(+), 12 deletions(-) > > diff --git a/fs/cachefiles/internal.h b/fs/cachefiles/internal.h > index 2ad58c465208..39895bbd149a 100644 > --- a/fs/cachefiles/internal.h > +++ b/fs/cachefiles/internal.h > @@ -17,6 +17,7 @@ > #include > #include > #include > +#include ^ This is not needed any more. Otherwise LGTM. Reviewed-by: Jingbo Xu -- Thanks, Jingbo