diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-02-12 21:00:05 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-02-13 20:45:39 -0500 |
commit | 847c9db5cb50841589b8ebd3da0769b1b02fb3b2 (patch) | |
tree | 58d303a0306ed61114032b6d40085b17e13aaa0c /fs/ocfs2 | |
parent | fcf83067bf6eb101a35620d752bd559d473cfbaa (diff) |
ocfs2: deal with wraparounds of i_nlink in ocfs2_rename()
unfortunately, nlink_t may be smaller than 32 bits and ->i_nlink
on ocfs2 can grow up to 0xffffffff; storing it in nlink_t variable
will lose upper bits on such architectures. Needs to be made u32,
until we get kernel-side nlink_t uniformly 32bit...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ocfs2')
-rw-r--r-- | fs/ocfs2/namei.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ocfs2/namei.c b/fs/ocfs2/namei.c index be244692550..a9856e3eaaf 100644 --- a/fs/ocfs2/namei.c +++ b/fs/ocfs2/namei.c @@ -1053,7 +1053,7 @@ static int ocfs2_rename(struct inode *old_dir, handle_t *handle = NULL; struct buffer_head *old_dir_bh = NULL; struct buffer_head *new_dir_bh = NULL; - nlink_t old_dir_nlink = old_dir->i_nlink; + u32 old_dir_nlink = old_dir->i_nlink; struct ocfs2_dinode *old_di; struct ocfs2_dir_lookup_result old_inode_dot_dot_res = { NULL, }; struct ocfs2_dir_lookup_result target_lookup_res = { NULL, }; |