From: Sjoerd Simons Date: Mon, 13 Apr 2015 20:54:19 +0000 (+0200) Subject: sandbox: only do sandboxfs for hostfs interface X-Git-Tag: v2015.07-rc1~120 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=85300a9a9dfb364ab1a5f94e6d3f9e558a193be1;p=u-boot sandbox: only do sandboxfs for hostfs interface Only do sandbox filesystem access when using the hostfs device interface, rather then falling back to it in all cases. This prevents confusion situations due to the fallback being taken rather then an unsupported error being raised. Signed-off-by: Sjoerd Simons Reviewed-by: Simon Glass Acked-by: Simon Glass --- diff --git a/fs/sandbox/sandboxfs.c b/fs/sandbox/sandboxfs.c index a920bc0877..5acfc03704 100644 --- a/fs/sandbox/sandboxfs.c +++ b/fs/sandbox/sandboxfs.c @@ -10,7 +10,11 @@ int sandbox_fs_set_blk_dev(block_dev_desc_t *rbdd, disk_partition_t *info) { - return 0; + /* + * Only accept a NULL block_dev_desc_t for the sandbox, which is when + * hostfs interface is used + */ + return rbdd != NULL; } int sandbox_fs_read_at(const char *filename, loff_t pos, void *buffer,