diff options
author | Yan, Zheng <zyan@redhat.com> | 2016-07-06 03:37:42 -0400 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2016-07-27 21:00:42 -0400 |
commit | 3609404f8c782c01fe626a03949641dddbc65c34 (patch) | |
tree | 3eb8adebedc9ff3c42e50efec1ed778bdbd4e789 | |
parent | 3469ed0d149ba7066e8fef72be55f67ee7de196d (diff) |
ceph: update types of some local varibles
Signed-off-by: Yan, Zheng <zyan@redhat.com>
-rw-r--r-- | fs/ceph/caps.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/fs/ceph/caps.c b/fs/ceph/caps.c index 1e48377f18a7..698cf002d3f1 100644 --- a/fs/ceph/caps.c +++ b/fs/ceph/caps.c | |||
@@ -993,7 +993,7 @@ static int send_cap_msg(struct ceph_mds_session *session, | |||
993 | u32 seq, u64 flush_tid, u64 oldest_flush_tid, | 993 | u32 seq, u64 flush_tid, u64 oldest_flush_tid, |
994 | u32 issue_seq, u32 mseq, u64 size, u64 max_size, | 994 | u32 issue_seq, u32 mseq, u64 size, u64 max_size, |
995 | struct timespec *mtime, struct timespec *atime, | 995 | struct timespec *mtime, struct timespec *atime, |
996 | struct timespec *ctime, u64 time_warp_seq, | 996 | struct timespec *ctime, u32 time_warp_seq, |
997 | kuid_t uid, kgid_t gid, umode_t mode, | 997 | kuid_t uid, kgid_t gid, umode_t mode, |
998 | u64 xattr_version, | 998 | u64 xattr_version, |
999 | struct ceph_buffer *xattrs_buf, | 999 | struct ceph_buffer *xattrs_buf, |
@@ -1118,8 +1118,8 @@ static int __send_cap(struct ceph_mds_client *mdsc, struct ceph_cap *cap, | |||
1118 | struct inode *inode = &ci->vfs_inode; | 1118 | struct inode *inode = &ci->vfs_inode; |
1119 | u64 cap_id = cap->cap_id; | 1119 | u64 cap_id = cap->cap_id; |
1120 | int held, revoking, dropping, keep; | 1120 | int held, revoking, dropping, keep; |
1121 | u64 seq, issue_seq, mseq, time_warp_seq, follows; | 1121 | u64 follows, size, max_size; |
1122 | u64 size, max_size; | 1122 | u32 seq, issue_seq, mseq, time_warp_seq; |
1123 | struct timespec mtime, atime, ctime; | 1123 | struct timespec mtime, atime, ctime; |
1124 | int wake = 0; | 1124 | int wake = 0; |
1125 | umode_t mode; | 1125 | umode_t mode; |
@@ -1585,10 +1585,11 @@ void ceph_check_caps(struct ceph_inode_info *ci, int flags, | |||
1585 | int mds = -1; /* keep track of how far we've gone through i_caps list | 1585 | int mds = -1; /* keep track of how far we've gone through i_caps list |
1586 | to avoid an infinite loop on retry */ | 1586 | to avoid an infinite loop on retry */ |
1587 | struct rb_node *p; | 1587 | struct rb_node *p; |
1588 | int tried_invalidate = 0; | 1588 | int delayed = 0, sent = 0, num; |
1589 | int delayed = 0, sent = 0, force_requeue = 0, num; | 1589 | bool is_delayed = flags & CHECK_CAPS_NODELAY; |
1590 | int queue_invalidate = 0; | 1590 | bool queue_invalidate = false; |
1591 | int is_delayed = flags & CHECK_CAPS_NODELAY; | 1591 | bool force_requeue = false; |
1592 | bool tried_invalidate = false; | ||
1592 | 1593 | ||
1593 | /* if we are unmounting, flush any unused caps immediately. */ | 1594 | /* if we are unmounting, flush any unused caps immediately. */ |
1594 | if (mdsc->stopping) | 1595 | if (mdsc->stopping) |
@@ -1668,17 +1669,17 @@ retry_locked: | |||
1668 | if (revoking & (CEPH_CAP_FILE_CACHE| | 1669 | if (revoking & (CEPH_CAP_FILE_CACHE| |
1669 | CEPH_CAP_FILE_LAZYIO)) { | 1670 | CEPH_CAP_FILE_LAZYIO)) { |
1670 | dout("check_caps queuing invalidate\n"); | 1671 | dout("check_caps queuing invalidate\n"); |
1671 | queue_invalidate = 1; | 1672 | queue_invalidate = true; |
1672 | ci->i_rdcache_revoking = ci->i_rdcache_gen; | 1673 | ci->i_rdcache_revoking = ci->i_rdcache_gen; |
1673 | } else { | 1674 | } else { |
1674 | dout("check_caps failed to invalidate pages\n"); | 1675 | dout("check_caps failed to invalidate pages\n"); |
1675 | /* we failed to invalidate pages. check these | 1676 | /* we failed to invalidate pages. check these |
1676 | caps again later. */ | 1677 | caps again later. */ |
1677 | force_requeue = 1; | 1678 | force_requeue = true; |
1678 | __cap_set_timeouts(mdsc, ci); | 1679 | __cap_set_timeouts(mdsc, ci); |
1679 | } | 1680 | } |
1680 | } | 1681 | } |
1681 | tried_invalidate = 1; | 1682 | tried_invalidate = true; |
1682 | goto retry_locked; | 1683 | goto retry_locked; |
1683 | } | 1684 | } |
1684 | 1685 | ||
@@ -1824,7 +1825,7 @@ ack: | |||
1824 | * otherwise cancel. | 1825 | * otherwise cancel. |
1825 | */ | 1826 | */ |
1826 | if (delayed && is_delayed) | 1827 | if (delayed && is_delayed) |
1827 | force_requeue = 1; /* __send_cap delayed release; requeue */ | 1828 | force_requeue = true; /* __send_cap delayed release; requeue */ |
1828 | if (!delayed && !is_delayed) | 1829 | if (!delayed && !is_delayed) |
1829 | __cap_delay_cancel(mdsc, ci); | 1830 | __cap_delay_cancel(mdsc, ci); |
1830 | else if (!is_delayed || force_requeue) | 1831 | else if (!is_delayed || force_requeue) |