diff --git a/scst/src/scst_lib.c b/scst/src/scst_lib.c index 018baeed3..3f2f629e7 100644 --- a/scst/src/scst_lib.c +++ b/scst/src/scst_lib.c @@ -3707,7 +3707,7 @@ static struct scst_cmd *scst_create_prepare_internal_cmd( scst_sess_get(res->sess); if (res->tgt_dev != NULL) - __scst_get(0); + __scst_get(); res->state = SCST_CMD_STATE_PARSE; diff --git a/scst/src/scst_main.c b/scst/src/scst_main.c index 113d75e80..393aee8ea 100644 --- a/scst/src/scst_main.c +++ b/scst/src/scst_main.c @@ -1969,7 +1969,7 @@ out_unlock: */ void scst_get(void) { - __scst_get(0); + __scst_get(); } EXPORT_SYMBOL(scst_get); diff --git a/scst/src/scst_priv.h b/scst/src/scst_priv.h index 43ac0648b..ff871e2a1 100644 --- a/scst/src/scst_priv.h +++ b/scst/src/scst_priv.h @@ -602,15 +602,13 @@ static inline void scst_check_unblock_dev(struct scst_cmd *cmd) return; } -static inline void __scst_get(int barrier) +static inline void __scst_get(void) { atomic_inc(&scst_cmd_count); TRACE_DBG("Incrementing scst_cmd_count(new value %d)", atomic_read(&scst_cmd_count)); - /* See comment about smp_mb() in scst_suspend_activity() */ - if (barrier) - smp_mb__after_atomic_inc(); + smp_mb__after_atomic_inc(); } static inline void __scst_put(void) diff --git a/scst/src/scst_targ.c b/scst/src/scst_targ.c index c59283799..39034bfe7 100644 --- a/scst/src/scst_targ.c +++ b/scst/src/scst_targ.c @@ -3775,7 +3775,7 @@ static int scst_translate_lun(struct scst_cmd *cmd) TRACE_ENTRY(); /* See comment about smp_mb() in scst_suspend_activity() */ - __scst_get(1); + __scst_get(); if (likely(!test_bit(SCST_FLAG_SUSPENDED, &scst_flags))) { struct list_head *sess_tgt_dev_list_head = @@ -4354,7 +4354,7 @@ static int scst_mgmt_translate_lun(struct scst_mgmt_cmd *mcmd) (long long unsigned int)mcmd->lun); /* See comment about smp_mb() in scst_suspend_activity() */ - __scst_get(1); + __scst_get(); if (unlikely(test_bit(SCST_FLAG_SUSPENDED, &scst_flags) && !test_bit(SCST_FLAG_SUSPENDING, &scst_flags))) {