[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YjiAVezd5B9auhcP@casper.infradead.org>
Date: Mon, 21 Mar 2022 13:40:37 +0000
From: Matthew Wilcox <willy@...radead.org>
To: Jeffle Xu <jefflexu@...ux.alibaba.com>
Cc: dhowells@...hat.com, linux-cachefs@...hat.com, xiang@...nel.org,
chao@...nel.org, linux-erofs@...ts.ozlabs.org,
torvalds@...ux-foundation.org, gregkh@...uxfoundation.org,
linux-fsdevel@...r.kernel.org, joseph.qi@...ux.alibaba.com,
bo.liu@...ux.alibaba.com, tao.peng@...ux.alibaba.com,
gerry@...ux.alibaba.com, eguan@...ux.alibaba.com,
linux-kernel@...r.kernel.org, luodaowen.backend@...edance.com
Subject: Re: [PATCH v5 03/22] cachefiles: introduce on-demand read mode
On Wed, Mar 16, 2022 at 09:17:04PM +0800, Jeffle Xu wrote:
> +#ifdef CONFIG_CACHEFILES_ONDEMAND
> + struct xarray reqs; /* xarray of pending on-demand requests */
> + rwlock_t reqs_lock; /* Lock for reqs xarray */
Why do you have a separate rwlock when the xarray already has its own
spinlock? This is usually a really bad idea.
Powered by blists - more mailing lists