Hi,
When I stat(2) a device node on a cramfs, the st_blocks field is
bogus (it's derived from the size field which in this case holds the
major/minor numbers). This makes du(1) output completely wrong.

Please apply the patch below.

Eric

Signed-off-by: Eric Lammerts <[EMAIL PROTECTED]>

--- linux-2.6.11-rc5/fs/cramfs/inode.c.orig     2005-03-01 11:10:29.000000000 
-0500
+++ linux-2.6.11-rc5/fs/cramfs/inode.c  2005-03-01 11:10:36.000000000 -0500
@@ -70,6 +70,7 @@
                        inode->i_data.a_ops = &cramfs_aops;
                } else {
                        inode->i_size = 0;
+                       inode->i_blocks = 0;
                        init_special_inode(inode, inode->i_mode,
                                old_decode_dev(cramfs_inode->size));
                }
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to