summaryrefslogtreecommitdiffstats
path: root/lib/libzpool
diff options
context:
space:
mode:
authorBrian Behlendorf <[email protected]>2012-02-23 15:32:51 -0800
committerBrian Behlendorf <[email protected]>2012-03-21 14:51:44 -0700
commit49be0ccf1fdc2ce852271d4d2f8b7a9c2c4be6db (patch)
treeaed0f86abdf017fc9edb8593895aef671597cfd7 /lib/libzpool
parentc8df41538db3723edf3536379a78fbaf68f037d0 (diff)
Add zio constructor/destructor
Add a standard zio constructor and destructor. Normally, this is done to reduce to cost of allocating a new structure by reducing expensive operations such as memory allocations. However, in this case none of the operations moved out of zio_create() were really very expensive. This change was principly made as a debug patch (and workaround) for a zio_destroy() race. The is good evidence that zio_create() is reinitializing a mutex which is really still in use by another thread. This would completely explain the observed symptoms in the issue report. This patch doesn't fix the root cause of the race, but it should make it less likely by only initializing the mutex once in the constructor. Also, this particular flaw might have gone unnoticed in other zfs implementations due to the specific implementation details of Linux ticket spinlocks. Once the real root cause is determined and resolved this change can be safely reverted. Until then this should help workaround the issue. Signed-off-by: Brian Behlendorf <[email protected]> Issue #496
Diffstat (limited to 'lib/libzpool')
0 files changed, 0 insertions, 0 deletions