Open
Description
I think that the VFS block file system is not in a good shape. I would like to see it improved in several respects:
- The
_block_io
method should be replaced by_read
and_write
methods. Handling both operations in one method makes things needlessly complicated and inconsistent. I.e., the misleading error message "Could not read block(s)" that could also appear on write operations, or the use booleanwrite
argument, and the optionalbulk
argument. - The handling of partial block accesses is hard to comprehend and depends on questionable conditions. In particular, I was wondering about
(count % _block_size) >= 0
. Isn't this always true? - It should use the block session asynchronously, once the VFS supports this.
- It should use the
blit
library instead of byte-wise memcpy.