[U-Boot] Add ext4 write support

Kim Phillips kim.phillips at freescale.com
Tue Jan 10 03:30:41 CET 2012


On Mon, 9 Jan 2012 23:21:40 +0530
<uma.shankar at samsung.com> wrote:

> We are still keeping crc16.c file in fs/ext4 because the lib/crc16.c file ( Poly - x^16 + x^12 + x^5 + 1)
> is not compatible with Linux kernel crc implementation (Poly - x^16 + x^15 + x^2 + 1).

I see that now - lib/crc16.c implements the CCITT version, whereas
it appears filesystems use the IBM/ANSI polynomials.

> Also, fs/ubifs/crc16.c
> is also giving some errors.

strange - ubifs uses the same polynomial.  I diffed fs/ubifs/crc16.c
and linux' lib/crc16.c, and found no difference in the table.  Is
there a possibility of an endianness problem, or that the test was
based on data a prior CCITT test wrote?

> Kernel does not mount the partition if we use this particular crc file. Hence, we are keeping
> the existing crc16.c file.

setting the standard for new filesystem implementations to do the
same?

The implementations should be cleaned up before too many
duplications occur - linux calls the IBM/ANSI version plain 'crc16',
and the CCITT version crc-ccitt (linux/lib/crc-ccitt.c). Is it
possible instead to move u-boot's ubifs implementation into
lib/crc16.c, and the current u-boot lib/crc16.c be renamed
lib/crc-ccitt.c?

Thanks,

Kim

[1] http://en.wikipedia.org/wiki/Crc16



More information about the U-Boot mailing list