mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-02 09:46:37 +03:00
fs: Add a function to set the filesystem type
When sandbox is used with hostfs we won't have a block device, but still must set up the filesystem type before any filesystem operation, such as loading a file. Add a function to handle this. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
11
include/fs.h
11
include/fs.h
@@ -57,6 +57,17 @@ int do_ext2load(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]);
|
||||
*/
|
||||
int fs_set_blk_dev(const char *ifname, const char *dev_part_str, int fstype);
|
||||
|
||||
/**
|
||||
* fs_set_type() - Tell fs layer which filesystem type is used
|
||||
*
|
||||
* This is needed when reading from a non-block device such as sandbox. It does
|
||||
* a similar job to fs_set_blk_dev() but just sets the filesystem type instead
|
||||
* of detecting it and loading it on the block device
|
||||
*
|
||||
* @type: Filesystem type to use (FS_TYPE...)
|
||||
*/
|
||||
void fs_set_type(int type);
|
||||
|
||||
/*
|
||||
* fs_set_blk_dev_with_part - Set current block device + partition
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user