aboutsummaryrefslogtreecommitdiffstats
path: root/config
Commit message (Collapse)AuthorAgeFilesLines
...
| * Remove get_vmalloc_info() wrapperBrian Behlendorf2014-10-171-39/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The get_vmalloc_info() function was used to back the vmem_size() function. This was always problematic and resulted in brittle code because the kernel never provided a clean interface for modules. However, it turns out that the only caller of this function in ZFS uses it to determine the total virtual address space size. This can be determined easily without get_vmalloc_info() so vmem_size() has been updated to take this approach which allows us to shed the get_vmalloc_info() dependency. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove on_each_cpu() wrapperBrian Behlendorf2014-10-171-23/+0
| | | | | | | | | | | | | | The on_each_cpu() function has been available since Linux 2.6.27. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove mutex_lock_nested() wrapperBrian Behlendorf2014-10-171-24/+0
| | | | | | | | | | | | | | The mutex_lock_nested() function has been available since Linux 2.6.18. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove i_mutex() configure checkBrian Behlendorf2014-10-171-21/+0
| | | | | | | | | | | | | | | | | | | | | | The inode structure has used i_mutex as its internal locking primitive since 2.6.16. The compatibility code to check for the previous semaphore primitive has been removed. However, the wrapper function itself is being kept because it's entirely possible this primitive will change again to allow finer grained locking. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove kmalloc_node() compatibility codeBrian Behlendorf2014-10-171-20/+0
| | | | | | | | | | | | | | The kmalloc_node() function has been available since Linux 2.6.12. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove linux/uaccess.h header checkBrian Behlendorf2014-10-171-9/+0
| | | | | | | | | | | | | | | | The uaccess header has been available in the same location since Linux 2.6.18. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove uintptr_t typedefBrian Behlendorf2014-10-171-20/+0
| | | | | | | | | | | | | | The uintptr_t typedef has been available since Linux 2.6.24. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove atomic64_xchg() wrappersBrian Behlendorf2014-10-171-40/+0
| | | | | | | | | | | | | | | | The atomic64_xchg() and atomic64_cmpxchg() functions have been available since Linux 2.6.24. There is no longer a need to maintain this compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Simplify the time compatibility wrappersBrian Behlendorf2014-10-171-84/+0
| | | | | | | | | | | | | | | | | | | | Many of the time functions had grown overly complex in order to handle kernel compatibility issues. However, as of Linux 2.6.26 all the required functionality is available. This allows us to retire numerous configure checks and greatly simplify the time compatibility wrappers. Signed-off-by: Brian Behlendorf <[email protected]>
| * Map highbit64() to fls64()Brian Behlendorf2014-10-171-19/+0
| | | | | | | | | | | | | | | | The fls64() function has been available since Linux 2.6.16 and it should be used to implemented highbit64(). This allows us to provide an optimized implementation and simplify the code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove CTL_UNNUMBERED sysctl interfaceBrian Behlendorf2014-10-171-22/+0
| | | | | | | | | | | | | | | | | | Support for the CTL_UNNUMBERED sysctl interface was removed in Linux 2.6.19. There is no longer any reason to maintain this compatibility code. There also issue any reason to keep around the CTL_NAME macro and helpers so they have been retired. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove register_sysctl() compatibility codeBrian Behlendorf2014-10-171-20/+0
| | | | | | | | | | | | | | The register_sysctl() interface has been stable since Linux 2.6.21. There is no longer a need to maintain compatibility code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove utsname() wrapperBrian Behlendorf2014-10-171-20/+0
| | | | | | | | | | | | | | | | | | There is no longer a need to wrap this because utsname() is provided by the kernel and can be called directly. This will require a small change in the ZFS code because utsname is expected to be a global structure and not a function. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove adaptive mutex implementationBrian Behlendorf2014-10-171-19/+3
| | | | | | | | | | | | | | | | Since the Linux 2.6.29 kernel all mutexes have been adaptive mutexs. There is no longer any point in keeping this code so it is being removed to simplify the code. Signed-off-by: Brian Behlendorf <[email protected]>
| * Update code to use misc_register()/misc_deregister()Brian Behlendorf2014-10-171-61/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the SPL was originally written it was designed to use the device_create() and device_destroy() functions. Unfortunately, these functions changed considerably over the years making them difficult to rely on. As it turns out a better choice would have been to use the misc_register()/misc_deregister() functions. This interface for registering character devices has remained stable, is simple, and provides everything we need. Therefore the code has been reworked to use this interface. The higher level ZFS code has always depended on these same interfaces so this is also as a step towards minimizing our kernel dependencies. Signed-off-by: Brian Behlendorf <[email protected]>
| * Make license compatibility checks consistentBrian Behlendorf2014-10-172-5/+26
| | | | | | | | | | | | | | Apply the license specified in the META file to ensure the compatibility checks are all performed consistently. Signed-off-by: Brian Behlendorf <[email protected]>
| * Cleanup vn_rename() and vn_remove()Richard Yao2014-08-131-68/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | zfsonlinux/spl#bcb15891ab394e11615eee08bba1fd85ac32e158 implemented Linux 3.6+ support by adding duplicate vn_rename and vn_remove functions. The new ones were cleaner, but the duplicate functions made the codebase less maintainable. This adds some compatibility shims that allow us to retire the older vn_rename and vn_remove in favor of the new ones on old kernels. The result is a net 143 line reduction in lines of code and a cleaner codebase. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #370
| * Linux 3.17 compat: remove wait_on_bit action functionNed Bass2014-08-111-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Linux kernel 3.17 removes the action function argument from wait_on_bit(). Add autoconf test and compatibility macro to support the new interface. The former "wait_on_bit" interface required an 'action' function to be provided which does the actual waiting. There were over 20 such functions in the kernel, many of them identical, though most cases can be satisfied by one of just two functions: one which uses io_schedule() and one which just uses schedule(). This API change was made to consolidate all of those redundant wait functions. References: torvalds/linux@7431620 Signed-off-by: Ned Bass <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #378
| * Set LANG to a reasonable default (C)Turbo Fredriksson2014-06-101-2/+2
| | | | | | | | | | | | | | | | | | Set LANG=C before calling 'rpmbuild' to avoid rpmbuild failing on the translated date string in the changelog. Signed-off-by: Turbo Fredriksson <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #306
| * Restrict release number to META versionBrian Behlendorf2014-05-291-1/+1
| | | | | | | | | | | | | | | | | | | | When creating packages in a git repository the release number can be automatically set by 'git describe'. This normally works well but if your repository has newer tags which match the form NAME-VERSION* the release may be incorrectly calculated. To prevent this the match patten has been restricted to NAME-VERSION. Signed-off-by: Brian Behlendorf <[email protected]>
| * Add KMC_SLAB cache typeBrian Behlendorf2014-05-221-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For small objects the Linux slab allocator has several advantages over its counterpart in the SPL. These include: 1) It is more memory-efficient and packs objects more tightly. 2) It is continually tuned to maximize performance. Therefore it makes sense to layer the SPLs slab allocator on top of the Linux slab allocator. This allows us to leverage the advantages above while preserving the Illumos semantics we depend on. However, there are some things we need to be careful of: 1) The Linux slab allocator was never designed to work well with large objects. Because the SPL slab must still handle this use case a cut off limit was added to transition from Linux slab backed objects to kmem or vmem backed slabs. spl_kmem_cache_slab_limit - Objects less than or equal to this size in bytes will be backed by the Linux slab. By default this value is zero which disables the Linux slab functionality. Reasonable values for this cut off limit are in the range of 4096-16386 bytes. spl_kmem_cache_kmem_limit - Objects less than or equal to this size in bytes will be backed by a kmem slab. Objects over this size will be vmem backed instead. This value defaults to 1/8 a page, or 512 bytes on an x86_64 architecture. 2) Be aware that using the Linux slab may inadvertently introduce new deadlocks. Care has been taken previously to ensure that all allocations which occur in the write path use GFP_NOIO. However, there may be internal allocations performed in the Linux slab which do not honor these flags. If this is the case a deadlock may occur. The path forward is definitely to start relying on the Linux slab. But for that to happen we need to start building confidence that there aren't any unexpected surprises lurking for us. And ideally need to move completely away from using the SPLs slab for large memory allocations. This patch is a first step. NOTES: 1) The KMC_NOMAGAZINE flag was leveraged to support the Linux slab backed caches but it is not supported for kmem/vmem backed caches. 2) Regardless of the spl_kmem_cache_*_limit settings a cache may be explicitly set to a given type by passed the KMC_KMEM, KMC_VMEM, or KMC_SLAB flags during cache creation. 3) The constructors, destructors, and reclaim callbacks are all functional and will be called regardless of the cache type. 4) KMC_SLAB caches will not appear in /proc/spl/kmem/slab due to the issues involved in presenting correct object accounting. Instead they will appear in /proc/slabinfo under the same names. 5) Several kmem SPLAT tests needed to be fixed because they relied incorrectly on internal kmem slab accounting. With the updated test cases all the SPLAT tests pass as expected. 6) An autoconf test was added to ensure that the __GFP_COMP flag was correctly added to the default flags used when allocating a slab. This is required to ensure all pages in higher order slabs are properly refcounted, see ae16ed9. 7) When using the SLUB allocator there is no need to attempt to set the __GFP_COMP flag. This has been the default behavior for the SLUB since Linux 2.6.25. 8) When using the SLUB it may be desirable to set the slub_nomerge kernel parameter to prevent caches from being merged. Original-patch-by: DHE <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Signed-off-by: Prakash Surya <[email protected]> Signed-off-by: Tim Chase <[email protected]> Signed-off-by: DHE <[email protected]> Signed-off-by: Chunwei Chen <[email protected]> Closes #356
| * Linux 3.15: vfs_rename() added a flags argumentChunwei Chen2014-05-071-1/+22
| | | | | | | | | | | | | | | | | | | | | | | | Detect the updated vfs_rename() interface and call it with an extra flags argument. References: torvalds/linux@520c8b1 Signed-off-by: Chunwei Chen <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Issue #355
| * Linux 3.13 compat: Pass NULL for new delegated inode argumentRichard Yao2013-12-021-10/+42
| | | | | | | | | | | | | | | | | | | | | | | | This check was originally added for SLES10, a093c6a, to check for a 'struct vfsmount *' argument which they added. However, since SLES10 is based on a 2.6.16 kernel which is no longer supported this functionality was dropped. The checks were refactored to support Linux 3.13 without concern for historical versions. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #312
| * Linux 3.12 compat: New shrinker APIRichard Yao2013-11-061-30/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | torvalds/linux@24f7c6 introduced a new shrinker API while torvalds/linux@a0b021 dropped support for the old shrinker API. This patch adds support for the new shrinker API by wrapping the old one with the new one. This change also reorganizes the autotools checks on the shrinker API such that the configure script will fail early if an unknown API is encountered in the future. Support for the set_shrinker() API which was used by Linux 2.6.22 and older has been dropped. As a general rule compatibility is only maintained back to Linux 2.6.26. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes zfsonlinux/zfs#1732 Closes zfsonlinux/zfs#1822 Closes #293 Closes #307
| * Emulate illumos interface cv_timedwait_hires()Ned Bass2013-11-041-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Needed for Illumos #3582. This interface is supposed to support a variable-resolution timeout with nanosecond granularity. This implementation rounds up to microsecond resolution, as nanosecond- precision timing is rarely needed for real-world performance tuning and may incur unnecessary busy-waiting. usleep_range() is used if available, otherwise udelay() or msleep() are used depending on the length of the delay interval. Add flags from sys/callo.h as these are used to control the behavior of cv_timedwait_hires(). Specifically, CALLOUT_FLAG_ABSOLUTE Normally, the expiration passed to the timeout API functions is an expiration interval. If this flag is specified, then it is interpreted as the expiration time itself. CALLOUT_FLAG_ROUNDUP Roundup the expiration time to the next resolution boundary. If this flag is not specified, the expiration time is rounded down. References: https://www.illumos.org/issues/3582 illumos/illumos-gate@0689f76 Signed-off-by: Brian Behlendorf <[email protected]> Closes #304
| * Linux 3.8 compat: Use kuid_t/kgid_t when requiredRichard Yao2013-08-091-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When CONFIG_UIDGID_STRICT_TYPE_CHECKS is enabled uid_t/git_t are replaced by kuid_t/kgid_t, which are structures instead of integral types. This causes any code that uses an integral type to fail to build. The User Namespace functionality introduced in Linux 3.8 requires CONFIG_UIDGID_STRICT_TYPE_CHECKS, so we could not build against any kernel that supported it. We resolve this by converting between the new kuid_t/kgid_t structures and the original uid_t/gid_t types. Original-patch-by: DHE Rewrite-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #260
| * Linux 3.10 compat: replace PDE()->data with PDE_DATA()Yuxuan Shui2013-07-081-0/+19
| | | | | | | | | | | | | | | | | | | | | | Linux kernel commit torvalds/linux@d9dda78b renamed PDE() to PDE_DATA(). To handle this detect the prefered interface and define a PDE_DATA() wrapper for consistency. Signed-off-by: Yuxuan Shui <[email protected]> Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Issue #257
| * Linux 3.10 compat: struct vmalloc_info movedYuxuan Shui2013-07-081-0/+20
| | | | | | | | | | | | | | | | | | | | Linux kernel commmit torvalds/linux@db3808c1 moved the vmalloc_info structure from a private to a public header. Now that it's available for kernel modules use it. Signed-off-by: Yuxuan Shui <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Issue #257
| * Add --bump=0 to alienTurbo Fredriksson2013-04-241-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Preserve the release field when creating Debian packages. The --keep-version option was not used because it results in a failure when the git '<commit>_<hash>' syntax is used for the release. The '_' is a valid character for RPM packages but not for DEBs. Signed-off-by: Brian Behlendorf <[email protected]> Signed-off-by: Turbo Fredriksson <[email protected]> Issue zfsonlinux/zfs#1402 Issue zfsonlinux/zfs#928
| * Support .nogitrelease fileTurbo Fredriksson2013-04-241-1/+1
| | | | | | | | | | | | | | | | | | When building a custom release in a git tree provide the ability to prevent the release field from being overwritten by the `git describe` output. Signed-off-by: Brian Behlendorf <[email protected]> Issue zfsonlinux/zfs#1402
| * Replace the SPL_AC_META perl dependency with awkBrian Behlendorf2013-04-021-30/+55
| | | | | | | | | | | | | | | | | | The only remaining perl dependency is part of the SPL_AC_META macro. By eliminating this and replacing it with awk we can avoid the need to pull in perl to rebuild the packages. Signed-off-by: Brian Behlendorf <[email protected]> Issue zfsonlinux/zfs#1380
| * build: do not call boilerplate ourselfJan Engelhardt2013-04-021-0/+2
| | | | | | | | | | | | | | | | Rationale see section 3.5 "Using `autoreconf' to Update `configure' Scripts" of the autoconf manual. Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * gitignore: anchor entries at their respective directoryJan Engelhardt2013-04-021-6/+6
| | | | | | | | | | | | | | .ko is specific to module, .m4 to config, etc. Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * build: use CPPFLAGSJan Engelhardt2013-04-021-1/+2
| | | | | | | | | | | | | | | | -D and -I are preprocessor flags, so should preferably be in the appropriate variable. Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * build: resolve orthographic and other grammatical errorsJan Engelhardt2013-04-021-4/+4
| | | | | | | | | | Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Use 'git describe' for working buildsBrian Behlendorf2013-03-221-4/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When building from an arbitrary commit in the git tree it's useful for the resulting packages to be uniquely identifiable. Therefore, the build system has been updated to detect if your compiling in git tree. If you are building in a git tree, and there are commits after the last annotated tag. Then the <id>-<hash> component of 'git describe' will be used to overwrite the 'Release:' field in the META file. The only tricky part is that to ensure the 'make dist' tarball is built using the correct release. A dist-hook was added to the top level make file to rewrite the META file using the correct release. Signed-off-by: Brian Behlendorf <[email protected]> Closes #195 Issue #111
| * Refresh RPM packagingBrian Behlendorf2013-03-185-80/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refresh the existing RPM packaging to conform to the 'Fedora Packaging Guidelines'. This includes adopting the kmods2 packaging standard which is used fod kmods distributed by rpmfusion for Fedora/RHEL. http://fedoraproject.org/wiki/Packaging:Guidelines http://rpmfusion.org/Packaging/KernelModules/Kmods2 While the spec files have been entirely rewritten from a user perspective the only major changes are: * The Fedora packages now have a build dependency on the rpmfusion repositories. The generic kmod packages also have a new dependency on kmodtool-1.22 but it is bundled with the source rpm so no additional packages are needed. * The kernel binary module packages have been renamed from spl-modules-* to kmod-spl-* as specificed by kmods2. * The is now a common kmod-spl-devel-* package in addition to the per-kernel devel packages. The common package contains the development headers while the per-kernel package contains kernel specific build products. Signed-off-by: Brian Behlendorf <[email protected]> Closes #222
| * Drop support for 3 argument version of set_fs_pwdRichard Yao2013-03-141-24/+0
| | | | | | | | | | | | | | | | | | | | This was a suggestion that Brian Behlendorf made when reviewing an early pull request for Linux 3.9 support. This commit was made intentionally easy to revert should we ever have a reason to reintroduce support for older kernels. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Linux 3.9 compat: set_fs_root takes const struct path *Richard Yao2013-03-141-0/+44
| | | | | | | | | | | | | | | | torvalds/linux@dcf787f39162ce32ca325b3e784aba2d2444619a enforces const-correctness in passing struct path *. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Linux 3.9 compat: vfs_getattr takes two argumentsRichard Yao2013-03-141-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | The function prototype of vfs_getattr previoulsy took struct vfsmount * and struct dentry * as arguments. These would always be defined together in a struct path *. torvalds/linux@3dadecce20603aa380023c65e6f55f108fd5e952 modified vfs_getattr to take struct path * is taken as an argument instead. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Linux 3.9 compat: Include linux/sched/rt.hRichard Yao2013-03-141-0/+20
| | | | | | | | | | | | | | | | | | Linux 3.9 reorganized sched.h, splitting it into numerous files. torvalds/linux@8bd75c77b7c6a3954140dd2e20346aef3efe4a35 moved MAX_PRIO and MAX_RT_PRIO to linux/sched/rt.h. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove ARCH packagingBrian Behlendorf2013-03-042-89/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The kernel modules are now available in the Arch User Repository (AUR) via zfs. Since their packaging is maintained and superior to ours it is being removed from the tree. https://wiki.archlinux.org/index.php/ZFS Now that various distributions are picking up the packages we should eventually be able to remove most of this infrastructure. Packaging belongs with the distributions not upstream. Signed-off-by: Brian Behlendorf <[email protected]>
| * Fix HAVE_MUTEX_OWNER_TASK_STRUCT autotools check on PPC64Richard Yao2013-02-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | The HAVE_MUTEX_OWNER_TASK_STRUCT fails on PPC64 with the following error: error: 'current' undeclared (first use in this function) We include linux/sched.h to ensure that current is available. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
| * Fix atomic64_* autoconf checksBrian Behlendorf2013-02-051-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The SPL_AC_ATOMIC_SPINLOCK, SPL_AC_TYPE_ATOMIC64_CMPXCHG, and SPL_AC_TYPE_ATOMIC64_XCHG were all directly including the 'asm/atomic.h' header. As of Linux 3.4 this header was removed which results in a build failure. The right thing to do is include 'linux/atomic.h' however we can't safely do this because it doesn't exist in 2.6.26 kernels. Therefore, we include 'linux/fs.h' which in turn includes the correct atomic header regardless of the kernel version. When these incorrect APIs are used in ZFS the following build failure results. arc.c:791:80: warning: '__ret' may be used uninitialized in this function [-Wuninitialized] arc.c:791:1875: error: call to '__cmpxchg_wrong_size' declared with attribute error: Bad argument size for cmpxchg Since this is all Linux 2.6.24 compatibility code there's an argument to be made that it should be removed because kernels this old are not supported. However, because we're so close to a release I'm going to leave it in place for now. Signed-off-by: Brian Behlendorf <[email protected]> Closes zfsonlinux/zfs#814 Closes zfsonlinux/zfs#1254
| * Check for KALLSYMSBrian Behlendorf2013-01-291-0/+21
| | | | | | | | | | | | | | | | | | | | | | Check at ./configure time that the kernel was built with kallsyms support. If the kernel doesn't have CONFIG_KALLSYMS defined the modules will still compile cleanly but will not be loadable. So we really want to catch this early during ./configure. Note that we do not require CONFIG_KALLSYMS_ALL but it may be safely defined. Signed-off-by: Brian Behlendorf <[email protected]> Closes #6
| * Remove spl_invalidate_inodes()Brian Behlendorf2013-01-171-74/+0
| | | | | | | | | | | | | | | | | | | | | | This functionality is no longer required by ZFS, see commit zfsonlinux/zfs@7b3e34ba5a7ee8d0fda44d214f6f11eb16cdb26f. Since there are no other consumers, and because it adds additional autoconf complexity which must be maintained the spl_invalidate_inodes() function has been removed. Signed-off-by: Brian Behlendorf <[email protected]> Issue zfsonlinux/zfs#795
| * Check for ZLIB_INFLATE and ZLIB_DEFLATEBrian Behlendorf2013-01-091-0/+44
| | | | | | | | | | | | | | | | | | | | Check at ./configure time that the kernel was built with zlib support enabled. This support may either be configured as a module or builtin to the kernel. But if it's missing the build will fail so it's best to catch this early. Signed-off-by: Brian Behlendorf <[email protected]> Closes zfsonlinux/zfs#582
| * Linux compat 3.7.1, on_each_cpu()Brian Behlendorf2013-01-091-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some kernels require that we include the 'linux/irqflags.h' header for the SPL_AC_3ARGS_ON_EACH_CPU check. Otherwise, the functions local_irq_enable()/local_irq_disable() will not be defined and the prototype will be misdetected as the four argument version. This change actually include 'linux/interrupt.h' which in turn includes 'linux/irqflags.h' to be as generic as possible. Additionally, passing NULL as the function can result in a gcc error because the on_each_cpu() macro executes it unconditionally. To make the test more robust we pass the dummy function on_each_cpu_func(). Signed-off-by: Brian Behlendorf <[email protected]> Closes #204
| * RHEL 6.4 compat, fallocate()Brian Behlendorf2013-01-081-2/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the upstream kernel the FALLOC_FL_PUNCH_HOLE #define was introduced after the fallocate() function was moved from the inode_operations to the file_operations structure. Therefore, the SPL code assumed that if FALLOC_FL_PUNCH_HOLE was defined it was safe to use f_ops->fallocate(). Unfortunately, the RHEL6.4 kernel has only backported the FALLOC_FL_PUNCH_HOLE #define and not the fallocate() change. To address this compatibility issue the spl_filp_fallocate() helper function was added to properly detect which interface is available. Signed-off-by: Brian Behlendorf <[email protected]>
| * Removed SPL_AC_3ARGS_INIT_WORK checkBrian Behlendorf2012-12-121-21/+0
| | | | | | | | | | | | | | | | | | All consumers of the kernel delayed work queues have been shifted over to rely on the taskq implementation. This compatibility code can now be removed. Any new callers which need this functionality should use the taskq interfaces for delayed work items. Signed-off-by: Brian Behlendorf <[email protected]>