Conversation
Now fs cli commands are register at link time to reduce memory footprint. No change in functionality. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
Disk interface tightly coupled to file system and could not be used for exposing disk to something else then code in fs/fs. With this change new disk_listener interface allows code to be informed about disks being inserted and removed. Listeners in turn can mount file systems from disk or for example expose disk to USB host via MSC. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
File system was represented by fs_ops that consisted of bunch of file system functions, name, and pointer to link file system ops in chain. Most of the date was constant and there is was no reason to waste RAM for callback pointer. This introduce file_system object that has ops but can be extended to hold file system specific data. Same file system ops can be used for more then one file system. File system can be mounted and that what littlefs and other file systems will. This change mostly changes filesystem_ops to const in most places. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
This updates littlefs to use fs_mount instead of fs_register. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
This updates nffs to use fs_mount instead of fs_register. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
This adds command to show mounted file systems Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
This adds file disk listener that can mount fatfs disk (like sdcard) if it contains FAT data. Fixes problem with accessing disk grater then 2GB. Previous disk interface (that is now removed) used 32 bit to address bytes of disk. Now disk access uses sectors as it the code for disk. Further more file name conversion from sd0: to 0: is now removed. FATFS driver wants to use 0: volumes and mynewt wanted to have sd0: Now disk will be mounted as 0: removing need for conversion and heap allocations. Signed-off-by: Jerzy Kasenberg <jerzy@apache.org>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is start of a rework of file system related code.
There was a few drawbacks in current implementation of file system especially disk related (this does not touch FCB).