[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210819100137.5se3otjz5ngcfswz@kari-VirtualBox>
Date: Thu, 19 Aug 2021 13:01:37 +0300
From: Kari Argillander <kari.argillander@...il.com>
To: Pali Rohár <pali@...nel.org>
Cc: Konstantin Komarov <almaz.alexandrovich@...agon-software.com>,
Christoph Hellwig <hch@....de>, ntfs3@...ts.linux.dev,
linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org,
Matthew Wilcox <willy@...radead.org>,
Christian Brauner <christian.brauner@...ntu.com>
Subject: Re: [PATCH v2 3/6] fs/ntfs3: Use new api for mounting
On Thu, Aug 19, 2021 at 10:18:28AM +0200, Pali Rohár wrote:
> Hello! I have there one comment:
>
> On Thursday 19 August 2021 03:26:30 Kari Argillander wrote:
> > @@ -545,10 +518,8 @@ static int ntfs_show_options(struct seq_file *m, struct dentry *root)
> > seq_printf(m, ",fmask=%04o", ~opts->fs_fmask_inv);
> > if (opts->dmask)
> > seq_printf(m, ",dmask=%04o", ~opts->fs_dmask_inv);
> > - if (opts->nls)
> > - seq_printf(m, ",nls=%s", opts->nls->charset);
> > - else
> > - seq_puts(m, ",nls=utf8");
> > + if (opts->nls_name)
> > + seq_printf(m, ",nls=%s", opts->nls_name);
>
> Please always print correct "nls=". Obviously ntfs driver (which
> internally stores filenames in UTF-16) must always use some conversion
> to null-term bytes. And if some kernel/driver default conversion is used
> then userspace should know it, what exactly is used (e.g. to ensure that
> would use correct encoding name argument of open(), stat()... syscalls).
Thanks. That was actually my intention, but it seems that there is bug
from my part and it will be fixed in v3. Thanks for reviewing.
>
> > if (opts->sys_immutable)
> > seq_puts(m, ",sys_immutable");
> > if (opts->discard)
> > @@ -619,7 +590,6 @@ static const struct super_operations ntfs_sops = {
> > .statfs = ntfs_statfs,
> > .show_options = ntfs_show_options,
> > .sync_fs = ntfs_sync_fs,
> > - .remount_fs = ntfs_remount,
> > .write_inode = ntfs3_write_inode,
> > };
>
Powered by blists - more mailing lists