summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
267d00f)
in lmv_obd.c:
- Correct wrong coding styles introduced by HSM (and others)
- Remove useless include
Signed-off-by: JC Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Change-Id: I2dd369e94dd351396e4a4deb72d1ec6f19b59b40
Reviewed-on: http://review.whamcloud.com/7252
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
#include <asm/div64.h>
#include <linux/seq_file.h>
#include <linux/namei.h>
#include <asm/div64.h>
#include <linux/seq_file.h>
#include <linux/namei.h>
-#include <asm/uaccess.h>
#else
#include <liblustre.h>
#endif
#else
#include <liblustre.h>
#endif
nr_out = 0;
for (i = 0; i < hur_in->hur_request.hr_itemcount; i++) {
curr_tgt = lmv_find_target(lmv,
nr_out = 0;
for (i = 0; i < hur_in->hur_request.hr_itemcount; i++) {
curr_tgt = lmv_find_target(lmv,
- &hur_in->hur_user_item[i].hui_fid);
+ &hur_in->hur_user_item[i].hui_fid);
if (obd_uuid_equals(&curr_tgt->ltd_uuid, &tgt_mds->ltd_uuid)) {
hur_out->hur_user_item[nr_out] =
if (obd_uuid_equals(&curr_tgt->ltd_uuid, &tgt_mds->ltd_uuid)) {
hur_out->hur_user_item[nr_out] =
- hur_in->hur_user_item[i];
+ hur_in->hur_user_item[i];
if (err) {
if (lmv->tgts[i]->ltd_active) {
/* permanent error */
if (err) {
if (lmv->tgts[i]->ltd_active) {
/* permanent error */
- CERROR("error: iocontrol MDC %s on MDT"
- "idx %d cmd %x: err = %d\n",
- lmv->tgts[i]->ltd_uuid.uuid,
- i, cmd, err);
+ CERROR("%s: iocontrol MDC %s on MDT"
+ " idx %d cmd %x: err = %d\n",
+ class_exp2obd(lmv->exp)->obd_name,
+ lmv->tgts[i]->ltd_uuid.uuid,
+ i, cmd, err);
rc = err;
lk->lk_flags |= LK_FLG_STOP;
/* unregister from previous MDS */
for (j = 0; j < i; j++)
obd_iocontrol(cmd,
rc = err;
lk->lk_flags |= LK_FLG_STOP;
/* unregister from previous MDS */
for (j = 0; j < i; j++)
obd_iocontrol(cmd,
- lmv->tgts[j]->ltd_exp,
- len, lk, uarg);
+ lmv->tgts[j]->ltd_exp,
+ len, lk, uarg);
RETURN(rc);
}
/* else: transient error.
RETURN(rc);
}
/* else: transient error.
/* copy UUID */
if (copy_to_user(data->ioc_pbuf2, obd2cli_tgt(mdc_obd),
/* copy UUID */
if (copy_to_user(data->ioc_pbuf2, obd2cli_tgt(mdc_obd),
- min((int) data->ioc_plen2,
- (int) sizeof(struct obd_uuid))))
+ min((int) data->ioc_plen2,
+ (int) sizeof(struct obd_uuid))))
RETURN(-EFAULT);
rc = obd_statfs(NULL, lmv->tgts[index]->ltd_exp, &stat_buf,
RETURN(-EFAULT);
rc = obd_statfs(NULL, lmv->tgts[index]->ltd_exp, &stat_buf,
if (rc)
RETURN(rc);
if (copy_to_user(data->ioc_pbuf1, &stat_buf,
if (rc)
RETURN(rc);
if (copy_to_user(data->ioc_pbuf1, &stat_buf,
- min((int) data->ioc_plen1,
- (int) sizeof(stat_buf))))
+ min((int) data->ioc_plen1,
+ (int) sizeof(stat_buf))))
RETURN(-EFAULT);
break;
}
RETURN(-EFAULT);
break;
}
tgt = lmv_find_target(lmv, &op_data->op_fid1);
if (IS_ERR(tgt))
tgt = lmv_find_target(lmv, &op_data->op_fid1);
if (IS_ERR(tgt))
if (tgt->ltd_exp == NULL)
if (tgt->ltd_exp == NULL)
rc = obd_iocontrol(cmd, tgt->ltd_exp, len, karg, uarg);
break;
rc = obd_iocontrol(cmd, tgt->ltd_exp, len, karg, uarg);
break;
/* build a request with fids for this MDS */
reqlen = offsetof(typeof(*hur),
hur_user_item[nr])
/* build a request with fids for this MDS */
reqlen = offsetof(typeof(*hur),
hur_user_item[nr])
- + hur->hur_request.hr_data_len;
+ + hur->hur_request.hr_data_len;
OBD_ALLOC_LARGE(req, reqlen);
if (req == NULL)
RETURN(-ENOMEM);
OBD_ALLOC_LARGE(req, reqlen);
if (req == NULL)
RETURN(-ENOMEM);
} else if (err) {
if (lmv->tgts[i]->ltd_active) {
CERROR("error: iocontrol MDC %s on MDT"
} else if (err) {
if (lmv->tgts[i]->ltd_active) {
CERROR("error: iocontrol MDC %s on MDT"
- "idx %d cmd %x: err = %d\n",
- lmv->tgts[i]->ltd_uuid.uuid,
- i, cmd, err);
+ " idx %d cmd %x: err = %d\n",
+ lmv->tgts[i]->ltd_uuid.uuid,
+ i, cmd, err);
lprocfs_obd_setup(obd, lvars.obd_vars);
#ifdef LPROCFS
lprocfs_obd_setup(obd, lvars.obd_vars);
#ifdef LPROCFS
- {
- rc = lprocfs_seq_create(obd->obd_proc_entry, "target_obd",
- 0444, &lmv_proc_target_fops, obd);
- if (rc)
- CWARN("%s: error adding LMV target_obd file: rc = %d\n",
- obd->obd_name, rc);
- }
+ {
+ rc = lprocfs_seq_create(obd->obd_proc_entry, "target_obd",
+ 0444, &lmv_proc_target_fops, obd);
+ if (rc)
+ CWARN("%s: error adding LMV target_obd file: rc = %d\n",
+ obd->obd_name, rc);
+ }
#endif
rc = fld_client_init(&lmv->lmv_fld, obd->obd_name,
LUSTRE_CLI_FLD_HASH_DHT);
#endif
rc = fld_client_init(&lmv->lmv_fld, obd->obd_name,
LUSTRE_CLI_FLD_HASH_DHT);