Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.

Commit

Permalink
staging/lustre: Add spaces preferred around that '{+, -, *, /, |, <<,…
Browse files Browse the repository at this point in the history
… >>, &}'

This patch fixes all checkpatch occurences of
"CHECK: spaces preferred around that '{+,-,*,/,|,<<,>>,&}' (ctx:VxV)"
in Lustre code.

Signed-off-by: Emoly Liu <[email protected]>
Signed-off-by: Oleg Drokin <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
verygreen authored and gregkh committed Aug 21, 2016
1 parent 10adcce commit cd94f23
Show file tree
Hide file tree
Showing 35 changed files with 111 additions and 95 deletions.
3 changes: 2 additions & 1 deletion drivers/staging/lustre/lustre/include/lu_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -1024,7 +1024,8 @@ enum lu_context_tag {
/**
* Contexts usable in cache shrinker thread.
*/
LCT_SHRINKER = LCT_MD_THREAD|LCT_DT_THREAD|LCT_CL_THREAD|LCT_NOREF
LCT_SHRINKER = LCT_MD_THREAD | LCT_DT_THREAD | LCT_CL_THREAD |
LCT_NOREF
};

/**
Expand Down
28 changes: 14 additions & 14 deletions drivers/staging/lustre/lustre/include/lustre/lustre_idl.h
Original file line number Diff line number Diff line change
Expand Up @@ -2019,7 +2019,7 @@ void lustre_swab_generic_32s(__u32 *val);

#define MDS_INODELOCK_MAXSHIFT 5
/* This FULL lock is useful to take on unlink sort of operations */
#define MDS_INODELOCK_FULL ((1<<(MDS_INODELOCK_MAXSHIFT+1))-1)
#define MDS_INODELOCK_FULL ((1 << (MDS_INODELOCK_MAXSHIFT + 1)) - 1)

/* NOTE: until Lustre 1.8.7/2.1.1 the fid_ver() was packed into name[2],
* but was moved into name[1] along with the OID to avoid consuming the
Expand Down Expand Up @@ -3193,8 +3193,8 @@ struct llog_log_hdr {
__u32 llh_cat_idx;
/* for a catalog the first plain slot is next to it */
struct obd_uuid llh_tgtuuid;
__u32 llh_reserved[LLOG_HEADER_SIZE/sizeof(__u32) - 23];
__u32 llh_bitmap[LLOG_BITMAP_BYTES/sizeof(__u32)];
__u32 llh_reserved[LLOG_HEADER_SIZE / sizeof(__u32) - 23];
__u32 llh_bitmap[LLOG_BITMAP_BYTES / sizeof(__u32)];
struct llog_rec_tail llh_tail;
} __packed;

Expand Down Expand Up @@ -3409,17 +3409,17 @@ void lustre_swab_lustre_capa(struct lustre_capa *c);

/** lustre_capa::lc_opc */
enum {
CAPA_OPC_BODY_WRITE = 1<<0, /**< write object data */
CAPA_OPC_BODY_READ = 1<<1, /**< read object data */
CAPA_OPC_INDEX_LOOKUP = 1<<2, /**< lookup object fid */
CAPA_OPC_INDEX_INSERT = 1<<3, /**< insert object fid */
CAPA_OPC_INDEX_DELETE = 1<<4, /**< delete object fid */
CAPA_OPC_OSS_WRITE = 1<<5, /**< write oss object data */
CAPA_OPC_OSS_READ = 1<<6, /**< read oss object data */
CAPA_OPC_OSS_TRUNC = 1<<7, /**< truncate oss object */
CAPA_OPC_OSS_DESTROY = 1<<8, /**< destroy oss object */
CAPA_OPC_META_WRITE = 1<<9, /**< write object meta data */
CAPA_OPC_META_READ = 1<<10, /**< read object meta data */
CAPA_OPC_BODY_WRITE = 1 << 0, /**< write object data */
CAPA_OPC_BODY_READ = 1 << 1, /**< read object data */
CAPA_OPC_INDEX_LOOKUP = 1 << 2, /**< lookup object fid */
CAPA_OPC_INDEX_INSERT = 1 << 3, /**< insert object fid */
CAPA_OPC_INDEX_DELETE = 1 << 4, /**< delete object fid */
CAPA_OPC_OSS_WRITE = 1 << 5, /**< write oss object data */
CAPA_OPC_OSS_READ = 1 << 6, /**< read oss object data */
CAPA_OPC_OSS_TRUNC = 1 << 7, /**< truncate oss object */
CAPA_OPC_OSS_DESTROY = 1 << 8, /**< destroy oss object */
CAPA_OPC_META_WRITE = 1 << 9, /**< write object meta data */
CAPA_OPC_META_READ = 1 << 10, /**< read object meta data */
};

#define CAPA_OPC_OSS_RW (CAPA_OPC_OSS_READ | CAPA_OPC_OSS_WRITE)
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/include/lustre/lustre_user.h
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,7 @@ static inline void hsm_set_cl_error(int *flags, int error)
*flags |= (error << CLF_HSM_ERR_L);
}

#define CR_MAXSIZE cfs_size_round(2*NAME_MAX + 1 + \
#define CR_MAXSIZE cfs_size_round(2 * NAME_MAX + 1 + \
sizeof(struct changelog_ext_rec))

struct changelog_rec {
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/include/lustre_fid.h
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ static inline __u32 fid_flatten32(const struct lu_fid *fid)
* (from OID), or up to 128M inodes without collisions for new files.
*/
ino = ((seq & 0x000fffffULL) << 12) + ((seq >> 8) & 0xfffff000) +
(seq >> (64 - (40-8)) & 0xffffff00) +
(seq >> (64 - (40 - 8)) & 0xffffff00) +
(fid_oid(fid) & 0xff000fff) + ((fid_oid(fid) & 0x00fff000) << 8);

return ino ? ino : fid_oid(fid);
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/include/lustre_lite.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@

/* 4UL * 1024 * 1024 */
#define LL_MAX_BLKSIZE_BITS (22)
#define LL_MAX_BLKSIZE (1UL<<LL_MAX_BLKSIZE_BITS)
#define LL_MAX_BLKSIZE (1UL << LL_MAX_BLKSIZE_BITS)

/*
* This is embedded into llite super-blocks to keep track of
Expand Down
13 changes: 7 additions & 6 deletions drivers/staging/lustre/lustre/include/obd_support.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,17 +115,17 @@ extern char obd_jobid_var[];
* running on a backup server. (If it's too low, import_select_connection
* will increase the timeout anyhow.)
*/
#define INITIAL_CONNECT_TIMEOUT max(CONNECTION_SWITCH_MIN, obd_timeout/20)
#define INITIAL_CONNECT_TIMEOUT max(CONNECTION_SWITCH_MIN, obd_timeout / 20)
/* The max delay between connects is SWITCH_MAX + SWITCH_INC + INITIAL */
#define RECONNECT_DELAY_MAX (CONNECTION_SWITCH_MAX + CONNECTION_SWITCH_INC + \
INITIAL_CONNECT_TIMEOUT)
/* The min time a target should wait for clients to reconnect in recovery */
#define OBD_RECOVERY_TIME_MIN (2*RECONNECT_DELAY_MAX)
#define OBD_RECOVERY_TIME_MIN (2 * RECONNECT_DELAY_MAX)
#define OBD_IR_FACTOR_MIN 1
#define OBD_IR_FACTOR_MAX 10
#define OBD_IR_FACTOR_DEFAULT (OBD_IR_FACTOR_MAX/2)
#define OBD_IR_FACTOR_DEFAULT (OBD_IR_FACTOR_MAX / 2)
/* default timeout for the MGS to become IR_FULL */
#define OBD_IR_MGS_TIMEOUT (4*obd_timeout)
#define OBD_IR_MGS_TIMEOUT (4 * obd_timeout)
#define LONG_UNLINK 300 /* Unlink should happen before now */

/**
Expand Down Expand Up @@ -526,7 +526,8 @@ do { \
POISON_PTR(ptr); \
} while (0)

#define KEY_IS(str) \
(keylen >= (sizeof(str)-1) && memcmp(key, str, (sizeof(str)-1)) == 0)
#define KEY_IS(str) \
(keylen >= (sizeof(str) - 1) && \
memcmp(key, str, (sizeof(str) - 1)) == 0)

#endif
4 changes: 2 additions & 2 deletions drivers/staging/lustre/lustre/ldlm/ldlm_request.c
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,7 @@ static __u64 ldlm_cli_cancel_local(struct ldlm_lock *lock)
lock_res_and_lock(lock);
ldlm_set_cbpending(lock);
local_only = !!(lock->l_flags &
(LDLM_FL_LOCAL_ONLY|LDLM_FL_CANCEL_ON_BLOCK));
(LDLM_FL_LOCAL_ONLY | LDLM_FL_CANCEL_ON_BLOCK));
ldlm_cancel_callback(lock);
rc = ldlm_is_bl_ast(lock) ? LDLM_FL_BL_AST : LDLM_FL_CANCELING;
unlock_res_and_lock(lock);
Expand Down Expand Up @@ -1838,7 +1838,7 @@ static int ldlm_chain_lock_for_replay(struct ldlm_lock *lock, void *closure)
* bug 17614: locks being actively cancelled. Get a reference
* on a lock so that it does not disappear under us (e.g. due to cancel)
*/
if (!(lock->l_flags & (LDLM_FL_FAILED|LDLM_FL_CANCELING))) {
if (!(lock->l_flags & (LDLM_FL_FAILED | LDLM_FL_CANCELING))) {
list_add(&lock->l_pending_chain, list);
LDLM_LOCK_GET(lock);
}
Expand Down
4 changes: 2 additions & 2 deletions drivers/staging/lustre/lustre/llite/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -2472,7 +2472,7 @@ ll_file_ioctl(struct file *file, unsigned int cmd, unsigned long arg)

if (och) {
mode = och->och_flags &
(FMODE_READ|FMODE_WRITE);
(FMODE_READ | FMODE_WRITE);
rc = ll_lease_close(och, inode, &lease_broken);
if (rc == 0 && lease_broken)
mode = 0;
Expand Down Expand Up @@ -2959,7 +2959,7 @@ int ll_have_md_lock(struct inode *inode, __u64 *bits,
struct lustre_handle lockh;
ldlm_policy_data_t policy;
enum ldlm_mode mode = (l_req_mode == LCK_MINMODE) ?
(LCK_CR|LCK_CW|LCK_PR|LCK_PW) : l_req_mode;
(LCK_CR | LCK_CW | LCK_PR | LCK_PW) : l_req_mode;
struct lu_fid *fid;
__u64 flags;
int i;
Expand Down
21 changes: 12 additions & 9 deletions drivers/staging/lustre/lustre/llite/llite_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -659,7 +659,8 @@ static int ll_options(char *options, int *flags)
*flags |= tmp;
goto next;
}
tmp = ll_set_opt("noflock", s1, LL_SBI_FLOCK|LL_SBI_LOCALFLOCK);
tmp = ll_set_opt("noflock", s1,
LL_SBI_FLOCK | LL_SBI_LOCALFLOCK);
if (tmp) {
*flags &= ~tmp;
goto next;
Expand Down Expand Up @@ -1549,14 +1550,14 @@ int ll_setattr(struct dentry *de, struct iattr *attr)
{
int mode = d_inode(de)->i_mode;

if ((attr->ia_valid & (ATTR_CTIME|ATTR_SIZE|ATTR_MODE)) ==
(ATTR_CTIME|ATTR_SIZE|ATTR_MODE))
if ((attr->ia_valid & (ATTR_CTIME | ATTR_SIZE | ATTR_MODE)) ==
(ATTR_CTIME | ATTR_SIZE | ATTR_MODE))
attr->ia_valid |= MDS_OPEN_OWNEROVERRIDE;

if (((attr->ia_valid & (ATTR_MODE|ATTR_FORCE|ATTR_SIZE)) ==
(ATTR_SIZE|ATTR_MODE)) &&
if (((attr->ia_valid & (ATTR_MODE | ATTR_FORCE | ATTR_SIZE)) ==
(ATTR_SIZE | ATTR_MODE)) &&
(((mode & S_ISUID) && !(attr->ia_mode & S_ISUID)) ||
(((mode & (S_ISGID|S_IXGRP)) == (S_ISGID|S_IXGRP)) &&
(((mode & (S_ISGID | S_IXGRP)) == (S_ISGID | S_IXGRP)) &&
!(attr->ia_mode & S_ISGID))))
attr->ia_valid |= ATTR_FORCE;

Expand All @@ -1567,7 +1568,7 @@ int ll_setattr(struct dentry *de, struct iattr *attr)
attr->ia_valid |= ATTR_KILL_SUID;

if ((attr->ia_valid & ATTR_MODE) &&
((mode & (S_ISGID|S_IXGRP)) == (S_ISGID|S_IXGRP)) &&
((mode & (S_ISGID | S_IXGRP)) == (S_ISGID | S_IXGRP)) &&
!(attr->ia_mode & S_ISGID) &&
!(attr->ia_valid & ATTR_KILL_SGID))
attr->ia_valid |= ATTR_KILL_SGID;
Expand Down Expand Up @@ -1742,9 +1743,11 @@ int ll_update_inode(struct inode *inode, struct lustre_md *md)
lli->lli_ctime = body->mbo_ctime;
}
if (body->mbo_valid & OBD_MD_FLMODE)
inode->i_mode = (inode->i_mode & S_IFMT)|(body->mbo_mode & ~S_IFMT);
inode->i_mode = (inode->i_mode & S_IFMT) |
(body->mbo_mode & ~S_IFMT);
if (body->mbo_valid & OBD_MD_FLTYPE)
inode->i_mode = (inode->i_mode & ~S_IFMT)|(body->mbo_mode & S_IFMT);
inode->i_mode = (inode->i_mode & ~S_IFMT) |
(body->mbo_mode & S_IFMT);
LASSERT(inode->i_mode != 0);
if (S_ISREG(inode->i_mode))
inode->i_blkbits = min(PTLRPC_MAX_BRW_BITS + 1,
Expand Down
4 changes: 2 additions & 2 deletions drivers/staging/lustre/lustre/llite/llite_mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,15 +126,15 @@ ll_fault_io_init(struct vm_area_struct *vma, struct lu_env **env_ret,

fio = &io->u.ci_fault;
fio->ft_index = index;
fio->ft_executable = vma->vm_flags&VM_EXEC;
fio->ft_executable = vma->vm_flags & VM_EXEC;

/*
* disable VM_SEQ_READ and use VM_RAND_READ to make sure that
* the kernel will not read other pages not covered by ldlm in
* filemap_nopage. we do our readahead in ll_readpage.
*/
if (ra_flags)
*ra_flags = vma->vm_flags & (VM_RAND_READ|VM_SEQ_READ);
*ra_flags = vma->vm_flags & (VM_RAND_READ | VM_SEQ_READ);
vma->vm_flags &= ~VM_SEQ_READ;
vma->vm_flags |= VM_RAND_READ;

Expand Down
14 changes: 7 additions & 7 deletions drivers/staging/lustre/lustre/llite/lproc_llite.c
Original file line number Diff line number Diff line change
Expand Up @@ -996,17 +996,17 @@ static const struct llite_file_opcode {
/* file operation */
{ LPROC_LL_DIRTY_HITS, LPROCFS_TYPE_REGS, "dirty_pages_hits" },
{ LPROC_LL_DIRTY_MISSES, LPROCFS_TYPE_REGS, "dirty_pages_misses" },
{ LPROC_LL_READ_BYTES, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_BYTES,
{ LPROC_LL_READ_BYTES, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_BYTES,
"read_bytes" },
{ LPROC_LL_WRITE_BYTES, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_BYTES,
{ LPROC_LL_WRITE_BYTES, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_BYTES,
"write_bytes" },
{ LPROC_LL_BRW_READ, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_PAGES,
{ LPROC_LL_BRW_READ, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_PAGES,
"brw_read" },
{ LPROC_LL_BRW_WRITE, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_PAGES,
{ LPROC_LL_BRW_WRITE, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_PAGES,
"brw_write" },
{ LPROC_LL_OSC_READ, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_BYTES,
{ LPROC_LL_OSC_READ, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_BYTES,
"osc_read" },
{ LPROC_LL_OSC_WRITE, LPROCFS_CNTR_AVGMINMAX|LPROCFS_TYPE_BYTES,
{ LPROC_LL_OSC_WRITE, LPROCFS_CNTR_AVGMINMAX | LPROCFS_TYPE_BYTES,
"osc_write" },
{ LPROC_LL_IOCTL, LPROCFS_TYPE_REGS, "ioctl" },
{ LPROC_LL_OPEN, LPROCFS_TYPE_REGS, "open" },
Expand Down Expand Up @@ -1253,7 +1253,7 @@ static void ll_display_extents_info(struct ll_rw_extents_info *io_extents,
r, pct(r, read_tot), pct(read_cum, read_tot),
w, pct(w, write_tot), pct(write_cum, write_tot));
start = end;
if (start == 1<<10) {
if (start == 1 << 10) {
start = 1;
units += 10;
unitp++;
Expand Down
4 changes: 2 additions & 2 deletions drivers/staging/lustre/lustre/llite/namei.c
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ static struct dentry *ll_lookup_nd(struct inode *parent, struct dentry *dentry,
(inode_permission(parent, MAY_WRITE | MAY_EXEC) == 0))
return NULL;

if (flags & (LOOKUP_PARENT|LOOKUP_OPEN|LOOKUP_CREATE))
if (flags & (LOOKUP_PARENT | LOOKUP_OPEN | LOOKUP_CREATE))
itp = NULL;
else
itp = &it;
Expand Down Expand Up @@ -1012,7 +1012,7 @@ static int ll_mkdir(struct inode *dir, struct dentry *dentry, umode_t mode)

if (!IS_POSIXACL(dir) || !exp_connect_umask(ll_i2mdexp(dir)))
mode &= ~current_umask();
mode = (mode & (S_IRWXUGO|S_ISVTX)) | S_IFDIR;
mode = (mode & (S_IRWXUGO | S_ISVTX)) | S_IFDIR;
err = ll_new_node(dir, dentry, NULL, mode, 0, LUSTRE_OPC_MKDIR);

if (!err)
Expand Down
5 changes: 3 additions & 2 deletions drivers/staging/lustre/lustre/llite/rw.c
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,8 @@ static void ras_update_stride_detector(struct ll_readahead_state *ras,
if (!stride_io_mode(ras) && (stride_gap != 0 ||
ras->ras_consecutive_stride_requests == 0)) {
ras->ras_stride_pages = ras->ras_consecutive_pages;
ras->ras_stride_length = stride_gap+ras->ras_consecutive_pages;
ras->ras_stride_length = ras->ras_consecutive_pages +
stride_gap;
}
LASSERT(ras->ras_request_index == 0);
LASSERT(ras->ras_consecutive_stride_requests == 0);
Expand All @@ -663,7 +664,7 @@ static void ras_update_stride_detector(struct ll_readahead_state *ras,
}

ras->ras_stride_pages = ras->ras_consecutive_pages;
ras->ras_stride_length = stride_gap+ras->ras_consecutive_pages;
ras->ras_stride_length = stride_gap + ras->ras_consecutive_pages;

RAS_CDEBUG(ras);
return;
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/llite/rw26.c
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ static int ll_releasepage(struct page *vmpage, gfp_t gfp_mask)
return result;
}

#define MAX_DIRECTIO_SIZE (2*1024*1024*1024UL)
#define MAX_DIRECTIO_SIZE (2 * 1024 * 1024 * 1024UL)

static inline int ll_get_user_pages(int rw, unsigned long user_addr,
size_t size, struct page ***pages,
Expand Down
4 changes: 2 additions & 2 deletions drivers/staging/lustre/lustre/llite/super25.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ static int __init lustre_init(void)

rc = -ENOMEM;
ll_inode_cachep = kmem_cache_create("lustre_inode_cache",
sizeof(struct ll_inode_info),
0, SLAB_HWCACHE_ALIGN|SLAB_ACCOUNT,
sizeof(struct ll_inode_info), 0,
SLAB_HWCACHE_ALIGN | SLAB_ACCOUNT,
NULL);
if (!ll_inode_cachep)
goto out_cache;
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/llite/vvp_object.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ static int vvp_attr_set(const struct lu_env *env, struct cl_object *obj,
if (0 && valid & CAT_SIZE)
i_size_write(inode, attr->cat_size);
/* not currently necessary */
if (0 && valid & (CAT_UID|CAT_GID|CAT_SIZE))
if (0 && valid & (CAT_UID | CAT_GID | CAT_SIZE))
mark_inode_dirty(inode);
return 0;
}
Expand Down
3 changes: 2 additions & 1 deletion drivers/staging/lustre/lustre/lov/lov_ea.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ static int lsm_lmm_verify_common(struct lov_mds_md *lmm, int lmm_bytes,
}

if (lmm->lmm_stripe_size == 0 ||
(le32_to_cpu(lmm->lmm_stripe_size)&(LOV_MIN_STRIPE_SIZE-1)) != 0) {
(le32_to_cpu(lmm->lmm_stripe_size) &
(LOV_MIN_STRIPE_SIZE - 1)) != 0) {
CERROR("bad stripe size %u\n",
le32_to_cpu(lmm->lmm_stripe_size));
lov_dump_lmm_common(D_WARNING, lmm);
Expand Down
14 changes: 8 additions & 6 deletions drivers/staging/lustre/lustre/lov/lov_obd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1917,8 +1917,9 @@ static int lov_fiemap(struct lov_obd *lov, __u32 keylen, void *key,
break;
}

len_mapped_single_call = lcl_fm_ext[ext_count-1].fe_logical -
lun_start + lcl_fm_ext[ext_count - 1].fe_length;
len_mapped_single_call =
lcl_fm_ext[ext_count - 1].fe_logical -
lun_start + lcl_fm_ext[ext_count - 1].fe_length;

/* Have we finished mapping on this device? */
if (req_fm_len <= len_mapped_single_call)
Expand All @@ -1927,14 +1928,15 @@ static int lov_fiemap(struct lov_obd *lov, __u32 keylen, void *key,
/* Clear the EXTENT_LAST flag which can be present on
* last extent
*/
if (lcl_fm_ext[ext_count-1].fe_flags & FIEMAP_EXTENT_LAST)
if (lcl_fm_ext[ext_count - 1].fe_flags &
FIEMAP_EXTENT_LAST)
lcl_fm_ext[ext_count - 1].fe_flags &=
~FIEMAP_EXTENT_LAST;

curr_loc = lov_stripe_size(lsm,
lcl_fm_ext[ext_count - 1].fe_logical+
lcl_fm_ext[ext_count - 1].fe_length,
cur_stripe);
lcl_fm_ext[ext_count - 1].fe_logical +
lcl_fm_ext[ext_count - 1].fe_length,
cur_stripe);
if (curr_loc >= fm_key->oa.o_size)
ost_eof = 1;

Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/lov/lov_pool.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ static __u32 pool_hashfn(struct cfs_hash *hash_body, const void *key, unsigned m
for (i = 0; i < LOV_MAXPOOLNAME; i++) {
if (poolname[i] == '\0')
break;
result = (result << 4)^(result >> 28) ^ poolname[i];
result = (result << 4) ^ (result >> 28) ^ poolname[i];
}
return (result % mask);
}
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/lustre/lustre/mdc/mdc_locks.c
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ mdc_intent_open_pack(struct obd_export *exp, struct lookup_intent *it,
else
mode = LCK_PR;
} else {
if (it->it_flags & (FMODE_WRITE|MDS_OPEN_TRUNC))
if (it->it_flags & (FMODE_WRITE | MDS_OPEN_TRUNC))
mode = LCK_CW;
else if (it->it_flags & __FMODE_EXEC)
mode = LCK_PR;
Expand Down
Loading

0 comments on commit cd94f23

Please sign in to comment.