Make smbfs with UNIX extensions get file disk usage count right.
commitdf60db4e57cdb0e0c1ac9d4a35ecc2ec2ef72e22
authorLinus Torvalds <torvalds@ppc970.osdl.org>
Sat, 25 Sep 2004 08:51:42 +0000 (25 01:51 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Sat, 25 Sep 2004 08:51:42 +0000 (25 01:51 -0700)
tree45200e058ed437b4d206e075705e119809c9f404
parent038f9a8f2bb8d02cade66afff652629aba83cf8a
Make smbfs with UNIX extensions get file disk usage count right.

We need to convert from bytes to blocks, and we also need to
handle the fact that old smbd's will round up the disk usage
bytecount to even multiples of 1MB, and gracefully fall back
on an estimate based on the file size instead in that case.

Acked by Samuel Thibault who noted the problem in the first
place, and Jeremy Allison wrt smbd behavior.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/smbfs/proc.c