diff options
Diffstat (limited to 'module/splat/splat-internal.h')
-rw-r--r-- | module/splat/splat-internal.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/module/splat/splat-internal.h b/module/splat/splat-internal.h index b138196f5..2ff19541b 100644 --- a/module/splat/splat-internal.h +++ b/module/splat/splat-internal.h @@ -28,6 +28,7 @@ #include "spl-device.h" #include "spl-debug.h" #include "splat-ctl.h" +#include <sys/mutex.h> #define SPLAT_SUBSYSTEM_INIT(type) \ ({ splat_subsystem_t *_sub_; \ @@ -121,7 +122,7 @@ typedef struct splat_subsystem { #define SPLAT_INFO_BUFFER_REDZONE 256 typedef struct splat_info { - struct mutex info_lock; + kmutex_t info_lock; int info_size; char *info_buffer; char *info_head; /* Internal kernel use only */ @@ -136,7 +137,7 @@ typedef struct splat_info { ASSERT(_info_); \ ASSERT(_info_->info_buffer); \ \ - mutex_lock(&_info_->info_lock); \ + mutex_enter(&_info_->info_lock); \ \ /* Don't allow the kernel to start a write in the red zone */ \ if ((int)(_info_->info_head - _info_->info_buffer) > \ @@ -148,7 +149,7 @@ typedef struct splat_info { _info_->info_head += _rc_; \ } \ \ - mutex_unlock(&_info_->info_lock); \ + mutex_exit(&_info_->info_lock); \ _rc_; \ }) |