Skip to contentSkip to conversation

romfs-support-inode-blocks-calculation.patch removed from -mm tree

merged [email protected] 1 participant 1 message Oct 16, 2020

lore
Share & tools
lore

[email protected]

author tree notice Applied
#0 lore raw

The patch titled
Subject: ROMFS: support inode blocks calculation
has been removed from the -mm tree. Its filename was
romfs-support-inode-blocks-calculation.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
From: Libing Zhou <[email protected]>
Subject: ROMFS: support inode blocks calculation

When use 'stat' tool to display file status, the 'Blocks' field always in '0', this is not good for tool 'du'(e.g.: busybox 'du'), it always output '0' size for the files under ROMFS since such tool calculates number of 512B Blocks.

This patch calculates approx. number of 512B blocks based on inode size.

---

 fs/romfs/super.c |    1 +
 1 file changed, 1 insertion(+)
fs/romfs/super.c renamed from fs/romfs/super.c~romfs-support-inode-blocks-calculation +1 -0
@@ -356,6 +356,7 @@ static struct inode *romfs_iget(struct s
 	}
 
 	i->i_mode = mode;
+	i->i_blocks = (i->i_size + 511) >> 9;
 
 	unlock_new_inode(i);
 	return i;

_

Patches currently in -mm which might be from [email protected] are