Skip to content

Commit e9f7f17

Browse files
committed
Merge tag 'vfio-v4.10-rc7' of git://github.com/awilliam/linux-vfio
Pull VFIO fix from Alex Williamson: "Fix an error path in SPAPR IOMMU backend (Alexey Kardashevskiy)" * tag 'vfio-v4.10-rc7' of git://github.com/awilliam/linux-vfio: vfio/spapr: Fix missing mutex unlock when creating a window
2 parents 7a92cc6 + 2da64d2 commit e9f7f17

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

drivers/vfio/vfio_iommu_spapr_tce.c

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1123,12 +1123,11 @@ static long tce_iommu_ioctl(void *iommu_data,
11231123
mutex_lock(&container->lock);
11241124

11251125
ret = tce_iommu_create_default_window(container);
1126-
if (ret)
1127-
return ret;
1128-
1129-
ret = tce_iommu_create_window(container, create.page_shift,
1130-
create.window_size, create.levels,
1131-
&create.start_addr);
1126+
if (!ret)
1127+
ret = tce_iommu_create_window(container,
1128+
create.page_shift,
1129+
create.window_size, create.levels,
1130+
&create.start_addr);
11321131

11331132
mutex_unlock(&container->lock);
11341133

0 commit comments

Comments
 (0)