From 9759c60f1a1503e48dc5c45a209c3edd5758319f Mon Sep 17 00:00:00 2001 From: Eric Dillmann Date: Wed, 23 Jan 2013 10:54:30 +0100 Subject: Illumos #3035 LZ4 compression support in ZFS and GRUB 3035 LZ4 compression support in ZFS and GRUB Reviewed by: Matthew Ahrens Reviewed by: Christopher Siden Reviewed by: George Wilson Approved by: Christopher Siden References: illumos/illumos-gate@a6f561b4aee75d0d028e7b36b151c8ed8a86bc76 https://www.illumos.org/issues/3035 http://wiki.illumos.org/display/illumos/LZ4+Compression+In+ZFS This patch has been slightly modified from the upstream Illumos version to be compatible with Linux. Due to the very limited stack space in the kernel a lz4 workspace kmem cache is used. Since we are using gcc we are also able to take advantage of the gcc optimized __builtin_ctz functions. Support for GRUB has been dropped from this patch. That code is available but those changes will need to made to the upstream GRUB package. Lastly, several hunks of dead code were dropped for clarity. They include the functions real_LZ4_uncompress(), LZ4_compressBound() and the Visual Studio specific hunks wrapped in _MSC_VER. Ported-by: Eric Dillmann Signed-off-by: Brian Behlendorf Closes #1217 --- lib/libzpool/Makefile.am | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/libzpool/Makefile.am b/lib/libzpool/Makefile.am index 1285af325..3e62de637 100644 --- a/lib/libzpool/Makefile.am +++ b/lib/libzpool/Makefile.am @@ -48,6 +48,7 @@ libzpool_la_SOURCES = \ $(top_srcdir)/module/zfs/fm.c \ $(top_srcdir)/module/zfs/gzip.c \ $(top_srcdir)/module/zfs/lzjb.c \ + $(top_srcdir)/module/zfs/lz4.c \ $(top_srcdir)/module/zfs/metaslab.c \ $(top_srcdir)/module/zfs/refcount.c \ $(top_srcdir)/module/zfs/rrwlock.c \ -- cgit v1.2.3