diff options
author | Martin K. Petersen <martin.petersen@oracle.com> | 2022-04-07 03:46:54 +0200 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2022-04-07 03:46:54 +0200 |
commit | 5f3ecd74476510382a35e3ac1883ce52eb5903ae (patch) | |
tree | ca694f62fc98edb940a1cd94561eb3b8d9527c63 /drivers/target | |
parent | Linux 5.18-rc1 (diff) | |
parent | scsi: bnx2i: Fix spelling mistake "mis-match" -> "mismatch" (diff) | |
download | linux-5f3ecd74476510382a35e3ac1883ce52eb5903ae.tar.xz linux-5f3ecd74476510382a35e3ac1883ce52eb5903ae.zip |
Merge branch '5.18/scsi-queue' into 5.18/scsi-fixes
Pull the remaining commits from 5.18/scsi-queue into fixes.
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/target')
-rw-r--r-- | drivers/target/target_core_user.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index 95d4ca50a605..fd7267baa707 100644 --- a/drivers/target/target_core_user.c +++ b/drivers/target/target_core_user.c @@ -1821,6 +1821,7 @@ static struct page *tcmu_try_get_data_page(struct tcmu_dev *udev, uint32_t dpi) mutex_lock(&udev->cmdr_lock); page = xa_load(&udev->data_pages, dpi); if (likely(page)) { + get_page(page); mutex_unlock(&udev->cmdr_lock); return page; } @@ -1877,6 +1878,7 @@ static vm_fault_t tcmu_vma_fault(struct vm_fault *vmf) /* For the vmalloc()ed cmd area pages */ addr = (void *)(unsigned long)info->mem[mi].addr + offset; page = vmalloc_to_page(addr); + get_page(page); } else { uint32_t dpi; @@ -1887,7 +1889,6 @@ static vm_fault_t tcmu_vma_fault(struct vm_fault *vmf) return VM_FAULT_SIGBUS; } - get_page(page); vmf->page = page; return 0; } |