Re: [PATCH v2 1/6] fs: enhance and rename shutdown() callback to remove_bdev()

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

 





在 2025/7/1 15:44, Christoph Hellwig 写道:
On Tue, Jul 01, 2025 at 03:02:34PM +0930, Qu Wenruo wrote:
To allow those multi-device filesystems to be integrated to use
fs_holder_ops:

- Rename shutdown() call back to remove_bdev()
   To better describe when the call back is called.

What is renamed back here?

Rename the old shutdown to remove_bdev().


-static void exfat_shutdown(struct super_block *sb)
+static void exfat_shutdown(struct super_block *sb, struct block_device *bdev)
  {
  	exfat_force_shutdown(sb, EXFAT_GOING_DOWN_NOSYNC);
  }
@@ -202,7 +202,7 @@ static const struct super_operations exfat_sops = {
  	.put_super	= exfat_put_super,
  	.statfs		= exfat_statfs,
  	.show_options	= exfat_show_options,
-	.shutdown	= exfat_shutdown,
+	.remove_bdev	= exfat_shutdown,

Please also rename the function so that they match the method name.

I prefer not, and it is intentionally left as is.

This give us a very clear view what a fs is expected to do.

If a fs can only shutdown when losing any device, a read won't need to dig into the details, just looking at that line will tell us what is the behavior.

Thanks,
Qu






[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux