u-boot-brain/fs/squashfs
Campbell Suter 9dba07f143 Fix squashfs failing to load sparse files
SquashFS supports sprase blocks in files - that is, if a given block is
composed only of zeros, it's not written to the output file to save
space and it's on-disk length field is set to zero to indicate that.

Previously the squashfs driver did not recognise that, and would attempt
to read and decompress a zero-sized block, which obviously failed.

The following command may be used to create a file for testing:

cat <(dd if=/dev/urandom of=/dev/stdout bs=1M count=1) \
	<(dd if=/dev/zero of=/dev/stdout bs=1M count=1) \
	<(dd if=/dev/urandom of=/dev/stdout bs=1k count=200) >test_file

Signed-off-by: Campbell Suter <campbell@snapit.group>
2021-01-20 14:01:44 -05:00
..
Kconfig include/u-boot, lib/zlib: add sources for zlib decompression 2020-08-07 22:31:32 -04:00
Makefile fs/squashfs: new filesystem 2020-08-07 22:31:32 -04:00
sqfs_decompressor.c fs/squashfs: add support for LZO decompression 2020-08-24 14:11:31 -04:00
sqfs_decompressor.h fs/squashfs: replace sqfs_decompress() parameter 2020-08-24 14:11:31 -04:00
sqfs_dir.c fs/squashfs: Fix Coverity Scan defects 2020-09-18 16:19:58 -04:00
sqfs_filesystem.h fs/squashfs: add support for ZSTD decompression 2020-08-24 14:11:31 -04:00
sqfs_inode.c fs/squashfs: Fix index off by 1 for inode SQFS_LDIR_TYPE 2020-11-19 09:45:49 -05:00
sqfs_utils.h fs/squashfs: new filesystem 2020-08-07 22:31:32 -04:00
sqfs.c Fix squashfs failing to load sparse files 2021-01-20 14:01:44 -05:00