[PATCH v0] mkfs.ubifs: Add support for lz4hc compressor in mkfs.ubifs

Elie De Brauwer eliedebrauwer at gmail.com
Sat Oct 5 05:56:19 PDT 2013


On Sat, Oct 5, 2013 at 1:53 PM, Konstantin Tokarev <annulen at yandex.ru> wrote:
>
>
> 05.10.2013, 10:53, "Elie De Brauwer" <eliedebrauwer at gmail.com>:
>> Brent et all,
>>
>> I was bored last night and while following the thread on the lz4hc
>> compression for ubifs got my attention so I decided to give a go at
>> implementing in. Below you can find a patch which does just that.
>>
>> An lz4hc and favor_lz4hc compr type, they mimick lzo and favor_lzo
>> but use lz4hc instead of lzo.
>>
>> In order to use lz4hc I included 3 files from the lz4 project since
>> lz4 is not yet available in a conventient modular form (suggestions
>> to fix this are welcome).
>>
>> In the meantime I saw however that Brent was also considering adding
>> lz4hc support mkfs.ubifs so I'm making a v0 zero post either to serve
>> as input for review comment (mainly on handling the lz4 dependency)
>> and then I'll take care of cleaning up and testing it myself, or just
>> to serve as some reference to the implementation of Brent, let me know
>> of you want some polishing up on this version or are already in an
>> advanced phase of a solution of yourself.
>>
>> (Yes, it's called v0, it's still untested but I would like input on
>> the lz4 dependency handling and the extension of the options, or
>> do we see something feasible where we contain lzo/lz4hc and zlib on
>> the fly, suggestions welcome).
>>
>> my 2 cents
>> E.
>
> Thank you very much!
>
> Unfortunately, your patch does not apply cleanly. I've tried mtd-utils
> master and v1.5.0, and got rejects in both cases.
>

That's odd, yesterday I started by cloning mtd-utils.git and when I
try to repeat my own steps and apply my patch it does seem to work.

edb at lapelidb:/tmp$ mkdir l
edb at lapelidb:/tmp$ cd l/
edb at lapelidb:/tmp/l$ git clone -q git://git.infradead.org/mtd-utils.git
edb at lapelidb:/tmp/l$ cd mtd-utils/
edb at lapelidb:/tmp/l/mtd-utils$ patch -p1 <
/tmp/0001-mkfs.ubifs-Add-support-for-lz4hc-compressor-in-mkfs..patch
patching file Makefile
patching file mkfs.ubifs/README
patching file mkfs.ubifs/compr.c
patching file mkfs.ubifs/compr.h
patching file mkfs.ubifs/lz4/lz4.h
patching file mkfs.ubifs/lz4/lz4hc.c
patching file mkfs.ubifs/lz4/lz4hc.h
patching file mkfs.ubifs/mkfs.ubifs.c
patching file mkfs.ubifs/ubifs-media.h
patching file mkfs.ubifs/ubifs.h
edb at lapelidb:/tmp/l/mtd-utils$

The only thing I can imagine is that I started from a wrong repository
... any pointers ?

gr
E.



-- 
Elie De Brauwer



More information about the linux-mtd mailing list