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
f987f4c2
Commit
f987f4c2
authored
Dec 30, 2015
by
Mike Marshall
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Orangefs: don't trigger copy_attributes_to_inode from d_revalidate.
Signed-off-by:
Mike Marshall
<
hubcap@omnibond.com
>
parent
4f20854b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
36 deletions
+14
-36
fs/orangefs/dcache.c
fs/orangefs/dcache.c
+14
-36
No files found.
fs/orangefs/dcache.c
View file @
f987f4c2
...
...
@@ -77,7 +77,7 @@ static int orangefs_revalidate_lookup(struct dentry *dentry)
/*
* Verify that dentry is valid.
*
* Should return 1 if dentry can still be trusted, else 0
* Should return 1 if dentry can still be trusted, else 0
.
*/
static
int
orangefs_d_revalidate
(
struct
dentry
*
dentry
,
unsigned
int
flags
)
{
...
...
@@ -92,49 +92,27 @@ static int orangefs_d_revalidate(struct dentry *dentry, unsigned int flags)
/* find inode from dentry */
if
(
!
dentry
->
d_inode
)
{
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: negative dentry.
\n
"
,
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: negative dentry.
\n
"
,
__func__
);
goto
invalid_exi
t
;
goto
ou
t
;
}
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: inode valid.
\n
"
,
__func__
);
inode
=
dentry
->
d_inode
;
/*
* first perform a lookup to make sure that the object not only
* exists, but is still in the expected place in the name space
*/
if
(
!
is_root_handle
(
inode
))
{
if
(
!
orangefs_revalidate_lookup
(
dentry
))
goto
invalid_exit
;
}
else
{
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: root handle, lookup skipped.
\n
"
,
__func__
);
/* skip root handle lookups. */
if
(
is_root_handle
(
inode
))
{
ret
=
1
;
goto
out
;
}
/* now perform getattr */
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: doing getattr: inode: %p, handle: %pU
\n
"
,
__func__
,
inode
,
get_khandle_from_ino
(
inode
));
ret
=
orangefs_inode_getattr
(
inode
,
ORANGEFS_ATTR_SYS_ALL_NOHINT
);
gossip_debug
(
GOSSIP_DCACHE_DEBUG
,
"%s: getattr %s (ret = %d), returning %s for dentry i_count=%d
\n
"
,
__func__
,
(
ret
==
0
?
"succeeded"
:
"failed"
),
ret
,
(
ret
==
0
?
"valid"
:
"INVALID"
),
atomic_read
(
&
inode
->
i_count
));
if
(
ret
!=
0
)
goto
invalid_exit
;
/* dentry is valid! */
return
1
;
invalid_exit:
return
0
;
/* lookup the object. */
if
(
orangefs_revalidate_lookup
(
dentry
))
ret
=
1
;
out:
return
ret
;
}
const
struct
dentry_operations
orangefs_dentry_operations
=
{
...
...
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