All of lore.kernel.org
 help / color / mirror / Atom feed
* mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods
@ 2019-03-14  7:20 Murphy Zhou
  2019-03-14 10:58 ` Karel Zak
  2019-03-18  4:56 ` Murphy Zhou
  0 siblings, 2 replies; 3+ messages in thread
From: Murphy Zhou @ 2019-03-14  7:20 UTC (permalink / raw)
  To: Linux-Fsdevel

Hi,

Since this
commit f3a09c92018a91ad0981146a4ac59414f814d801 Author: Al Viro
<viro@zeniv.linux.org.uk>
Date:   Sun Dec 23 18:55:56 2018 -0500

    introduce fs_context methods

    Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>


LTP[1] mount02 tests #5 starts to fail.

This testcase is calling mount(2) with a  NULL fs type. It's expecting
EINVAL to PASS but now we are getting ENOENT.

Should I fix the testcase or there is some work in the kernel ? I'm
wring this email to confirm with you guys.

Thanks,
M
[1] https://github.com/linux-test-project/ltp/blob/master/testcases/kernel/syscalls/mount/mount02.c

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods
  2019-03-14  7:20 mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods Murphy Zhou
@ 2019-03-14 10:58 ` Karel Zak
  2019-03-18  4:56 ` Murphy Zhou
  1 sibling, 0 replies; 3+ messages in thread
From: Karel Zak @ 2019-03-14 10:58 UTC (permalink / raw)
  To: Murphy Zhou; +Cc: Linux-Fsdevel

On Thu, Mar 14, 2019 at 03:20:05PM +0800, Murphy Zhou wrote:
> Hi,
> 
> Since this
> commit f3a09c92018a91ad0981146a4ac59414f814d801 Author: Al Viro
> <viro@zeniv.linux.org.uk>
> Date:   Sun Dec 23 18:55:56 2018 -0500
> 
>     introduce fs_context methods
> 
>     Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
> 
> 
> LTP[1] mount02 tests #5 starts to fail.
> 
> This testcase is calling mount(2) with a  NULL fs type. It's expecting
> EINVAL to PASS but now we are getting ENOENT.
> 
> Should I fix the testcase or there is some work in the kernel ? I'm
> wring this email to confirm with you guys.

It's necessary to fix kernel, because userspace error messages are
generated by error codes. 

   EINVAL means message "wrong fs type, bad option, bad..."
   ENOENT means message "mount(2) system call failed: %m"

 Karel


-- 
 Karel Zak  <kzak@redhat.com>
 http://karelzak.blogspot.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods
  2019-03-14  7:20 mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods Murphy Zhou
  2019-03-14 10:58 ` Karel Zak
@ 2019-03-18  4:56 ` Murphy Zhou
  1 sibling, 0 replies; 3+ messages in thread
From: Murphy Zhou @ 2019-03-18  4:56 UTC (permalink / raw)
  To: Linux-Fsdevel

FIX: It's calling mount(2) with a NULL device name.

On Thu, Mar 14, 2019 at 3:20 PM Murphy Zhou <jencce.kernel@gmail.com> wrote:
>
> Hi,
>
> Since this
> commit f3a09c92018a91ad0981146a4ac59414f814d801 Author: Al Viro
> <viro@zeniv.linux.org.uk>
> Date:   Sun Dec 23 18:55:56 2018 -0500
>
>     introduce fs_context methods
>
>     Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
>
>
> LTP[1] mount02 tests #5 starts to fail.
>
> This testcase is calling mount(2) with a  NULL fs type. It's expecting
> EINVAL to PASS but now we are getting ENOENT.
>
> Should I fix the testcase or there is some work in the kernel ? I'm
> wring this email to confirm with you guys.
>
> Thanks,
> M
> [1] https://github.com/linux-test-project/ltp/blob/master/testcases/kernel/syscalls/mount/mount02.c

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-03-18  4:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-14  7:20 mount(2) with NULL fstype returns ENOENT instead of EINVAL after introducing fs_context methods Murphy Zhou
2019-03-14 10:58 ` Karel Zak
2019-03-18  4:56 ` Murphy Zhou

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.