Workaround required to make MuditaOS
able to boot from ext4-formatted OS
partition.
Previously OS partition was mounted
on /sys and user partition on
/sys/user. This worked
when two separate FS drivers
(FATFS and lwext4) were used.
Changing OS partition to ext4
created an ambiguity whether
/sys/user is user partition
mountpoint or folder 'user'
on OS partition. This
workaround still may create
ambiguities, so the issue
should be fixed in one of
the further releases by
completely removing 'sys'
prefix.
Add support for the EXT4 filesystem using LWEXT4
Add minor VFS fixes
Add unittest for the EXT4 partitions
Reformat partition for use EXT4 filesystem
[EGD-7587] Initial cmake of the ext4
[EGD-7587] Block driver for the ext4
Initial version of the block driver for the ext4 device
[EGD-7587] Initial version of the EXT4 fs support
Initial version of the ext4 filesystem support
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
[EGD-7587] Mount unmount initial unit tests
Mount and unmount initial unit tests
[EGD-7587] Unit tests and fixes for ext4
Unit tests and fixes for the ext4 partition
[EGD-7587[ adjust flags
Adjust ext configuration flags
[EGD-7587] Change to generate ext4 image
Change image generation script to generate ext4 image
[EGD-7584] Change cache memory settings
Change cache memory settings
[EGD-7587] Change create image flags
Change create image flags
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
[EGD-7587] Git change lwext4 to the mudita version
Change LWEXT4 to mudita version
[EGD-7587] Modify ext4 implementation
Modify ext4 implementation according to the new lwext4
mudita branch. Some issues were fixed in this branch
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
[EGD-7587] Add to VFS rmdir syscall
Add to VFS missing rmdir for compliance POSIX std
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
Remove dependency to the production image by creating separate sysroot
for test assets alongside with a test image Test.img.
Signed-off-by: Marcin Smoczyński <smoczynski.marcin@gmail.com>
Preparing and copying of assets to the image was unreliable.
Switched from cmake mechanism to rsync, making resulting
scheme universal and reducing output folder pollution.
Folder filtering prevented us from accessing /sys folder
of VFS image. This fix redirects all /sys references to
the image by default, requiring us to explicitly specify
all paths we want to redirect to Linux fs.
This commit adds interceptions for common POSIX calls.
Issue [EGD-4551] has shown that some calls can be made from
stdlibc++ that we didn't trace or intercept so far. Our goal
here is to improve our POSIX coverage.
This commit is part of libiosyscalls refining task.
Its purpose is to make this code more predictable and
easier to maintain (as well as fixing some minor bugs).
Add support for mount umount in the libiosyscall library
due to planning to use ro fatfs and remount to rw only
for update purposes.
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
Move iosyscalls symbols to a separate namespace `_iosys_*`
This helps us avoid accidentally overriding library calls
which are not exported as symbols.
Disk access was not protected by the mutex and race contition
occurs when multiple access was made for lfs and fat.
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
This is a first commit when the emulator uses
the new filesystem core.
libiosyscall library read environment variable
IOSYSCALS_REDIRECT_TO_IMAGE
When IOSYSCALS_REDIRECT_TO_IMAGE=1 all syscalls
are redirected to the image. If env is not defined
or set to 0 only paths are translated and redirected
to the native linux syscalls
[EGD-5074] Remove free rtox library
Remove unneeded fat library from the freertos
[EGD-5074] Fix freertos mutex as unique
Add freertos mutex in the unique_ptr for avoid inclusion of the
freertos.h
[EGD-5074] Remove frertos-fat submodule
Remove uneeded fat freertos submodule
[EGD-5074] Add handle types in the vfs_subsystem
Add handle types in the vfs subsystem
[EGD-5074] Add submodule for hashmap
Add submodule for hashmap
[EGD-5074] Add support for dirent
Add support for dirent for new filesystem
[EGD-5074] Fix mutex class
Remove mutex in header
[EGD-5074] Remove old vfs from file indexer
File indexer should be fixed for use new vfs
[EGD-5074] Fix unit test vfs
Remove unit tests vfs for clas
[EGD-5074] Add Posix implementation with new fs
Add posix implementation with new fs core
[EGD-5074] Fix stdio syscalls
Fix all stdio syscalls
[EGD-5074] Fix iosyscalls scan family
Fix iosyscalls scan family
[EGD-5074] Fix native API
Fix native api
Work in progress some minor fixes
[EGD-5074] Fix lib stdio
Fix lib stdio
[EGD-5074] fix lseek return value in fat driver
Fix lseek return value in the fat driver
[EGD-5074] Unit test fix
Unittest fixes
[EGD-5074] Emulator syscalls
Signed-off-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
Due to the errors in the libiosyscalls it was impossible
to build emulator for Linux Debug target. This commit will fix this
problem.
Co-authored-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
Currently calling any method from class vfs
causes aplication crash when methods are called before
vfs.Init() call. This commit prevent to crash end return failure
instead. The fix is related to any any vfs methods and methods called
through the standard syscall.
It is only the hotfix and it will be removed when new VFS subsystem
will be ready.
Co-authored-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>
Currently if file doens't exists on image the error is reported
but some subsystems need access to the underlaying linux fs.
In the feature release add strict checking for allowed paths
now it redirect syscall with warning.
Co-authored-by: Lucjan Bryndza <lucjan.bryndza@mudita.com>