fuse: fix stat call on 32 bit platforms
authorPavel Shilovsky <piastry@etersoft.ru>
Thu, 10 May 2012 15:49:38 +0000 (19:49 +0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Jun 2012 18:21:29 +0000 (11:21 -0700)
commit9abcb7517f13aa54152bee6370538b8f56893349
treea15e24c622f773c714a72f3b1113054cfd9f7d89
parentd5b9a38383178758ddf671b7a5551afab4e504b2
fuse: fix stat call on 32 bit platforms

commit 45c72cd73c788dd18c8113d4a404d6b4a01decf1 upstream.

Now we store attr->ino at inode->i_ino, return attr->ino at the
first time and then return inode->i_ino if the attribute timeout
isn't expired. That's wrong on 32 bit platforms because attr->ino
is 64 bit and inode->i_ino is 32 bit in this case.

Fix this by saving 64 bit ino in fuse_inode structure and returning
it every time we call getattr. Also squash attr->ino into inode->i_ino
explicitly.

Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/fuse/dir.c
fs/fuse/fuse_i.h
fs/fuse/inode.c