[U-Boot] [PATCH v3 1/8] sandbox: only do sandboxfs for hostfs interface
Sjoerd Simons
sjoerd.simons at collabora.co.uk
Sun Apr 12 23:04:42 CEST 2015
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 <sjoerd.simons at collabora.co.uk>
Reviewed-by: Simon Glass <sjg at chromium.org>
Acked-by: Simon Glass <sjg at chromium.org>
---
Changes in v3: None
Changes in v2:
- Minor comment coding style improvement
fs/sandbox/sandboxfs.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/fs/sandbox/sandboxfs.c b/fs/sandbox/sandboxfs.c
index a920bc0..5acfc03 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,
--
2.1.4
More information about the U-Boot
mailing list