FreeBSD src
Go to file
Ned Bass de39ec11b8 Fix LZ4 endianness autodetection
Endianness detection in LZ4 is broken in user-space builds.  This
bug corrupts compressed data and manifests itself in several ztest
failures.  When LZ4 was originally ported to Illumos ZFS, the proper
checks for Linux were stripped out. The Linux port then inherited
the remaining detection code that works on Illumos but not on Linux.

The current LZ4 endianness check misuses the condition
defined(__BIG_ENDIAN) to indicate a big-endian system.  On Linux
__BIG_ENDIAN is defined uncondtionally in the user-space header
/usr/include/endian.h, regardless of the endianness of the system.
The kernel does not use this header, so only user-space builds are
affected.

While we could fix this by restoring the upstream LZ4 endianness
detection code, reliable checks already exist in
libspl/include/sys/isa_defs.h. This change uses the libspl results
to replace the word-size and endianness checks in LZ4, simplifying
the code and reducing duplication.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Signed-off-by: Chunwei Chen <tuxoko@gmail.com>
Signed-off-by: DHE <git@dehacked.net>
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Fixes #1963
Fixes #1964
Fixes #1965
2014-04-20 16:55:42 -07:00
cmd Replace zed_file_create_dirs() with mkdirp() 2014-04-09 13:32:54 -07:00
config Linux 3.14 compat: rq_for_each_segment in dmu_req_copy 2014-04-10 14:28:51 -07:00
dracut Refresh dracut module setup 2013-03-21 12:51:06 -07:00
etc Allow specifying '-o <opts>' in defaults/init script. 2014-04-04 09:49:09 -07:00
include Use ddi_time_after and friends to compare time 2014-04-14 13:27:56 -07:00
lib Report atime and relatime as the property's actual value. 2014-04-16 11:57:17 -07:00
man Initial implementation of zed (ZFS Event Daemon) 2014-04-02 13:10:03 -07:00
module Fix LZ4 endianness autodetection 2014-04-20 16:55:42 -07:00
patches Adding grub2 mkconfig support patch 2012-07-30 16:17:23 -07:00
rpm Initial implementation of zed (ZFS Event Daemon) 2014-04-02 13:10:03 -07:00
scripts Various zimport.sh fixes 2014-04-17 09:30:55 -07:00
udev Open pools asynchronously after module load 2013-07-03 09:24:38 -07:00
.gitignore Ignore *.{deb,rpm,tar.gz} files in the top directory. 2013-04-24 16:18:59 -07:00
.gitmodules Add zimport.sh compatibility test script 2014-02-21 12:10:31 -08:00
AUTHORS Fix minor typos and update marketing copy. 2013-03-21 12:51:06 -07:00
autogen.sh build: do not call boilerplate ourself 2013-04-02 10:55:20 -07:00
configure.ac Initial implementation of zed (ZFS Event Daemon) 2014-04-02 13:10:03 -07:00
copy-builtin Consistent menuconfig name 2012-08-26 13:49:37 -07:00
COPYRIGHT Refresh links to web site 2013-03-06 15:46:41 -08:00
DISCLAIMER Fix minor typos and update marketing copy. 2013-03-21 12:51:06 -07:00
Makefile.am cstyle: Exclude several files from 'make checkstyle' 2013-12-18 16:46:35 -08:00
META Tag zfs-0.6.2 2013-08-22 13:33:26 -07:00
OPENSOLARIS.LICENSE Add CDDL license file 2008-12-01 14:49:34 -08:00
README.markdown Fix minor typos and update marketing copy. 2013-03-21 12:51:06 -07:00
zfs-script-config.sh.in Initial implementation of zed (ZFS Event Daemon) 2014-04-02 13:10:03 -07:00
zfs.release.in Move zfs.release generation to configure step 2012-07-12 12:22:51 -07:00

Native ZFS for Linux!

ZFS is an advanced file system and volume manager which was originally developed for Solaris and is now maintained by the Illumos community.

ZFS on Linux, which is also known as ZoL, is currently feature complete. It includes fully functional and stable SPA, DMU, ZVOL, and ZPL layers.

Full documentation for installing ZoL on your favorite Linux distribution can be found at: http://zfsonlinux.org