Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d95fa14
)
Branch:HEAD
author
wangdi
<wangdi>
Thu, 19 Apr 2007 09:33:17 +0000
(09:33 +0000)
committer
wangdi
<wangdi>
Thu, 19 Apr 2007 09:33:17 +0000
(09:33 +0000)
b:11662
Fix grant leak that caused OST crashes.
r:adilger
r:green
lustre/osc/osc_request.c
patch
|
blob
|
history
diff --git
a/lustre/osc/osc_request.c
b/lustre/osc/osc_request.c
index
dca0fd9
..
dacd3f3
100644
(file)
--- a/
lustre/osc/osc_request.c
+++ b/
lustre/osc/osc_request.c
@@
-1312,7
+1312,8
@@
static int async_internal(int cmd, struct obd_export *exp, struct obdo *oa,
* otherwise we may run out of space on OST due to grant. */
spin_lock(&cli->cl_loi_list_lock);
for (i = 0; i < page_count; i++) {
- if (cli->cl_avail_grant >= CFS_PAGE_SIZE)
+ if (cli->cl_avail_grant >= CFS_PAGE_SIZE &&
+ cmd == OBD_BRW_WRITE)
osc_consume_write_grant(cli, pga[i]);
}
spin_unlock(&cli->cl_loi_list_lock);