From: adilger Date: Wed, 11 May 2005 18:28:46 +0000 (+0000) Subject: Branch b1_4 X-Git-Tag: v1_7_100~1^25~8^2~136 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=553feee7bf0492aab15658d2cc86a730954a1b83;p=fs%2Flustre-release.git Branch b1_4 Pass OBD_BRW_WRITE to filter_alloc_iobuf() from preprw_write(). This parameter is actually unused at this time, so no real effect. b=6289 r=fergal (original change) --- diff --git a/lustre/obdfilter/filter_io.c b/lustre/obdfilter/filter_io.c index baa8173..bc37000 100644 --- a/lustre/obdfilter/filter_io.c +++ b/lustre/obdfilter/filter_io.c @@ -318,7 +318,7 @@ static int filter_preprw_read(int cmd, struct obd_export *exp, struct obdo *oa, fsfilt_check_slow(now, obd_timeout, "preprw_read setup"); - for (i = 0, lnb = res, rnb = nb; i < obj->ioo_bufcnt; + for (i = 0, lnb = res, rnb = nb; i < obj->ioo_bufcnt; i++, rnb++, lnb++) { lnb->dentry = dentry; lnb->offset = rnb->offset; @@ -327,8 +327,8 @@ static int filter_preprw_read(int cmd, struct obd_export *exp, struct obdo *oa, if (inode->i_size <= rnb->offset) /* If there's no more data, abort early. - * lnb->page == NULL and lnb->rc == 0, so it's - * easy to detect later. */ + * lnb->page == NULL and lnb->rc == 0, so it's + * easy to detect later. */ break; else rc = filter_alloc_dio_page(obd, inode, lnb); @@ -527,7 +527,7 @@ static int filter_preprw_write(int cmd, struct obd_export *exp, struct obdo *oa, memset(res, 0, niocount * sizeof(*res)); - rc = filter_alloc_iobuf(&exp->exp_obd->u.filter, OBD_BRW_READ, + rc = filter_alloc_iobuf(&exp->exp_obd->u.filter, OBD_BRW_WRITE, obj->ioo_bufcnt, &iobuf); if (rc) GOTO(cleanup, rc);