[PATCH 5/9] lib: Import reed solomon code from kernel

Markus Pargmann mpa at pengutronix.de
Fri Dec 4 05:22:41 PST 2015


Hi,

On Friday 04 December 2015 08:12:55 Sascha Hauer wrote:
> On Wed, Dec 02, 2015 at 02:48:47PM +0100, Markus Pargmann wrote:
> > reed solomon code is used by RAMOOPS to check and fix data stored in
> > volatile memory.
> > 
> > Signed-off-by: Markus Pargmann <mpa at pengutronix.de>
> > ---
> >  include/linux/rslib.h           | 109 ++++++++++++
> >  lib/Kconfig                     |  15 ++
> >  lib/Makefile                    |   1 +
> >  lib/reed_solomon/Makefile       |   6 +
> >  lib/reed_solomon/decode_rs.c    | 271 +++++++++++++++++++++++++++++
> >  lib/reed_solomon/encode_rs.c    |  54 ++++++
> >  lib/reed_solomon/reed_solomon.c | 377 ++++++++++++++++++++++++++++++++++++++++
> >  7 files changed, 833 insertions(+)
> >  create mode 100644 include/linux/rslib.h
> >  create mode 100644 lib/reed_solomon/Makefile
> >  create mode 100644 lib/reed_solomon/decode_rs.c
> >  create mode 100644 lib/reed_solomon/encode_rs.c
> >  create mode 100644 lib/reed_solomon/reed_solomon.c
> > 
> 
> > diff --git a/lib/Kconfig b/lib/Kconfig
> > index fbf9f0f34849..f2f3b5775ace 100644
> > --- a/lib/Kconfig
> > +++ b/lib/Kconfig
> > @@ -22,6 +22,21 @@ config XZ_DECOMPRESS
> >  	bool "include xz uncompression support"
> >  	select UNCOMPRESS
> >  
> > +config REED_SOLOMON
> > +	bool
> > +
> > +config REED_SOLOMON_ENC8
> > +	bool
> > +
> > +config REED_SOLOMON_DEC8
> > +	bool
> > +
> > +config REED_SOLOMON_ENC16
> > +	bool
> > +
> > +config REED_SOLOMON_DEC16
> > +	bool
> > +
> 
> These fine grained config options seem unnecessary. Can we limit this to
> a single config REED_SOLOMON only? The linker will discard unused
> symbols anyway.

Ok, I reduced this to just the single config symbol 'REED_SOLOMON'.

Best Regards,

Markus

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.infradead.org/pipermail/barebox/attachments/20151204/858d652a/attachment.sig>


More information about the barebox mailing list