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
3ed97d63
Commit
3ed97d63
authored
Apr 26, 2016
by
Ilya Dryomov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libceph: make ceph_osdc_put_request() accept NULL
Signed-off-by:
Ilya Dryomov
<
idryomov@gmail.com
>
parent
663ae2cc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
9 deletions
+8
-9
fs/ceph/addr.c
fs/ceph/addr.c
+3
-6
net/ceph/osd_client.c
net/ceph/osd_client.c
+5
-3
No files found.
fs/ceph/addr.c
View file @
3ed97d63
...
...
@@ -1099,8 +1099,7 @@ static int ceph_writepages_start(struct address_space *mapping,
mapping
->
writeback_index
=
index
;
out:
if
(
req
)
ceph_osdc_put_request
(
req
);
ceph_osdc_put_request
(
req
);
ceph_put_snap_context
(
snapc
);
dout
(
"writepages done, rc = %d
\n
"
,
rc
);
return
rc
;
...
...
@@ -1824,10 +1823,8 @@ static int __ceph_pool_perm_get(struct ceph_inode_info *ci, u32 pool)
out_unlock:
up_write
(
&
mdsc
->
pool_perm_rwsem
);
if
(
rd_req
)
ceph_osdc_put_request
(
rd_req
);
if
(
wr_req
)
ceph_osdc_put_request
(
wr_req
);
ceph_osdc_put_request
(
rd_req
);
ceph_osdc_put_request
(
wr_req
);
out:
if
(
!
err
)
err
=
have
;
...
...
net/ceph/osd_client.c
View file @
3ed97d63
...
...
@@ -354,9 +354,11 @@ EXPORT_SYMBOL(ceph_osdc_get_request);
void
ceph_osdc_put_request
(
struct
ceph_osd_request
*
req
)
{
dout
(
"%s %p (was %d)
\n
"
,
__func__
,
req
,
atomic_read
(
&
req
->
r_kref
.
refcount
));
kref_put
(
&
req
->
r_kref
,
ceph_osdc_release_request
);
if
(
req
)
{
dout
(
"%s %p (was %d)
\n
"
,
__func__
,
req
,
atomic_read
(
&
req
->
r_kref
.
refcount
));
kref_put
(
&
req
->
r_kref
,
ceph_osdc_release_request
);
}
}
EXPORT_SYMBOL
(
ceph_osdc_put_request
);
...
...
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