lkml.org 
[lkml]   [2015]   [Jul]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [f2fs-dev] [PATCH 12/12] f2fs: use extent_cache by default
Date
Hi Jaegeuk,

> -----Original Message-----
> From: Jaegeuk Kim [mailto:jaegeuk@kernel.org]
> Sent: Saturday, July 04, 2015 1:16 PM
> To: Chao Yu
> Cc: linux-fsdevel@vger.kernel.org; linux-kernel@vger.kernel.org;
> linux-f2fs-devel@lists.sourceforge.net
> Subject: Re: [f2fs-dev] [PATCH 12/12] f2fs: use extent_cache by default

[snip]

> > > @@ -237,10 +237,11 @@ void update_inode(struct inode *inode, struct page *node_page)
> > > ri->i_size = cpu_to_le64(i_size_read(inode));
> > > ri->i_blocks = cpu_to_le64(inode->i_blocks);
> > >
> > > - read_lock(&F2FS_I(inode)->ext_lock);
> > > - set_raw_extent(&F2FS_I(inode)->ext, &ri->i_ext);
> > > - read_unlock(&F2FS_I(inode)->ext_lock);
> > > -
> > > + if (F2FS_I(inode)->extent_tree)
> >
> > Could extent cache destroy after above check?
>
> I don't think so.
>
> The extent_tree is assigned as one way.
> Once it is assigned, it will be deallocated only after evict_inode.

Previously, I suspected that ->write_inode and ->evict will be executed
concurrently.

After checking the code, I find that would not happen, so we are safe.

Thanks,

>
> Thanks,
>
> >
> > Thanks,



\
 
 \ /
  Last update: 2015-07-04 08:41    [W:0.066 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site