Commit 77079dbe authored by Roel Kluin's avatar Roel Kluin Committed by Linus Torvalds
Browse files

alpha: PTR_ERR overwrites -EINVAL in syscall osf_mount

The initial -EINVAL value is overwritten by `retval = PTR_ERR(name)'.  If
this isn't an error pointer and typenr is not 1, 6 or 9, then this retval,
a pointer cast to a long, is returned.
Signed-off-by: default avatarRoel Kluin <>
Acked-by: default avatarRichard Henderson <>
Cc: Ivan Kokshaysky <>
Cc: Matt Turner <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 68221908
......@@ -361,7 +361,7 @@ osf_procfs_mount(char *dirname, struct procfs_args __user *args, int flags)
SYSCALL_DEFINE4(osf_mount, unsigned long, typenr, char __user *, path,
int, flag, void __user *, data)
int retval = -EINVAL;
int retval;
char *name;
name = getname(path);
......@@ -379,6 +379,7 @@ SYSCALL_DEFINE4(osf_mount, unsigned long, typenr, char __user *, path,
retval = osf_procfs_mount(name, data, flag);
retval = -EINVAL;
printk("osf_mount(%ld, %x)\n", typenr, flag);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment