[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20211010123639.ubjvilz5fe3nlmau@pali>
Date: Sun, 10 Oct 2021 14:36:39 +0200
From: Pali Rohár <pali@...nel.org>
To: Martin Kepplinger <martink@...teo.de>
Cc: OGAWA Hirofumi <hirofumi@...l.parknet.co.jp>, angus@...ea.ca,
linux-kernel@...r.kernel.org, kay.sievers@...y.org,
lennart@...ttering.net, gregkh@...uxfoundation.org, david@...ar.dk,
tytso@....edu, alan@...rguk.ukuu.org.uk, akpm@...ux-foundation.org
Subject: Re: [PATCH] fs: fat: Make the volume label writable when mounted
On Sunday 10 October 2021 14:18:16 Pali Rohár wrote:
> Hello!
>
> On Sunday 10 October 2021 21:06:52 OGAWA Hirofumi wrote:
> > > diff --git a/include/uapi/linux/msdos_fs.h b/include/uapi/linux/msdos_fs.h
> > > index a5773899f4d9..b666bca09238 100644
> > > --- a/include/uapi/linux/msdos_fs.h
> > > +++ b/include/uapi/linux/msdos_fs.h
> > > @@ -104,6 +104,7 @@ struct __fat_dirent {
> > > #define FAT_IOCTL_SET_ATTRIBUTES _IOW('r', 0x11, __u32)
> > > /*Android kernel has used 0x12, so we use 0x13*/
> > > #define FAT_IOCTL_GET_VOLUME_ID _IOR('r', 0x13, __u32)
> > > +#define VFAT_IOCTL_SET_LABEL _IOW('r', 0x14, __u32)
> >
> > maybe FAT_IOCTL_SET_LABEL is better.
>
> Please do not introduce a new fs specific ioctls. There is already
> vfs-agnostic FS_IOC_SETFSLABEL ioctl, look at manpage:
> https://man7.org/linux/man-pages/man2/ioctl_fslabel.2.html
>
> I have WIP patches which adds support for FS_IOC_SETFSLABEL ioctl into
> kernel vfat driver. But it is not possible to implement this ioctl
> properly until issues with encoding are fixed in vfat driver. Some of
> dependency patches I have sent to ML as RFC series:
> https://lore.kernel.org/lkml/20210808162453.1653-1-pali@kernel.org/
Also look at important details about encoding in discussion:
https://lore.kernel.org/lkml/20200107231522.GC472641@magnolia/
> If you have a time and motivation, I can send you my unfinished WIP
> patches which implements FS_IOC_SETFSLABEL ioctl for vfat.
Powered by blists - more mailing lists