Go to file
Steven Johnson 9b88fa165f splat taskq:front: Fix race
The taskq:front test has a race condition where task 4 and 8
race to complete, due to an incorrectly calculated set of delay
"factors" (T). If task 4 wins and actually finishes first, the
verification of the order of completion will fail.

The delays calculated to order task completion do not take into
account the terminal line in the table, and so are all off by
a factor of 1. This causes all the tasks in all queues to finish
sooner than expected and the accumulated error is the root cause
of tasks 4 and 8 racing to complete first. Before the change the
"actual" table looks like I commented in #130.

I changed:

* the table in the comment to correctly reflect the test and the
  factor timings needed.
* the individual task delay factors of T so that ONLY 1 task will
  every 2T. (on average)
* 1T was reduced from 100ms to 50ms. This halves the duration of
  the test and makes any remaining raciness more likely to cause
  failures, but it did not cause the test to fail.
* simplified the delay factor logic by using a table look-up
  instead of a switch.
* Added a "task started" message so that with -v it is possible
  to see the order tasks are started.
* Moved the "task completed" message inside the spinlock so that
  with -v the message truly reflects the absolute order of
  completion as guaranteed by the spinlock.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #130
2012-12-05 12:23:40 -08:00
cmd Remove autotools products 2012-08-27 11:46:23 -07:00
config Verify --with-linux source directory exists 2012-11-29 15:05:54 -08:00
include Track emergency object in rbtree 2012-11-06 14:54:19 -08:00
lib Remove autotools products 2012-08-27 11:46:23 -07:00
module splat taskq:front: Fix race 2012-12-05 12:23:40 -08:00
patches Reimplement rwlocks for Linux lock profiling/analysis. 2009-09-18 16:09:47 -07:00
scripts Remove autotools products 2012-08-27 11:46:23 -07:00
.gitignore Remove autotools products 2012-09-11 10:12:47 -07:00
AUTHORS Public Release Prep 2010-05-17 15:18:00 -07:00
autogen.sh Remove autotools products 2012-08-27 11:46:23 -07:00
ChangeLog Prep for spl-0.5.0 tag 2010-08-13 09:33:50 -07:00
configure.ac Support building a spl-modules-dkms sub package 2012-08-08 13:49:40 -07:00
copy-builtin Add script for builtin module building. 2012-07-26 15:13:09 -07:00
COPYING Public Release Prep 2010-05-17 15:18:00 -07:00
DISCLAIMER Public Release Prep 2010-05-17 15:18:00 -07:00
dkms.conf.in Support building a spl-modules-dkms sub package 2012-08-08 13:49:40 -07:00
dkms.postinst Support building a spl-modules-dkms sub package 2012-08-08 13:49:40 -07:00
INSTALL Public Release Prep 2010-05-17 15:18:00 -07:00
Makefile.am Add copy-builtin to EXTRA_DIST 2012-08-23 09:59:40 -07:00
META SPL 0.6.0-rc12 2012-11-13 14:28:25 -08:00
PKGBUILD-spl-modules.in Add make rule for building Arch Linux packages 2011-12-14 16:44:10 -08:00
PKGBUILD-spl.in Add make rule for building Arch Linux packages 2011-12-14 16:44:10 -08:00
README.markdown Add script for builtin module building. 2012-07-26 15:13:09 -07:00
spl-modules.spec.in Cleanly remove spl-modules-devel headers 2012-08-13 16:34:32 -07:00
spl.release.in Move spl.release generation to configure step 2012-07-12 12:13:47 -07:00
spl.spec.in Fix rpm dependencies 2012-01-18 11:24:36 -08:00

The Solaris Porting Layer (SPL) is a Linux kernel module which provides many of the Solaris kernel APIs. This shim layer makes it possible to run Solaris kernel code in the Linux kernel with relatively minimal modification. This can be particularly useful when you want to track upstream Solaris development closely and dont want the overhead of maintaining a large patch which converts Solaris primitives to Linux primitives.

To build packages for your distribution:

$ ./configure
$ make pkg

To copy the kernel code inside your kernel source tree for builtin compilation:

$ ./configure --enable-linux-builtin --with-linux=/usr/src/linux-...
$ ./copy-builtin /usr/src/linux-...

Full documentation for building, configuring, and using the SPL can be found at: http://zfsonlinux.org