]> git.proxmox.com Git - mirror_spl-debian.git/commit - module/splat/splat-internal.h
Add linux compatibility tests
authorBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 21 Jun 2011 17:57:48 +0000 (10:57 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 21 Jun 2011 21:02:46 +0000 (14:02 -0700)
commitbf0c60c060ac58c9bb835cb62b49f0cb68bb68e4
tree553c2ce768a14ea1765aaca0664e56548bdbac19
parenta55bcaad181096d764e12d847e3091cd7b15509a
Add linux compatibility tests

While the splat tests were originally designed to stress test
the Solaris primatives.  I am extending them to include some kernel
compatibility tests.  Certain linux APIs have changed frequently.
These tests ensure that added compatibility is working properly
and no unnoticed regression have slipped in.

Test 1 and 2 add basic regression tests for shrink_icache_memory
and shrink_dcache_memory.  These are simply functional tests to
ensure we can call these functions safely.  Checking for correct
behavior is more difficult since other running processes will
influence the behavior.  However, these functions are provided
by the kernel so if we can successfully call them we assume they
are working correctly.

Test 3 checks that shrinker functions are being registered and
called correctly.  As of Linux 3.0 the shrinker API has changed
four different times so I felt the need to add a trivial test
case to ensure each variant works as expected.
include/splat-ctl.h
module/splat/Makefile.in
module/splat/splat-ctl.c
module/splat/splat-internal.h
module/splat/splat-linux.c [new file with mode: 0644]