* [PATCH] FAT: small cleanup (3/4)
@ 2004-05-02 13:10 OGAWA Hirofumi
0 siblings, 0 replies; only message in thread
From: OGAWA Hirofumi @ 2004-05-02 13:10 UTC (permalink / raw)
To: Linus Torvalds, Andrew Morton; +Cc: linux-kernel
Hi,
just small cleanup.
--
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
fs/fat/file.c | 2 +-
fs/fat/misc.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff -puN fs/fat/misc.c~fat_micro-cleanup fs/fat/misc.c
--- linux-2.6.6-rc3/fs/fat/misc.c~fat_micro-cleanup 2004-05-02 19:15:43.000000000 +0900
+++ linux-2.6.6-rc3-hirofumi/fs/fat/misc.c 2004-05-02 19:15:43.000000000 +0900
@@ -205,7 +205,7 @@ struct buffer_head *fat_extend_dir(struc
if (inode->i_size & (sb->s_blocksize - 1)) {
fat_fs_panic(sb, "Odd directory size");
inode->i_size = (inode->i_size + sb->s_blocksize)
- & ~(sb->s_blocksize - 1);
+ & ~((loff_t)sb->s_blocksize - 1);
}
inode->i_size += MSDOS_SB(sb)->cluster_size;
MSDOS_I(inode)->mmu_private += MSDOS_SB(sb)->cluster_size;
diff -puN fs/fat/file.c~fat_micro-cleanup fs/fat/file.c
--- linux-2.6.6-rc3/fs/fat/file.c~fat_micro-cleanup 2004-05-02 19:15:43.000000000 +0900
+++ linux-2.6.6-rc3-hirofumi/fs/fat/file.c 2004-05-02 19:15:43.000000000 +0900
@@ -50,7 +50,7 @@ int fat_get_block(struct inode *inode, s
BUG();
return -EIO;
}
- if (!((unsigned long)iblock % MSDOS_SB(sb)->sec_per_clus)) {
+ if (!((unsigned long)iblock & (MSDOS_SB(sb)->sec_per_clus - 1))) {
int error;
error = fat_add_cluster(inode);
_
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2004-05-02 13:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-05-02 13:10 [PATCH] FAT: small cleanup (3/4) OGAWA Hirofumi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox