diff options
author | Sage Weil <sage@inktank.com> | 2013-08-15 14:11:45 -0400 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-08-15 14:11:45 -0400 |
commit | ee3e542fec6e69bc9fb668698889a37d93950ddf (patch) | |
tree | e74ee766a4764769ef1d3d45d266b4dea64101d3 /fs/ceph/mds_client.c | |
parent | fe2a801b50c0bb8039d627e5ae1fec249d10ff39 (diff) | |
parent | f1d6e17f540af37bb1891480143669ba7636c4cf (diff) |
Merge remote-tracking branch 'linus/master' into testing
Diffstat (limited to 'fs/ceph/mds_client.c')
-rw-r--r-- | fs/ceph/mds_client.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c index cbf08203e00d..603786b564be 100644 --- a/fs/ceph/mds_client.c +++ b/fs/ceph/mds_client.c | |||
@@ -1588,7 +1588,7 @@ retry: | |||
1588 | *base = ceph_ino(temp->d_inode); | 1588 | *base = ceph_ino(temp->d_inode); |
1589 | *plen = len; | 1589 | *plen = len; |
1590 | dout("build_path on %p %d built %llx '%.*s'\n", | 1590 | dout("build_path on %p %d built %llx '%.*s'\n", |
1591 | dentry, dentry->d_count, *base, len, path); | 1591 | dentry, d_count(dentry), *base, len, path); |
1592 | return path; | 1592 | return path; |
1593 | } | 1593 | } |
1594 | 1594 | ||
@@ -2517,20 +2517,20 @@ static int encode_caps_cb(struct inode *inode, struct ceph_cap *cap, | |||
2517 | struct ceph_filelock *flocks; | 2517 | struct ceph_filelock *flocks; |
2518 | 2518 | ||
2519 | encode_again: | 2519 | encode_again: |
2520 | lock_flocks(); | 2520 | spin_lock(&inode->i_lock); |
2521 | ceph_count_locks(inode, &num_fcntl_locks, &num_flock_locks); | 2521 | ceph_count_locks(inode, &num_fcntl_locks, &num_flock_locks); |
2522 | unlock_flocks(); | 2522 | spin_unlock(&inode->i_lock); |
2523 | flocks = kmalloc((num_fcntl_locks+num_flock_locks) * | 2523 | flocks = kmalloc((num_fcntl_locks+num_flock_locks) * |
2524 | sizeof(struct ceph_filelock), GFP_NOFS); | 2524 | sizeof(struct ceph_filelock), GFP_NOFS); |
2525 | if (!flocks) { | 2525 | if (!flocks) { |
2526 | err = -ENOMEM; | 2526 | err = -ENOMEM; |
2527 | goto out_free; | 2527 | goto out_free; |
2528 | } | 2528 | } |
2529 | lock_flocks(); | 2529 | spin_lock(&inode->i_lock); |
2530 | err = ceph_encode_locks_to_buffer(inode, flocks, | 2530 | err = ceph_encode_locks_to_buffer(inode, flocks, |
2531 | num_fcntl_locks, | 2531 | num_fcntl_locks, |
2532 | num_flock_locks); | 2532 | num_flock_locks); |
2533 | unlock_flocks(); | 2533 | spin_unlock(&inode->i_lock); |
2534 | if (err) { | 2534 | if (err) { |
2535 | kfree(flocks); | 2535 | kfree(flocks); |
2536 | if (err == -ENOSPC) | 2536 | if (err == -ENOSPC) |