Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
3eda0de6
Commit
3eda0de6
authored
Jul 26, 2011
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
9p: propagate umode_t
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
587228be
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
14 deletions
+15
-14
fs/9p/v9fs_vfs.h
fs/9p/v9fs_vfs.h
+2
-2
fs/9p/vfs_inode.c
fs/9p/vfs_inode.c
+11
-10
fs/9p/vfs_inode_dotl.c
fs/9p/vfs_inode_dotl.c
+1
-1
fs/9p/vfs_super.c
fs/9p/vfs_super.c
+1
-1
No files found.
fs/9p/v9fs_vfs.h
View file @
3eda0de6
...
@@ -54,9 +54,9 @@ extern struct kmem_cache *v9fs_inode_cache;
...
@@ -54,9 +54,9 @@ extern struct kmem_cache *v9fs_inode_cache;
struct
inode
*
v9fs_alloc_inode
(
struct
super_block
*
sb
);
struct
inode
*
v9fs_alloc_inode
(
struct
super_block
*
sb
);
void
v9fs_destroy_inode
(
struct
inode
*
inode
);
void
v9fs_destroy_inode
(
struct
inode
*
inode
);
struct
inode
*
v9fs_get_inode
(
struct
super_block
*
sb
,
in
t
mode
,
dev_t
);
struct
inode
*
v9fs_get_inode
(
struct
super_block
*
sb
,
umode_
t
mode
,
dev_t
);
int
v9fs_init_inode
(
struct
v9fs_session_info
*
v9ses
,
int
v9fs_init_inode
(
struct
v9fs_session_info
*
v9ses
,
struct
inode
*
inode
,
in
t
mode
,
dev_t
);
struct
inode
*
inode
,
umode_
t
mode
,
dev_t
);
void
v9fs_evict_inode
(
struct
inode
*
inode
);
void
v9fs_evict_inode
(
struct
inode
*
inode
);
ino_t
v9fs_qid2ino
(
struct
p9_qid
*
qid
);
ino_t
v9fs_qid2ino
(
struct
p9_qid
*
qid
);
void
v9fs_stat2inode
(
struct
p9_wstat
*
,
struct
inode
*
,
struct
super_block
*
);
void
v9fs_stat2inode
(
struct
p9_wstat
*
,
struct
inode
*
,
struct
super_block
*
);
...
...
fs/9p/vfs_inode.c
View file @
3eda0de6
...
@@ -59,7 +59,7 @@ static const struct inode_operations v9fs_symlink_inode_operations;
...
@@ -59,7 +59,7 @@ static const struct inode_operations v9fs_symlink_inode_operations;
*
*
*/
*/
static
u32
unixmode2p9mode
(
struct
v9fs_session_info
*
v9ses
,
in
t
mode
)
static
u32
unixmode2p9mode
(
struct
v9fs_session_info
*
v9ses
,
umode_
t
mode
)
{
{
int
res
;
int
res
;
res
=
mode
&
0777
;
res
=
mode
&
0777
;
...
@@ -94,11 +94,11 @@ static u32 unixmode2p9mode(struct v9fs_session_info *v9ses, int mode)
...
@@ -94,11 +94,11 @@ static u32 unixmode2p9mode(struct v9fs_session_info *v9ses, int mode)
* @rdev: major number, minor number in case of device files.
* @rdev: major number, minor number in case of device files.
*
*
*/
*/
static
in
t
p9mode2unixmode
(
struct
v9fs_session_info
*
v9ses
,
static
umode_
t
p9mode2unixmode
(
struct
v9fs_session_info
*
v9ses
,
struct
p9_wstat
*
stat
,
dev_t
*
rdev
)
struct
p9_wstat
*
stat
,
dev_t
*
rdev
)
{
{
int
res
;
int
res
;
int
mode
=
stat
->
mode
;
u32
mode
=
stat
->
mode
;
res
=
mode
&
S_IALLUGO
;
res
=
mode
&
S_IALLUGO
;
*
rdev
=
0
;
*
rdev
=
0
;
...
@@ -255,7 +255,7 @@ void v9fs_destroy_inode(struct inode *inode)
...
@@ -255,7 +255,7 @@ void v9fs_destroy_inode(struct inode *inode)
}
}
int
v9fs_init_inode
(
struct
v9fs_session_info
*
v9ses
,
int
v9fs_init_inode
(
struct
v9fs_session_info
*
v9ses
,
struct
inode
*
inode
,
in
t
mode
,
dev_t
rdev
)
struct
inode
*
inode
,
umode_
t
mode
,
dev_t
rdev
)
{
{
int
err
=
0
;
int
err
=
0
;
...
@@ -329,7 +329,7 @@ int v9fs_init_inode(struct v9fs_session_info *v9ses,
...
@@ -329,7 +329,7 @@ int v9fs_init_inode(struct v9fs_session_info *v9ses,
break
;
break
;
default:
default:
P9_DPRINTK
(
P9_DEBUG_ERROR
,
"BAD mode 0x%x S_IFMT 0x%x
\n
"
,
P9_DPRINTK
(
P9_DEBUG_ERROR
,
"BAD mode 0x%
h
x S_IFMT 0x%x
\n
"
,
mode
,
mode
&
S_IFMT
);
mode
,
mode
&
S_IFMT
);
err
=
-
EINVAL
;
err
=
-
EINVAL
;
goto
error
;
goto
error
;
...
@@ -346,13 +346,13 @@ int v9fs_init_inode(struct v9fs_session_info *v9ses,
...
@@ -346,13 +346,13 @@ int v9fs_init_inode(struct v9fs_session_info *v9ses,
*
*
*/
*/
struct
inode
*
v9fs_get_inode
(
struct
super_block
*
sb
,
in
t
mode
,
dev_t
rdev
)
struct
inode
*
v9fs_get_inode
(
struct
super_block
*
sb
,
umode_
t
mode
,
dev_t
rdev
)
{
{
int
err
;
int
err
;
struct
inode
*
inode
;
struct
inode
*
inode
;
struct
v9fs_session_info
*
v9ses
=
sb
->
s_fs_info
;
struct
v9fs_session_info
*
v9ses
=
sb
->
s_fs_info
;
P9_DPRINTK
(
P9_DEBUG_VFS
,
"super block: %p mode: %o
\n
"
,
sb
,
mode
);
P9_DPRINTK
(
P9_DEBUG_VFS
,
"super block: %p mode: %
h
o
\n
"
,
sb
,
mode
);
inode
=
new_inode
(
sb
);
inode
=
new_inode
(
sb
);
if
(
!
inode
)
{
if
(
!
inode
)
{
...
@@ -486,7 +486,8 @@ static struct inode *v9fs_qid_iget(struct super_block *sb,
...
@@ -486,7 +486,8 @@ static struct inode *v9fs_qid_iget(struct super_block *sb,
int
new
)
int
new
)
{
{
dev_t
rdev
;
dev_t
rdev
;
int
retval
,
umode
;
int
retval
;
umode_t
umode
;
unsigned
long
i_ino
;
unsigned
long
i_ino
;
struct
inode
*
inode
;
struct
inode
*
inode
;
struct
v9fs_session_info
*
v9ses
=
sb
->
s_fs_info
;
struct
v9fs_session_info
*
v9ses
=
sb
->
s_fs_info
;
...
@@ -1125,7 +1126,7 @@ void
...
@@ -1125,7 +1126,7 @@ void
v9fs_stat2inode
(
struct
p9_wstat
*
stat
,
struct
inode
*
inode
,
v9fs_stat2inode
(
struct
p9_wstat
*
stat
,
struct
inode
*
inode
,
struct
super_block
*
sb
)
struct
super_block
*
sb
)
{
{
mode_t
mode
;
u
mode_t
mode
;
char
ext
[
32
];
char
ext
[
32
];
char
tag_name
[
14
];
char
tag_name
[
14
];
unsigned
int
i_nlink
;
unsigned
int
i_nlink
;
...
...
fs/9p/vfs_inode_dotl.c
View file @
3eda0de6
...
@@ -594,7 +594,7 @@ int v9fs_vfs_setattr_dotl(struct dentry *dentry, struct iattr *iattr)
...
@@ -594,7 +594,7 @@ int v9fs_vfs_setattr_dotl(struct dentry *dentry, struct iattr *iattr)
void
void
v9fs_stat2inode_dotl
(
struct
p9_stat_dotl
*
stat
,
struct
inode
*
inode
)
v9fs_stat2inode_dotl
(
struct
p9_stat_dotl
*
stat
,
struct
inode
*
inode
)
{
{
mode_t
mode
;
u
mode_t
mode
;
struct
v9fs_inode
*
v9inode
=
V9FS_I
(
inode
);
struct
v9fs_inode
*
v9inode
=
V9FS_I
(
inode
);
if
((
stat
->
st_result_mask
&
P9_STATS_BASIC
)
==
P9_STATS_BASIC
)
{
if
((
stat
->
st_result_mask
&
P9_STATS_BASIC
)
==
P9_STATS_BASIC
)
{
...
...
fs/9p/vfs_super.c
View file @
3eda0de6
...
@@ -117,7 +117,7 @@ static struct dentry *v9fs_mount(struct file_system_type *fs_type, int flags,
...
@@ -117,7 +117,7 @@ static struct dentry *v9fs_mount(struct file_system_type *fs_type, int flags,
struct
inode
*
inode
=
NULL
;
struct
inode
*
inode
=
NULL
;
struct
dentry
*
root
=
NULL
;
struct
dentry
*
root
=
NULL
;
struct
v9fs_session_info
*
v9ses
=
NULL
;
struct
v9fs_session_info
*
v9ses
=
NULL
;
in
t
mode
=
S_IRWXUGO
|
S_ISVTX
;
umode_
t
mode
=
S_IRWXUGO
|
S_ISVTX
;
struct
p9_fid
*
fid
;
struct
p9_fid
*
fid
;
int
retval
=
0
;
int
retval
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment