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
LU-4416 osd-ldiskfs: remove unused 'optional_mutex' argument
[fs/lustre-release.git]
/
lustre
/
osd-ldiskfs
/
osd_io.c
diff --git
a/lustre/osd-ldiskfs/osd_io.c
b/lustre/osd-ldiskfs/osd_io.c
index
1e4e915
..
bbdf111
100644
(file)
--- a/
lustre/osd-ldiskfs/osd_io.c
+++ b/
lustre/osd-ldiskfs/osd_io.c
@@
-819,7
+819,7
@@
int osd_ldiskfs_map_bm_inode_pages(struct inode *inode, struct page **page,
static int osd_ldiskfs_map_inode_pages(struct inode *inode, struct page **page,
int pages, unsigned long *blocks,
static int osd_ldiskfs_map_inode_pages(struct inode *inode, struct page **page,
int pages, unsigned long *blocks,
- int create
, struct mutex *optional_mutex
)
+ int create)
{
int rc;
{
int rc;
@@
-828,11
+828,7
@@
static int osd_ldiskfs_map_inode_pages(struct inode *inode, struct page **page,
blocks, create);
return rc;
}
blocks, create);
return rc;
}
- if (optional_mutex != NULL)
- mutex_lock(optional_mutex);
rc = osd_ldiskfs_map_bm_inode_pages(inode, page, pages, blocks, create);
rc = osd_ldiskfs_map_bm_inode_pages(inode, page, pages, blocks, create);
- if (optional_mutex != NULL)
- mutex_unlock(optional_mutex);
return rc;
}
return rc;
}
@@
-907,8
+903,7
@@
static int osd_write_prep(const struct lu_env *env, struct dt_object *dt,
if (iobuf->dr_npages) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
if (iobuf->dr_npages) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
- iobuf->dr_blocks,
- 0, NULL);
+ iobuf->dr_blocks, 0);
if (likely(rc == 0)) {
rc = osd_do_bio(osd, inode, iobuf);
/* do IO stats for preparation reads */
if (likely(rc == 0)) {
rc = osd_do_bio(osd, inode, iobuf);
/* do IO stats for preparation reads */
@@
-1036,7
+1031,7
@@
static int osd_declare_write_commit(const struct lu_env *env,
/* make sure the over quota flags were not set */
lnb[0].flags &= ~(OBD_BRW_OVER_USRQUOTA | OBD_BRW_OVER_GRPQUOTA);
/* make sure the over quota flags were not set */
lnb[0].flags &= ~(OBD_BRW_OVER_USRQUOTA | OBD_BRW_OVER_GRPQUOTA);
- rc = osd_declare_inode_qid(env, i
node->i_uid, inode->i_gid
,
+ rc = osd_declare_inode_qid(env, i
_uid_read(inode), i_gid_read(inode)
,
quota_space, oh, true, true, &flags,
ignore_quota);
quota_space, oh, true, true, &flags,
ignore_quota);
@@
-1111,8
+1106,7
@@
static int osd_write_commit(const struct lu_env *env, struct dt_object *dt,
} else if (iobuf->dr_npages > 0) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
} else if (iobuf->dr_npages > 0) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
- iobuf->dr_blocks,
- 1, NULL);
+ iobuf->dr_blocks, 1);
} else {
/* no pages to write, no transno is needed */
thandle->th_local = 1;
} else {
/* no pages to write, no transno is needed */
thandle->th_local = 1;
@@
-1201,8
+1195,7
@@
static int osd_read_prep(const struct lu_env *env, struct dt_object *dt,
if (iobuf->dr_npages) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
if (iobuf->dr_npages) {
rc = osd_ldiskfs_map_inode_pages(inode, iobuf->dr_pages,
iobuf->dr_npages,
- iobuf->dr_blocks,
- 0, NULL);
+ iobuf->dr_blocks, 0);
rc = osd_do_bio(osd, inode, iobuf);
/* IO stats will be done in osd_bufs_put() */
rc = osd_do_bio(osd, inode, iobuf);
/* IO stats will be done in osd_bufs_put() */
@@
-1446,8
+1439,9
@@
out:
* as llog or last_rcvd files. We needn't enforce quota on those
* objects, so always set the lqi_space as 0. */
if (inode != NULL)
* as llog or last_rcvd files. We needn't enforce quota on those
* objects, so always set the lqi_space as 0. */
if (inode != NULL)
- rc = osd_declare_inode_qid(env, inode->i_uid, inode->i_gid,
- 0, oh, true, true, NULL, false);
+ rc = osd_declare_inode_qid(env, i_uid_read(inode),
+ i_gid_read(inode), 0, oh, true,
+ true, NULL, false);
RETURN(rc);
}
RETURN(rc);
}
@@
-1611,8
+1605,8
@@
static int osd_declare_punch(const struct lu_env *env, struct dt_object *dt,
inode = osd_dt_obj(dt)->oo_inode;
LASSERT(inode);
inode = osd_dt_obj(dt)->oo_inode;
LASSERT(inode);
- rc = osd_declare_inode_qid(env, i
node->i_uid, inode->i_gid, 0, oh
,
- true, true, NULL, false);
+ rc = osd_declare_inode_qid(env, i
_uid_read(inode), i_gid_read(inode)
,
+
0, oh,
true, true, NULL, false);
RETURN(rc);
}
RETURN(rc);
}