Date: Sun, 22 Jan 2012 14:49:36 +0200 From: Mikolaj Golub <trociny@freebsd.org> To: Jaakko Heinonen <jh@FreeBSD.org> Cc: svn-src-head@freebsd.org, Kevin Lo <kevlo@FreeBSD.org>, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r230252 - head/sys/fs/tmpfs Message-ID: <86obtvvr4v.fsf@kopusha.home.net> In-Reply-To: <20120117171031.GA2316@a91-153-116-96.elisa-laajakaista.fi> (Jaakko Heinonen's message of "Tue, 17 Jan 2012 19:10:31 %2B0200") References: <201201170125.q0H1PrlJ061058@svn.freebsd.org> <20120117171031.GA2316@a91-153-116-96.elisa-laajakaista.fi>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 17 Jan 2012 19:10:31 +0200 Jaakko Heinonen wrote: JH> On 2012-01-17, Kevin Lo wrote: >> Return EOPNOTSUPP since we only support update mounts for NFS export. >> >> @@ -150,8 +150,12 @@ tmpfs_mount(struct mount *mp) >> return (EINVAL); >> >> if (mp->mnt_flag & MNT_UPDATE) { >> + /* >> + * Only support update mounts for NFS export. >> + */ >> if (vfs_flagopt(mp->mnt_optnew, "export", NULL, 0)) >> return (0); >> + return (EOPNOTSUPP); >> } JH> This doesn't look correct. As long as the option list includes the JH> "export" option, all options are accepted. An example: JH> # mount -u -o ro /mnt JH> mount: tmpfs : Operation not supported JH> # mount -u -o ro,export /mnt JH> # There is no error but ro is still ignored, so this is only the issue with reporting. Note, the code for nullfs (as an example) looks the same. It could be fixed with vfs_filteropt(9), not sure if this is worth doing here though. -- Mikolaj Golub
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86obtvvr4v.fsf>