From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: Re: [PATCH 8/9] btrfs: handle a NULL folio in extent_range_redirty_for_io Date: Wed, 18 Jan 2023 17:42:47 +0100 Message-ID: <20230118164247.GC7584@lst.de> References: <20230118094329.9553-1-hch@lst.de> <20230118094329.9553-9-hch@lst.de> Mime-Version: 1.0 Return-path: Content-Disposition: inline In-Reply-To: List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Matthew Wilcox Cc: Christoph Hellwig , Andrew Morton , Hugh Dickins , linux-afs-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linux-btrfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, cluster-devel-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org, linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org, linux-xfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-nilfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org On Wed, Jan 18, 2023 at 04:08:57PM +0000, Matthew Wilcox wrote: > On Wed, Jan 18, 2023 at 10:43:28AM +0100, Christoph Hellwig wrote: > > filemap_get_folio can return NULL, skip those cases. > > Hmm, I'm not sure that's true. We have one place that calls > extent_range_redirty_for_io(), and it previously calls > extent_range_clear_dirty_for_io() which has an explicit > > BUG_ON(!page); /* Pages should be in the extent_io_tree */ > > so I'm going to say this one can't happen either. I haven't delved far > enough into btrfs to figure out why it can't happen. I'll drop this patch for now.