forked from OERV-BSP/u-boot
test_fs: Allow running unprivileged
There is no need to mount the filesystem on the host side. All filesystem tools offer some way to fill the fs without mounting. So, create the content on the host side, create and fill the fs without mounting. No more sudo or guestmount needed. This new approach works because the tests don't care about user IDs and no device files are needed. If user IDs start to matter it's still possible to use wrapper tools like fakeroot in future while filling the fs. Signed-off-by: Richard Weinberger <richard@nod.at> Signed-off-by: Simon Glass <sjg@chromium.org> Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
This commit is contained in:
committed by
Tom Rini
parent
dc1859f8d2
commit
463bc7b82e
@@ -540,8 +540,8 @@ def test_ut_dm_init(u_boot_console):
|
||||
u_boot_utils.run_and_log(
|
||||
u_boot_console, f'sfdisk {fn}', stdin=b'type=83')
|
||||
|
||||
fs_helper.mk_fs(u_boot_console.config, 'ext2', 0x200000, '2MB')
|
||||
fs_helper.mk_fs(u_boot_console.config, 'fat32', 0x100000, '1MB')
|
||||
fs_helper.mk_fs(u_boot_console.config, 'ext2', 0x200000, '2MB', None)
|
||||
fs_helper.mk_fs(u_boot_console.config, 'fat32', 0x100000, '1MB', None)
|
||||
|
||||
mmc_dev = 6
|
||||
fn = os.path.join(u_boot_console.config.source_dir, f'mmc{mmc_dev}.img')
|
||||
|
||||
Reference in New Issue
Block a user