summaryrefslogtreecommitdiffstats
path: root/drivers/target
diff options
context:
space:
mode:
authorBodo Stroesser <bostroesser@gmail.com>2021-03-10 19:44:58 +0100
committerMartin K. Petersen <martin.petersen@oracle.com>2021-03-16 04:18:37 +0100
commit471ee95ccca9c417344453f73a39681cfde39af1 (patch)
treee206ecf3416444e966138bfbb664172199365d6c /drivers/target
parentscsi: qla2xxx: Use dma_pool_zalloc() (diff)
downloadlinux-471ee95ccca9c417344453f73a39681cfde39af1.tar.xz
linux-471ee95ccca9c417344453f73a39681cfde39af1.zip
scsi: target: tcmu: Adjust parameter in call to tcmu_blocks_release()
In commit f7c89771d07d ("scsi: target: tcmu: Replace radix_tree with XArray") the meaning of last parameter of tcmu_blocks_release() was changed. So in the callers we should subtract 1 from the previous parameter. Unfortunately that change got lost at one of the two places where tcmu_blocks_release() is called. That does not lead to any problems, but we should adjust it anyway. Link: https://lore.kernel.org/r/20210310184458.10741-1-bostroesser@gmail.com Signed-off-by: Bodo Stroesser <bostroesser@gmail.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/target')
-rw-r--r--drivers/target/target_core_user.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c
index 9e1b115cb032..bdfc057f000c 100644
--- a/drivers/target/target_core_user.c
+++ b/drivers/target/target_core_user.c
@@ -1658,7 +1658,7 @@ static void tcmu_dev_kref_release(struct kref *kref)
xa_destroy(&udev->commands);
WARN_ON(!all_expired);
- tcmu_blocks_release(&udev->data_blocks, 0, udev->dbi_max + 1);
+ tcmu_blocks_release(&udev->data_blocks, 0, udev->dbi_max);
bitmap_free(udev->data_bitmap);
mutex_unlock(&udev->cmdr_lock);