-
Thomas Gleixner authored
The attached patch contains a shared Reed-Solomon Library analogous to the shared zlib. (N)AND FLASH is gaining popularity and there are a lot of ASIC/SoC/FPGA controllers around which implement hardware support for Reed-Solomon error correction. As usual they use different implementations (polynomials etc.). So it's obvious to use a shared library for the common tasks of error correction. A short scan through the kernel revealed that at least the ftape driver uses Reed-Solomon error correction. It could be easily converted to use the shared library code. The encoder/decoder code is lifted from the GPL'd userspace RS-library written by Phil Karn. I modified/wrapped it to provide the different functions which we need in the MTD/NAND code. The library is tested in extenso under various MTD/NAND configurations. The lib should be usable for other purposes right out of the box. Adjustment for currently not implemented functionality is an easy task. I'm willing to take the maintainership of the library. Signed-Off-By: Thomas Gleixner <tglx@linutronix.de> Signed-Off-By: David Woodhouse <dwmw2@infradead.org> "No objections at all. Just keep the authorship notices." -- Phil Karn
15b54237