aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2010-11-18 21:05:24 -0500
committerChris Mason <chris.mason@oracle.com>2010-11-21 22:26:07 -0500
commitf209561ad83c5ffd561dc4bc3a3c90b704fe9231 (patch)
tree9241e4251c8e73cdbb8b9e4abf279afd61694a8d /fs/btrfs
parent5f3888ff6f0b9dce60705765752b788a92557644 (diff)
btrfs: Show device attr correctly for symlinks
Symlinks and files of other types show different device numbers, though they are on the same partition: $ touch tmp; ln -s tmp tmp2; stat tmp tmp2 File: `tmp' Size: 0 Blocks: 0 IO Block: 4096 regular empty file Device: 15h/21d Inode: 984027 Links: 1 --- snip --- File: `tmp2' -> `tmp' Size: 3 Blocks: 0 IO Block: 4096 symbolic link Device: 13h/19d Inode: 984028 Links: 1 Reported-by: Toke Høiland-Jørgensen <toke@toke.dk> Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r--fs/btrfs/inode.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index a47e4faa8c46..eed357ff6c99 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -7299,6 +7299,7 @@ static const struct inode_operations btrfs_symlink_inode_operations = {
7299 .readlink = generic_readlink, 7299 .readlink = generic_readlink,
7300 .follow_link = page_follow_link_light, 7300 .follow_link = page_follow_link_light,
7301 .put_link = page_put_link, 7301 .put_link = page_put_link,
7302 .getattr = btrfs_getattr,
7302 .permission = btrfs_permission, 7303 .permission = btrfs_permission,
7303 .setxattr = btrfs_setxattr, 7304 .setxattr = btrfs_setxattr,
7304 .getxattr = btrfs_getxattr, 7305 .getxattr = btrfs_getxattr,