Index: uspace/lib/ext2/libext2_filesystem.c
===================================================================
--- uspace/lib/ext2/libext2_filesystem.c	(revision 5352d72a1c169f0bcb66fde90819e94f703d561a)
+++ uspace/lib/ext2/libext2_filesystem.c	(revision a2a1792c0942cd3880228f76eb3f2bca1534118c)
@@ -186,4 +186,6 @@
 	uint32_t block_group;
 	uint32_t offset_in_group;
+	uint32_t byte_offset_in_group;
+	size_t offset_in_block;
 	uint32_t inodes_per_group;
 	uint32_t inode_table_start;
@@ -217,5 +219,8 @@
 	block_size = ext2_superblock_get_block_size(fs->superblock);
 	
-	block_id = inode_table_start + ((index * inode_size) / block_size);
+	byte_offset_in_group = offset_in_group * inode_size;
+	
+	block_id = inode_table_start + (byte_offset_in_group / block_size);
+	offset_in_block = byte_offset_in_group % block_size;
 	
 	rc = block_get(&newref->block, fs->device, block_id, 0);
@@ -225,5 +230,5 @@
 	}
 	
-	newref->inode = newref->block->data + (offset_in_group*inode_size);
+	newref->inode = newref->block->data + offset_in_block;
 	
 	*ref = newref;
