mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
Switch may_open() and break_lease() to passing O_...
... instead of mixing FMODE_ and O_ Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
d208bbdda9
commit
8737c9305b
8 changed files with 18 additions and 21 deletions
|
|
@ -36,10 +36,9 @@ static struct file *do_open(char *name, int flags)
|
|||
return ERR_PTR(error);
|
||||
|
||||
if (flags == O_RDWR)
|
||||
error = may_open(&nd.path, MAY_READ|MAY_WRITE,
|
||||
FMODE_READ|FMODE_WRITE);
|
||||
error = may_open(&nd.path, MAY_READ|MAY_WRITE, flags);
|
||||
else
|
||||
error = may_open(&nd.path, MAY_WRITE, FMODE_WRITE);
|
||||
error = may_open(&nd.path, MAY_WRITE, flags);
|
||||
|
||||
if (!error)
|
||||
return dentry_open(nd.path.dentry, nd.path.mnt, flags,
|
||||
|
|
|
|||
Loading…
Reference in a new issue