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
nexedi
linux
Commits
8e28bc7e
Commit
8e28bc7e
authored
May 22, 2013
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[readdir] convert hostfs
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
1bbae9f8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
7 deletions
+6
-7
fs/hostfs/hostfs_kern.c
fs/hostfs/hostfs_kern.c
+6
-7
No files found.
fs/hostfs/hostfs_kern.c
View file @
8e28bc7e
...
...
@@ -277,7 +277,7 @@ static const struct super_operations hostfs_sbops = {
.
show_options
=
hostfs_show_options
,
};
int
hostfs_readdir
(
struct
file
*
file
,
void
*
ent
,
filldir_t
filldir
)
int
hostfs_readdir
(
struct
file
*
file
,
struct
dir_context
*
ctx
)
{
void
*
dir
;
char
*
name
;
...
...
@@ -292,12 +292,11 @@ int hostfs_readdir(struct file *file, void *ent, filldir_t filldir)
__putname
(
name
);
if
(
dir
==
NULL
)
return
-
error
;
next
=
file
->
f_
pos
;
next
=
ctx
->
pos
;
while
((
name
=
read_dir
(
dir
,
&
next
,
&
ino
,
&
len
,
&
type
))
!=
NULL
)
{
error
=
(
*
filldir
)(
ent
,
name
,
len
,
file
->
f_pos
,
ino
,
type
);
if
(
error
)
break
;
file
->
f_pos
=
next
;
if
(
!
dir_emit
(
ctx
,
name
,
len
,
ino
,
type
))
break
;
ctx
->
pos
=
next
;
}
close_dir
(
dir
);
return
0
;
...
...
@@ -393,7 +392,7 @@ static const struct file_operations hostfs_file_fops = {
static
const
struct
file_operations
hostfs_dir_fops
=
{
.
llseek
=
generic_file_llseek
,
.
readdir
=
hostfs_readdir
,
.
iterate
=
hostfs_readdir
,
.
read
=
generic_read_dir
,
};
...
...
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