From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?ISO-8859-1?Q?Andreas_Bie=DFmann?= Date: Fri, 07 Sep 2012 10:00:22 +0200 Subject: [U-Boot] [PATCH v2] ubifs: Fix ubifsload when using ZLIB In-Reply-To: <1346857514-14742-1-git-send-email-veli-pekka.peltola@bluegiga.com> References: <1346857514-14742-1-git-send-email-veli-pekka.peltola@bluegiga.com> Message-ID: <5049A996.5050301@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 05.09.2012 17:05, Veli-Pekka Peltola wrote: > Using ZLIB compression with UBIFS fails if last data node is not a size of > UBIFS_BLOCK_SIZE (4096 bytes). > > Easiest way to test this is trying to read a file smaller than 4k: > => ubifsload 41000000 /etc/fstab > Loading file '/etc/fstab' to addr 0x41000000 with size 704 (0x000002c0)... > UBIFS error (pid 0): read_block: bad data node (block 0, inode 2506) > UBIFS error (pid 0): do_readpage: cannot read page 0 of inode 2506, error -22 > Error reading file '/etc/fstab' > /etc/fstab not found! > exit not allowed from main input shell. > => > > With this patch: > > => ubifsload 41000000 /etc/fstab > Loading file '/etc/fstab' to addr 0x41000000 with size 704 (0x000002c0)... > Done > => > > Signed-off-by: Veli-Pekka Peltola > Cc: kmpark at infradead.org Tested-by: Andreas Bie?mann