aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
diff options
context:
space:
mode:
authorJuergen Gross <[email protected]>2017-05-18 15:28:47 +0000
committerKonrad Rzeszutek Wilk <[email protected]>2017-06-13 20:04:18 +0000
commit46464411307746e6297a034a9983a22c9dfc5a0c (patch)
tree10a7411cf52e3cbe830d4a48f44cf1eb93085c31 /drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
parentblock: xen-blkback: add null check to avoid null pointer dereference (diff)
downloadkernel-46464411307746e6297a034a9983a22c9dfc5a0c.tar.gz
kernel-46464411307746e6297a034a9983a22c9dfc5a0c.zip
xen/blkback: fix disconnect while I/Os in flight
Today disconnecting xen-blkback is broken in case there are still I/Os in flight: xen_blkif_disconnect() will bail out early without releasing all resources in the hope it will be called again when the last request has terminated. This, however, won't happen as xen_blkif_free() won't be called on termination of the last running request: xen_blkif_put() won't decrement the blkif refcnt to 0 as xen_blkif_disconnect() didn't finish before thus some xen_blkif_put() calls in xen_blkif_disconnect() didn't happen. To solve this deadlock xen_blkif_disconnect() and xen_blkif_alloc_rings() shouldn't use xen_blkif_put() and xen_blkif_get() but use some other way to do their accounting of resources. This at once fixes another error in xen_blkif_disconnect(): when it returned early with -EBUSY for another ring than 0 it would call xen_blkif_put() again for already handled rings on a subsequent call. This will lead to inconsistencies in the refcnt handling. Cc: [email protected] Signed-off-by: Juergen Gross <[email protected]> Tested-by: Steven Haigh <[email protected]> Acked-by: Roger Pau MonnĂ© <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c')
0 files changed, 0 insertions, 0 deletions