From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C1A99C433F5 for ; Mon, 11 Apr 2022 12:36:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346147AbiDKMib (ORCPT ); Mon, 11 Apr 2022 08:38:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47542 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346138AbiDKMia (ORCPT ); Mon, 11 Apr 2022 08:38:30 -0400 Received: from out30-131.freemail.mail.aliyun.com (out30-131.freemail.mail.aliyun.com [115.124.30.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D38511ADBD; Mon, 11 Apr 2022 05:36:11 -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=e01e04407;MF=jefflexu@linux.alibaba.com;NM=1;PH=DS;RN=18;SR=0;TI=SMTPD_---0V9pPvL2_1649680565; Received: from 30.225.24.83(mailfrom:jefflexu@linux.alibaba.com fp:SMTPD_---0V9pPvL2_1649680565) by smtp.aliyun-inc.com(127.0.0.1); Mon, 11 Apr 2022 20:36:07 +0800 Message-ID: <46dc4929-b52b-474c-1bdb-b3e439f09585@linux.alibaba.com> Date: Mon, 11 Apr 2022 20:36:05 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Subject: Re: [PATCH v8 03/20] cachefiles: notify user daemon with anon_fd when looking up cookie Content-Language: en-US To: David Howells Cc: linux-cachefs@redhat.com, xiang@kernel.org, chao@kernel.org, linux-erofs@lists.ozlabs.org, torvalds@linux-foundation.org, gregkh@linuxfoundation.org, willy@infradead.org, linux-fsdevel@vger.kernel.org, joseph.qi@linux.alibaba.com, bo.liu@linux.alibaba.com, tao.peng@linux.alibaba.com, gerry@linux.alibaba.com, eguan@linux.alibaba.com, linux-kernel@vger.kernel.org, luodaowen.backend@bytedance.com, tianzichen@kuaishou.com, fannaihao@baidu.com References: <20220406075612.60298-4-jefflexu@linux.alibaba.com> <20220406075612.60298-1-jefflexu@linux.alibaba.com> <1091118.1649680137@warthog.procyon.org.uk> From: JeffleXu In-Reply-To: <1091118.1649680137@warthog.procyon.org.uk> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On 4/11/22 8:28 PM, David Howells wrote: > Jeffle Xu wrote: > >> + This permits on-demand read mode of cachefiles. In this mode, when >> + cache miss, the cachefiles backend instead of netfs, is responsible >> + for fetching data, e.g. through user daemon. > > That third line should probably begin with a tab as the other two line do. Oh yeah... > >> +static inline void cachefiles_flush_reqs(struct cachefiles_cache *cache) > > If it's in a .c file, there's no need to mark it "inline". The compiler will > inline it anyway if it decides it should. Okay. > >> +#ifdef CONFIG_CACHEFILES_ONDEMAND >> + cachefiles_flush_reqs(cache); >> + xa_destroy(&cache->reqs); >> +#endif > > If cachefiles_flush_reqs() is only used in this one place, the xa_destroy() > should possibly be moved into it. > Alright. -- Thanks, Jeffle