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
df64c082
Commit
df64c082
authored
May 02, 2015
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
freevxfs: switch to simple_follow_link()
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
ad476fed
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
39 deletions
+5
-39
fs/freevxfs/vxfs_extern.h
fs/freevxfs/vxfs_extern.h
+0
-3
fs/freevxfs/vxfs_immed.c
fs/freevxfs/vxfs_immed.c
+0
-34
fs/freevxfs/vxfs_inode.c
fs/freevxfs/vxfs_inode.c
+5
-2
No files found.
fs/freevxfs/vxfs_extern.h
View file @
df64c082
...
...
@@ -50,9 +50,6 @@ extern daddr_t vxfs_bmap1(struct inode *, long);
/* vxfs_fshead.c */
extern
int
vxfs_read_fshead
(
struct
super_block
*
);
/* vxfs_immed.c */
extern
const
struct
inode_operations
vxfs_immed_symlink_iops
;
/* vxfs_inode.c */
extern
const
struct
address_space_operations
vxfs_immed_aops
;
extern
struct
kmem_cache
*
vxfs_inode_cachep
;
...
...
fs/freevxfs/vxfs_immed.c
View file @
df64c082
...
...
@@ -32,28 +32,14 @@
*/
#include <linux/fs.h>
#include <linux/pagemap.h>
#include <linux/namei.h>
#include "vxfs.h"
#include "vxfs_extern.h"
#include "vxfs_inode.h"
static
void
*
vxfs_immed_follow_link
(
struct
dentry
*
,
struct
nameidata
*
);
static
int
vxfs_immed_readpage
(
struct
file
*
,
struct
page
*
);
/*
* Inode operations for immed symlinks.
*
* Unliked all other operations we do not go through the pagecache,
* but do all work directly on the inode.
*/
const
struct
inode_operations
vxfs_immed_symlink_iops
=
{
.
readlink
=
generic_readlink
,
.
follow_link
=
vxfs_immed_follow_link
,
};
/*
* Address space operations for immed files and directories.
*/
...
...
@@ -61,26 +47,6 @@ const struct address_space_operations vxfs_immed_aops = {
.
readpage
=
vxfs_immed_readpage
,
};
/**
* vxfs_immed_follow_link - follow immed symlink
* @dp: dentry for the link
* @np: pathname lookup data for the current path walk
*
* Description:
* vxfs_immed_follow_link restarts the pathname lookup with
* the data obtained from @dp.
*
* Returns:
* Zero on success, else a negative error code.
*/
static
void
*
vxfs_immed_follow_link
(
struct
dentry
*
dp
,
struct
nameidata
*
np
)
{
struct
vxfs_inode_info
*
vip
=
VXFS_INO
(
d_inode
(
dp
));
nd_set_link
(
np
,
vip
->
vii_immed
.
vi_immed
);
return
NULL
;
}
/**
* vxfs_immed_readpage - read part of an immed inode into pagecache
* @file: file context (unused)
...
...
fs/freevxfs/vxfs_inode.c
View file @
df64c082
...
...
@@ -35,6 +35,7 @@
#include <linux/pagemap.h>
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/namei.h>
#include "vxfs.h"
#include "vxfs_inode.h"
...
...
@@ -327,8 +328,10 @@ vxfs_iget(struct super_block *sbp, ino_t ino)
ip
->
i_op
=
&
page_symlink_inode_operations
;
ip
->
i_mapping
->
a_ops
=
&
vxfs_aops
;
}
else
{
ip
->
i_op
=
&
vxfs_immed_symlink_iops
;
vip
->
vii_immed
.
vi_immed
[
ip
->
i_size
]
=
'\0'
;
ip
->
i_op
=
&
simple_symlink_inode_operations
;
ip
->
i_link
=
vip
->
vii_immed
.
vi_immed
;
nd_terminate_link
(
ip
->
i_link
,
ip
->
i_size
,
sizeof
(
vip
->
vii_immed
.
vi_immed
)
-
1
);
}
}
else
init_special_inode
(
ip
,
ip
->
i_mode
,
old_decode_dev
(
vip
->
vii_rdev
));
...
...
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