linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Pali Rohár" <pali.rohar@gmail.com>
To: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>,
	linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org
Subject: Changing FAT label of mounted file system
Date: Tue, 5 Sep 2017 16:14:58 +0200	[thread overview]
Message-ID: <201709051614.58774@pali> (raw)

[-- Attachment #1: Type: Text/Plain, Size: 1408 bytes --]

Hello!

On most file system it is possible to change its label at anytime, when 
mounted or unmounted. But FAT is such special file system on which is 
label stored in two location, plus one is in directory structure (which 
cannot be modified when file system is mounted).

I would like to ask what about providing FAT specific IOCTL for vfat 
kernel driver which would allow to change volume label?

Currently vfat provides FAT_IOCTL_GET_VOLUME_ID which returns volume 
serial number, so in similar way it could be extended to provide 
FAT_IOCTL_GET_VOLUME_LABEL and FAT_IOCTL_SET_VOLUME_LABEL.

Now when partition manager program wants to change label of FAT 
partition, it first needs to unmount it, then change label and after 
that mount it again. Providing IOCTL would help partition manager 
programs to implement operation for changing volume label easier. Also 
unmounting partition is now always possible (when busy).

Next typical usage is opening file manager and in its window "renaming" 
volume label. Currently such thing is not possible to implement (without 
hacks) for FAT as once file manager has opened location of FAT partition 
it needs to be mounted -- and changing volume label is not possible.

Other file systems do not have this problem as label is not stored in 
directory structure, managed by kernel driver.

-- 
Pali Rohár
pali.rohar@gmail.com

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

             reply	other threads:[~2017-09-05 14:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-05 14:14 Pali Rohár [this message]
2017-09-05 15:35 ` Changing FAT label of mounted file system OGAWA Hirofumi
2017-10-30 15:35   ` Pali Rohár

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201709051614.58774@pali \
    --to=pali.rohar@gmail.com \
    --cc=hirofumi@mail.parknet.co.jp \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).