-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix ext2 read and write #59
Conversation
- Rename EXT2_INDIRECT_BLOCKS to EXT2_DIRECT_BLOCKS - Simplify and fix ext2_get_real_block_index - Simplify and fix ext2_read_inode_data - Remove indirect_blocks_index, doubly_indirect_blocks_index, and trebly_indirect_blocks_index from the fs structure
- We were not saving the block in ext2_set_real_block_index, now we do
- Add more comments to ext2_allocate_block; - Fix error return for ext2_read_inode_data; - Add more logging message where needed;
@@ -817,7 +832,7 @@ static inline int ext2_find_free_block_in_group(ext2_filesystem_t *fs, uint8_t * | |||
/// @param fs the ext2 filesystem structure. | |||
/// @param cache the cache from which we read the bgdt data. | |||
/// @param linear_index the output variable where we store the linear indes to the free block. | |||
/// @return 1 if we found a free block, 0 otherwise. | |||
/// @return 1 if we found a free block abd chace contains the block_bitmap, 0 otherwise. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is probably a typo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, thanks!
"t_groups", | ||
"t_itimer", | ||
"t_kill", | ||
// "t_abort", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why disabling all tests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, my bad, I was disabling them to focus on write/read from file.
ext2_dump_inode output
;EXT2_INDIRECT_BLOCKS
toEXT2_DIRECT_BLOCKS
;ext2_get_real_block_index
;ext2_read_inode_data
;indirect_blocks_index
,doubly_indirect_blocks_index
, andtrebly_indirect_blocks_index
from the fs structure;ext2_set_real_block_index
, we were not saving the block inext2_set_real_block_index
;ext2_write_inode_data
;ext2_allocate_block
;