1 2010-8-13 Brian Behlendorf <behlendorf1@llnl.gov>
5 * : The ChangeLog is being retired. Please use the git commit
6 logs for a full records of changes: 'git log'
8 2010-05-21 Brian Behlendorf <behlendorf1@llnl.gov>
12 * : Build system improvements:
13 - Added support for the 'make -s' silent build option.
14 - Allow spl_config.h to be included by dependent packages.
15 - Minor spec file updates.
17 * AUTHORS, COPYING, DISCLAIMER, and INSTALL: Updated.
19 * *.c, *.h, *.sh, AUTHORS, COPYING, DISCLAIMER, and INSTALL:
20 Added standard header to source files which includes the copyright,
21 license, and author information. Additionally, updated the listed
22 top level files to the latest versions.
24 * module/spl/spl-debug.c: Debugging defaults adjusted. The default
25 log dump path is now /tmp/spl-log and panic on SBUG has been disabled.
27 * include/sys/processor.h, include/sys/systm.h, include/sys/types.h:
28 Added 3 missing typedefs processorid_t, pc_t, and index_t.
30 * include/sys/console.h: Added support for console_* functions().
32 * module/spl/spl-time.c: Updated gethrtime() to use the function
33 do_posix_clock_monotonic_gettime() as described in the comment.
35 * module/spl/spl-condvar.c: Added cv_wait_interruptible() function
36 as an extension to the existing condition variable ABI to enable
37 sleeping threads a way to cleanly handle signals in the kernel.
39 * module/spl/spl-debug.c: Dump log from current process as required.
41 * module/spl/spl-taskq.c: Assume TQ_SLEEP in taskq_dispatch() if
42 the caller does not specify, this is the Solaris default.
44 * module/spl/spl-vnode.c: Extend the vn_rdwr() implementation to
45 correctly handle the FAPPEND option.
47 * module/spl/spl-generic.c, module/spl/spl-vnode.c: Update
48 vn_set_pwd() to allow a kernal address as filename. This turns
49 out to be critical because spl_setup()->The vn_set_pwd("/") which
50 is called at module load time was failing with -EFAULT.
52 * include/sys/rwlock.h: Disable rw_tryupgrade() for kernels built
53 without CONFIG_RWSEM_GENERIC_SPINLOCK defined. The existing
54 implementation is not safe in this case and needs to be replaced
55 with a correct native per-arch implementation.
57 * module/spl/spl-kmem.c: Reduce maximum kmem based slab size.
58 Allowing MAX_ORDER-1 sized memory allocations while the system
59 is low on memory has been observed to result in deadlocks. Callers
60 should not be using the slab in this way but we should still handle
61 the case more cleanly.
63 * module/spl/spl-kmem.c: Remove kmem_set_warning() interface and
64 replace it with KM_NODEBUG flag which can be specific per allocation.
66 * module/splat/splat-kmem.c: Tweaked what the idea of a large object
67 is for the kmem:slab_large regression tests because failures were
68 observed for very large kmem objects in newer kernels.
70 * include/sys/rwlock.h, module/splat/splat-rwlock.c: The rwlock
71 implementation was simplified because failures were being observed
72 when using the non-generic implementation. This change leverages
73 the rwsem_is_locked() function instead of directly consulting the
74 rwsem internals which differ per-arch and per-kernel-version.
76 2010-03-11 Brian Behlendorf <behlendorf1@llnl.gov>
80 * : Build system improvements:
81 - Remove Module.markers and Module.symver{s} in clean target.
82 - Improved kernel source detection when none specified.
83 - Fix RPM definitions for the unknown distro/installation.
85 * config/spl-build.m4: Linux 2.6.32 compat, SPL_AC_5ARGS_PROC_HANDLER
86 macro added to handle updated proc_handler () API.
88 * module/spl/spl-err.c: Fix panic() string, which was being used as a
89 format string, instead of an already-formatted string.
91 * /module/spl/spl-taskq.c: Optimize lowest outstanding taskqid
92 calculation in taskq_lowest_id(). The motivation for this change
93 was that I was observing as much as 10% of the total CPU time go
94 to waiting on the tq->tq_lock when the pending list was long.
96 * module/spl/spl-kmem.c: Strip __GFP_ZERO from kmalloc it is not
97 available for older kernels.
99 * module/spl/spl-proc.c: Add skc_flags and full header to
102 * module/spl/spl-generic.c: Correctly handle division on 32-bit RHEL5
103 systems by returning dividend.
105 * include/sys/rwlock.h: When using x86 specific rwsem correctly
106 intepret rwsem->count. Additionally check for changed guard macro
107 in 2.6.28+ for rwsem implementation
109 * module/splat/splat-vnode.c, module/splat/splat-kmem.c,
110 module/splat/splat-taskq.c: Several new tests were added to the
111 test suite and various bug fixes.
113 * include/asm/atomic_compat.h: Atomic64 compatibility for 32-bit
114 systems without kernel support.
116 * .gitignore: Added .gitignore files.
118 2009-11-20 Brian Behlendorf <behlendorf1@llnl.gov>
122 * config/spl-build.m4: Linux 2.6.31 compat, SPL_AC_2ARGS_SET_FS_PWD
123 macro updated to explicitly include linux/fs_struct.h which was
124 dropped from linux/sched.h.
126 * include/linux/mm_compat.h: Linux 2.6.31 compat, use the macros
127 min_wmark_pages, low_wmark_pages, and high_wmark_pages which were
128 introduced. For older kernels a compability macro is used.
130 * include/sys/kmem.h: Linux 2.6.31 compat, the __GFP_NOFAIL flag
131 should no longer be used and it may disappear from the kernel at any
132 time. To handle this I have simply added *_nofail wrappers in the
133 kmem implementation which perform the retry for non-atomic allocations.
135 * module/spl/spl-kmem.c: Linux 2.6.31 compat, kmem cache alignment
136 fixes and cleanup. Always perform allocations for the kmem cache
137 using __get_free_pages() or __vmalloc() to ensure the returned
138 memory is page aligned. Also introduce helper functions which use
139 P2ROUNDUP_TYPE instead of P2ROUNDUP force all types to be explicit.
141 * include/sys/mutex.h: Add mutex_enter_nested() as wrapper for
142 mutex_lock_nested() to permit integration with the lock checker.
144 * include/sys/mutex.h: Always use the generic mutex_destroy().
146 * Makefile.am: Ensure *.order and *.markers build products are
147 removed by distclean rule.
149 2009-11-02 Brian Behlendorf <behlendorf1@llnl.gov>
153 * config/spl-build.m4: Cleanup --enable-debug-* configure options.
154 --enable-debug=<default no> generic debug support.
155 --enable-debug-kmem=<default yes> basic kmem and slab accounting.
156 --enable-debug-kmem-tracking=<default no> detailed kmem tracking.
157 --enable-debug-kstat removed option support always enabled.
158 --enable-debug-callb removed option which never did anything.
160 * module/spl/spl-atomic.c: Reimplemented atomic functions by
161 layering them on top of the Linux atomic functions. This improves
162 performance by removing the need for a global spinlock.
164 * module/spl/spl-debug.c: Rebase cmn_err on vcmn_err. Handle the
165 case where the message contains a leading ! which means only send
166 it to syslog. And suppress warnings for messages which do not end
169 * module/splat/splat-ctl.c: Update to use kobject_set_name() for
170 increased portability.
172 * module/spl/spl-generic.c: Set cwd to '/' for the task during
173 module load for SPL dependent modules. Under Solaris this is
174 the expected behavior, on a Linux system your cwd remains set
175 to whatever the tasks cwd was when loading a module.
177 * module/spl/spl-mutex.c: Reimplemented mutexs for improved
178 performance and cleaner integration with the Linux kernels built
179 in lock analyzer. As of 2.6.29 based kernels adaptive mutexs
180 are supported, for these newer kernels task_curr() does not need
181 to be exported. Finally, DEBUG_MUTEX support was dropped in
182 favor of more detailed kernel profiling which is now available.
184 * module/spl/spl-rwlock.c: Reimplemented rwlocks for improved
185 performance and cleaner integration with the Linux kernels built
186 in lock analyzer. Additionally, the rwlock regression tests were
187 improved to help validate correctness.
189 * spl-modules.spec.in: Various spec file tweaks for the supported
190 distros: RHEL5, RHEL6, SLES10, SLES11, Chaos4, Fedora 11.
192 2009-08-04 Brian Behlendorf <behlendorf1@llnl.gov>
196 * FC11 and SLES11 support: This includes all compatibility changes
197 to support 2.6.29 based kernels and the required build system
199 * module/spl/spl-module.c: Register a basic compat ioctl handler
200 for 32-bit user vs 64-bit kernel compatibility. This is the default
201 build environment for all 64-bit SLES systems.
202 * config/spl-build.m4: Check arch/default path when detecting kernel
203 objects under SLES. We still preferentially use arch/arch if
204 available but if that fails it is acceptable to use default.
205 * module/spl/spl-vnode.: Use HAVE_PATH_IN_NAMEIDATA compat macros
206 for maximum kernel compatibility.
207 * config/spl-build.m4: Remove LINUXINCLUDE from autoconf wrapper.
208 This breaks the 2.6.28+ kernels build system, all kernel build systems
209 at least post 2.6.16 will set this properly so we should not.
210 * include/sys/vmsystm.h, module/spl/spl-kmem.c: Perferentially use the
211 global_page_state() API when your kernel supports the required enums.
212 * include/sys/debug.h: Add ASSERTV macro to simplify removing
213 variables (the V in ASSERTV) which are only used in ASSERT().
214 * include/sys/debug.h: Disable stack overflow checking by default
215 when build with --enable-debug, modern kernels now provide this.
216 * patches/fc11-spl-export-symbols.patch: Recommended missing symbols
217 patch for FC11. This is not required for correct functionality but
218 it is recommended for individuals who are already patching the kernel.
220 * Additional Solaris API emulation:
221 * include/sys/taskq.h: Add basic taskq support for the flag
222 TASKQ_THREADS_CPU_PCT which is used to scale the number of threads
223 based on the number of online CPUs.
224 * include/sys/file.hi, module/spl/spl-generic.c: Add support for
225 fake ioctls which originate from the kernel instead of user space.
226 * include/sys/acl.h: Add ACE_ALL_PERMS ACL definition.
227 * include/sys/cred.h, module/splat/splat-cred.c: Add basic credential
228 support and splat regression tests.
231 * include/sys/isa_defs.h: Add more endianess paranoia.
232 * module/spl/spl-time.c: Integer overflow after ~164 days.
233 * include/sys/debug.h: NULL dereference by tcd_for_each().
234 * module/splat/splat-kmem.c: Allow kmem or vmem based slabs for
235 slab_lock and slab_overcommit tests. This may still be an issue on
236 32-bit systems due to the small virtual address space.
237 * module/spl/spl-module.c: Positive Solaris ioctl return codes are
238 need to be negated for use by libc to ensure errno is set correctly.
240 2009-07-02 Brian Behlendorf <behlendorf1@llnl.gov>
244 * : Generic distro friendly build system / packaging improvements
245 for rpm based distros including CHAOS, RHEL, Fedora, and SLES.
247 spl-<version>.src.rpm
248 - Fully rebuildable source rpm for utils.
249 spl-modules-<version>.src.rpm
250 - Fully rebuildable source rpm for kernel modules.
252 spl-<version>.<arch>.rpm
253 - Binary rpm for utils. The utils in this package are compatible
254 with all spl-module rpms of the same version.
256 spl-modules-<verion>-<kernel>.arch.rpm
257 - Binary rpm containing the kernel modules for a specific kernel build.
258 The package name contains the kernel version and you should have one
259 of these packages installed to match every kernel on your system.
260 spl-modules-devel-<verion>-<kernel>.arch.rpm
261 - Binary rpm containing development header and module symbols needed
262 for building additional kernel modules which are dependent on the
265 * : Added SLES10 support. This includes all compatibility
266 changes to support 2.6.16 based kernels and the required
267 build system improvements.
269 * : Build System changes for SLES10:
270 - Exclude -obj when detecting installed kernel source.
271 - Detect -obj directory for out of tree kernel builds.
272 - Allow kernel build system to set CC to ensure -m64 is set properly.
273 This is an issue on 64-bit SLES systems which by default always
274 build 32-bit binaries (unlike RHEL/Fedora which default to 64-bit)
276 * : Configure Checks added for SLES10:
277 - div64_64() renamed to div64_u64() as of 2.6.26.
278 - global_page_state() fuction was introduced in 2.6.18 kernels.
279 The earlier 2.6.16 based SLES10 must not try and use it,
280 thankfully get_zone_counts() is still available.
281 - monotonic_clock() is unavailable __gethrtime() must perform the
282 HZ division as an 'unsigned long long' because the SPL only
283 implements __udivdi3(), and not __divdi3() for 'long long'
284 division on 32-bit arches.
285 - mutex_lock_nested() was introduced as part of the mutex
286 validator in 2.6.18, when it is unavailable it is safe to
287 fallback to using a plain mutex_lock().
288 - SLES specific API change to vfs_unlink() and vfs_rename() which
289 added a 'struct vfsmount *' argument. This was for something
290 called the linux-security-module, but it appears that it was
291 never adopted upstream.
292 - spl_device_create() correctly mapped to class_device_create()
293 for 2.6.13 to 2.6.17 based kernels, this is the preferred API.
294 - Prior to 2.6.17 there were no *_pgdat helper functions in
295 mm/mmzone.c. Instead for_each_zone() operated directly on
296 pgdat_list which may or may not have been exported depending on
297 how your kernel was compiled. A configure check was added to
298 determine if you have the helpers or not, and if the needed
299 symbols are exported. If they are not exported then they are
300 dynamically aquired at runtime by kallsyms_lookup_name().
302 * : Packaging changes for SLES10
303 - Properly honor --prefix in build system and rpm spec file.
304 - Add '--define require_kdir' to spec file to support building
305 rpms against kernel sources installed in non-default locations.
306 - Add '--define require_kobj' to spec file to support building
307 rpms against kernel object installed in non-default locations.
308 - Stop suppressing errors in autogen.sh script.
309 - Improved logic to detect missing kernel objects when they are
310 not located with the source. This is the common case for SLES
311 as well as in-tree chaos kernel builds and is done to simply
312 support for multiple arches.
313 - Moved spl-devel build products to /usr/src/spl-<version>, a
314 spl symlink is created to reference the last installed version.
315 - Allow checking for exported symbols in both Module.symvers
316 and Module.symvers. My stock SLES kernel ships an objects
317 directory with Module.symvers, yet produces a Module.symvers
318 in the local build directory.
320 * : Added powerpc64 support.
321 - Enable builds for powerpc64 ISA type.
322 - Add DIV_ROUND_UP and roundup macros if unavailable.
323 - Cast 64-bit values for %lld format string to (long long) to
324 quiet compile warning.
326 * module/splat/splat-ctl.c: Proper ioctl() 32/64-bit binary
327 compatibility. We need to ensure the ioctl data itself is always
328 packed the same for 32/64-bit binaries. Additionally, the correct
329 thing to do is encode this size in bytes as part of the command
332 * modules/spl/spl-kmem.c: Fixed a long standing bug in the debug
333 tracing. The tcd_for_each() macro expected a NULL to terminate
334 the trace_data[i] array but this was only ever true due to luck.
335 All trace_data[] iterators are now properly capped by TCD_TYPE_MAX.
337 * modules/spl/spl-kmem.c: To simplify debugging all symbols aquired
338 dynamically using spl_kallsyms_lookup_name() are initially poisoned
341 2009-03-20 Brian Behlendorf <behlendorf1@llnl.gov>
345 * configure.ac, *Makefile.am: Build system update. This includes
346 resolving various build issues and adding support for the remaining
347 common build targets. Available targets now include:
349 - make all # Build everything
350 - make install # Install everything
351 - make clean # Clean up build products
352 - make distclean # Clean up everything
353 - make dist # Create package tarball
354 - make srpm # Create package source RPM
355 - make rpm # Create package binary RPMs
356 - make tags # Create ctags and etags for everything
358 Extra care was taken to ensure that the source RPMs are fully
359 rebuildable against Fedora/RHEL/Chaos kernels. To build binary
360 RPMs from the source RPM for your system simply run:
362 rpmbuild --rebuild spl-x.y.z-1.src.rpm
364 This will produce two binary RPMs with correct 'requires'
365 dependencies for your kernel. One will contain all zpl modules
366 and support utilities, the other is a devel package for compiling
367 additional kernel modules which are dependent on the spl.
369 spl-x.y.z-1_<kernel version>.x86_64.rpm
370 spl-devel-x.y.2-1_<kernel version>.x86_64.rpm
372 * : FC10 (linux-2.6.27.19) and i686 compatibility update. The
373 list of support platforms has been extended to include FC10
374 systems and x86 architectures. It should be noted that kernels
375 older the 2.6.27.19 should work but have not have not been tested.
377 * configure.ac: Fix build issue preventing spl_config.h from being
378 cleanly included by dependent packages.
380 * module/spl/spl-taskq.c: Fix taskq_wait() not waiting bug.
382 * module/spl/spl-xdr.c: Add XDR implementation provided by Ricardo
385 * module/spl/spl-kmem.c: Linux VM integration cleanup.
387 * module/spl/spl-kmem.c: Slab cache improvements and fixes.
389 * modules/splat/*: Include additional SPLAT regression tests.
391 * : Various bug fixes are more clearly detailed in the git
392 commit logs. For a detailed summary of changes post version
393 0.4.2 check the git commit logs.
397 2009-02-05 Brian Behlendorf <behlendorf1@llnl.gov>
401 * module/spl/spl-kmem.c include/sys/kmem.h: Slab cache improvements:
402 - Implement kmem cache alignment.
403 - Implement slab ageing.
404 - Optimized slab packing algorithm.
405 - Fixed deadlock due to calling call kv_free() under the skc_lock.
406 - Added additional SPLAT test cases
407 - Performance optimizations
409 * module/spl/spl-kmem.c include/sys/kmem.h: Linux VM integration.
410 The Solaris global VM symbols minfree, desfree, lotsfree, needfree,
411 swapfs_minfree, swapfs_reserve, availrmem, freemem, and physmem are
412 now available and loosely integrating with the Linux VM. Some
413 tuning will undoubtably be needed and these tunables are available
414 in /proc/sys/kernel/spl/vm/* for this very reason.
416 * config/spl-build.m4: New configure checks needed when building
417 against 2.6.27+ kernels. More work is needed here.
419 * : Minor cleanup see the 'git log' for full details.
421 2009-01-21 Brian Behlendorf <behlendorf1@llnl.gov>
425 * : Implement ksid_*, ddi_strto*, and system taskq functionality.
426 In addition, several other small Solaris compatibility changes
427 were made, see the 'git log' for full details.
429 2008-11-26 Brian Behlendorf <behlendorf1@llnl.gov>
431 * : Tag spl-0.4.0 (Development now done with Git)
433 * : Imported SPL SVN repo in to Git Repo for core development.
435 2008-11-26 Brian Behlendorf <behlendorf1@llnl.gov>
439 * : Include META file support.
441 2008-11-05 Jim Garlick <garlick@llnl.gov>
443 * : Add autogen.sh products.
445 * configure.ac : Use AC_CONFIG_AUX_DIR to put autograph products
448 * autogen.sh : Use --copy to avoid symlinks, remove error
449 redirection, run aclocal before libtoolize.
451 2008-11-13 Brian Behlendorf <behlendorf1@llnl.gov>
453 * include/sys/sunddi.h, modules/spl/spl-module.c : Removed default
454 udev support from sunddi implementation because it uses GPL-only
455 symbols. This support is optionally available for SPL consumers
456 if they define HAVE_GPL_ONLY_SYMBOLS and license their module as
457 GPL using the MODULE_LICENSE("GPL") macro.
459 2008-11-05 Brian Behlendorf <behlendorf1@llnl.gov>
465 * : Patches from Ricardo M. Correia <Ricardo.M.Correia@sun.com>
466 applied with minor revisions:
468 spl-00-rm-gpl-symbol-notifier_chain.patch
469 spl-01-rm-gpl-symbol-set_cpus_allowed.patch
470 spl-02-rm-gpl-symbols-device.patch
471 spl-03-rm-gpl-symbol-ktime_get_ts.patch
472 spl-04-fix-taskq-spinlock-lockup.patch
474 spl-06-atomic64.patch
475 spl-07-kmem-cleanup.patch
476 spl-08-km-sleep-nofail.patch
477 spl-09-fix-kmem-track-oops.patch
478 spl-10-fix-assert-verify-ndebug.patch
480 2008-06-30 Brian Behlendorf <behlendorf1@llnl.gov>
484 * : modules/sys/kmem-slab.c : Refined SPL slab to include
485 per-cpu caches, removed internal hash, other general
486 performance improvements. Much work remain but it's pretty
487 good for an initial implementation.
489 2008-06-13 Brian Behlendorf <behlendorf1@llnl.gov>
491 * : modules/sys/kmem-slab.c : Re-implemented the slab to no
492 longer be based on the linux slab but to be it's own complete
493 implementation. The new slab behaves much more like the
494 Solaris slab than the Linux slab.
496 2008-06-04 Brian Behlendorf <behlendorf1@llnl.gov>
500 * : Extensive improvements to the build system to detect kernel
501 API changes so we can flexibly build with a wider range of kernel
502 versions. The code has now been testing with the 2.6.18-32chaos
503 and 2.6.25.3-18.fc9 kernels, however we should also be compatible
504 with other kernels in the range of 2.6.18-2.6.25.
506 2008-05-25 Brian Behlendorf <behlendorf1@llnl.gov>
508 * configure.ac, autoconf/* : Initial pass at resolving
509 API changes introduced by kernels newer than 2.6.18.
511 2008-05-21 Brian Behlendorf <behlendorf1@llnl.gov>
515 * : License headers including URCL added for release.
517 2008-05-21 Brian Behlendorf <behlendorf1@llnl.gov>
521 * configure.ac: Improved autotools support.
523 2008-04-26 Brian Behlendorf <behlendorf1@llnl.gov>
525 * include/sys/mutex.h : Implemented a close approximation
526 of adaptive mutexes. These changes however required me to
527 export a new symbol from the kernel proper 'task_curr()'
528 which means we are now dependant on a patched kernel.
530 2008-04-24 Brian Behlendorf <behlendorf1@llnl.gov>
534 * modules/spl/spl-proc.c : Add /proc/sys/spl/version.
536 2008-04-24 Herb Wartens <wartens2@llnl.gov>
538 * include/sys/kmem.h : Make sure that when calling __vmem_alloc
539 that we do not have __GFP_ZERO set. Once the memory is allocated
540 then zero out the memory if __GFP_ZERO is passed to
543 2008-04-16 Herb Wartens <wartens2@llnl.gov>
545 * modules/spl/spl-kmem.c : Make sure to disable interrupts
546 when necessary to avoid deadlocks. We were seeing the deadlock
547 when calling kmem_cache_generic_constructor() and then an interrupt
548 forced us to end up calling kmem_cache_generic_destructor()
549 which caused our deadlock.
551 2008-02-26 Brian Behlendorf <behlendorf1@llnl.gov>
553 : Initial commit of the solaris porting layer (spl). Included
554 in addition to the source is an initial autoconf / configure