Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Don't leak lov_lock at lov_add_target
[fs/lustre-release.git]
/
lustre
/
lov
/
lov_io.c
diff --git
a/lustre/lov/lov_io.c
b/lustre/lov/lov_io.c
index
346a992
..
f3d8893
100644
(file)
--- a/
lustre/lov/lov_io.c
+++ b/
lustre/lov/lov_io.c
@@
-185,6
+185,7
@@
static int lov_io_sub_init(const struct lu_env *env, struct lov_io *lio,
sub_io->ci_parent = io;
sub_io->ci_lockreq = io->ci_lockreq;
sub_io->ci_type = io->ci_type;
sub_io->ci_parent = io;
sub_io->ci_lockreq = io->ci_lockreq;
sub_io->ci_type = io->ci_type;
+ sub_io->ci_no_srvlock = io->ci_no_srvlock;
lov_sub_enter(sub);
result = cl_io_sub_init(sub->sub_env, sub_io,
lov_sub_enter(sub);
result = cl_io_sub_init(sub->sub_env, sub_io,
@@
-201,8
+202,8
@@
static int lov_io_sub_init(const struct lu_env *env, struct lov_io *lio,
RETURN(result);
}
RETURN(result);
}
-st
atic st
ruct lov_io_sub *lov_sub_get(const struct lu_env *env,
-
struct lov_io *lio, int stripe)
+struct lov_io_sub *lov_sub_get(const struct lu_env *env,
+ struct lov_io *lio, int stripe)
{
int rc;
struct lov_io_sub *sub = &lio->lis_subs[stripe];
{
int rc;
struct lov_io_sub *sub = &lio->lis_subs[stripe];
@@
-391,6
+392,7
@@
static int lov_io_iter_init(const struct lu_env *env,
stripe, start, end);
} else
rc = PTR_ERR(sub);
stripe, start, end);
} else
rc = PTR_ERR(sub);
+
if (!rc)
list_add_tail(&sub->sub_linkage, &lio->lis_active);
else
if (!rc)
list_add_tail(&sub->sub_linkage, &lio->lis_active);
else
@@
-550,7
+552,8
@@
static struct cl_page_list *lov_io_submit_qin(struct lov_device *ld,
*/
static int lov_io_submit(const struct lu_env *env,
const struct cl_io_slice *ios,
*/
static int lov_io_submit(const struct lu_env *env,
const struct cl_io_slice *ios,
- enum cl_req_type crt, struct cl_2queue *queue)
+ enum cl_req_type crt, struct cl_2queue *queue,
+ enum cl_req_priority priority)
{
struct lov_io *lio = cl2lov_io(env, ios);
struct lov_object *obj = lio->lis_object;
{
struct lov_io *lio = cl2lov_io(env, ios);
struct lov_object *obj = lio->lis_object;
@@
-580,7
+583,8
@@
static int lov_io_submit(const struct lu_env *env,
sub = lov_sub_get(env, lio, idx);
LASSERT(!IS_ERR(sub));
LASSERT(sub->sub_io == &lio->lis_single_subio);
sub = lov_sub_get(env, lio, idx);
LASSERT(!IS_ERR(sub));
LASSERT(sub->sub_io == &lio->lis_single_subio);
- rc = cl_io_submit_rw(sub->sub_env, sub->sub_io, crt, queue);
+ rc = cl_io_submit_rw(sub->sub_env, sub->sub_io,
+ crt, queue, priority);
lov_sub_put(sub);
RETURN(rc);
}
lov_sub_put(sub);
RETURN(rc);
}
@@
-621,7
+625,7
@@
static int lov_io_submit(const struct lu_env *env,
sub = lov_sub_get(env, lio, stripe);
if (!IS_ERR(sub)) {
rc = cl_io_submit_rw(sub->sub_env, sub->sub_io,
sub = lov_sub_get(env, lio, stripe);
if (!IS_ERR(sub)) {
rc = cl_io_submit_rw(sub->sub_env, sub->sub_io,
- crt, cl2q);
+ crt, cl2q
, priority
);
lov_sub_put(sub);
} else
rc = PTR_ERR(sub);
lov_sub_put(sub);
} else
rc = PTR_ERR(sub);