diff options
author | Lucas Stach <l.stach@pengutronix.de> | 2019-07-05 20:17:20 +0300 |
---|---|---|
committer | Lucas Stach <l.stach@pengutronix.de> | 2019-08-15 11:54:07 +0300 |
commit | db41fe7d2f75c946a0b138aa789ca7cf6cd8afc1 (patch) | |
tree | 4ee096f9ad071bcd3f3fdecd2ed66517374773a1 /drivers/gpu/drm/etnaviv/etnaviv_gpu.h | |
parent | 3001eeb7f216f404d5c459876131d3d48f3c12fc (diff) | |
download | linux-db41fe7d2f75c946a0b138aa789ca7cf6cd8afc1.tar.xz |
drm/etnaviv: simplify unbind checks
Remember if the GPU has been sucessfully initialized. Only in that case
do we need to clean up various structures in the unbind path. If the
GPU hasn't been sucessfully initialized all the cleanups should happen
in the failure paths of the init function.
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
Reviewed-by: Guido Günther <agx@sigxcpu.org>
Diffstat (limited to 'drivers/gpu/drm/etnaviv/etnaviv_gpu.h')
-rw-r--r-- | drivers/gpu/drm/etnaviv/etnaviv_gpu.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.h b/drivers/gpu/drm/etnaviv/etnaviv_gpu.h index 9bcf151f706b..b06c7c98d522 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.h +++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.h @@ -99,6 +99,7 @@ struct etnaviv_gpu { enum etnaviv_sec_mode sec_mode; struct workqueue_struct *wq; struct drm_gpu_scheduler sched; + bool initialized; /* 'ring'-buffer: */ struct etnaviv_cmdbuf buffer; |