Re: [PATCH] ceph: make sure all the files successfully put before unmounting

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 01, 2022 at 11:18:33AM -0800, Eric Biggers wrote:
> On Thu, Dec 01, 2022 at 02:58:00PM +0800, xiubli@xxxxxxxxxx wrote:
> > From: Xiubo Li <xiubli@xxxxxxxxxx>
> > 
> > When close a file it will be deferred to call the fput(), which
> > will hold the inode's i_count. And when unmounting the mountpoint
> > the evict_inodes() may skip evicting some inodes.
> > 
> > If encrypt is enabled the kernel generate a warning when removing
> > the encrypt keys when the skipped inodes still hold the keyring:
> 
> This does not make sense.  Unmounting is only possible once all the files on the
> filesystem have been closed.
> 

Specifically, __fput() puts the reference to the dentry (and thus the inode)
*before* it puts the reference to the mount.  And an unmount cannot be done
while the mount still has references.  So there should not be any issue here.

- Eric



[Index of Archives]     [linux Cryptography]     [Asterisk App Development]     [PJ SIP]     [Gnu Gatekeeper]     [IETF Sipping]     [Info Cyrus]     [ALSA User]     [Fedora Linux Users]     [Linux SCTP]     [DCCP]     [Gimp]     [Yosemite News]     [Deep Creek Hot Springs]     [Yosemite Campsites]     [ISDN Cause Codes]

  Powered by Linux