diff options
author | Jerome Glisse <jglisse@redhat.com> | 2009-12-11 14:36:19 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-12-22 20:14:04 -0500 |
commit | 0a0c7596c643239e8d4c3eaaba43b74a96f2411e (patch) | |
tree | bb387597d7c8260a8cd2a18235cde90cc72c757d /drivers/gpu/drm/radeon/radeon.h | |
parent | d2efdf6d6f425950a61fa5cc3aa22e6718e7f3c8 (diff) |
drm/radeon/kms: Avoid crash when trying to cleanup uninitialized structure
Add boolean to record if some part of the driver are initialized or
not this allow to avoid a crash when trying to cleanup uninitialized
structure members.
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon.h')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h index cd650fd3964e..53b55608102b 100644 --- a/drivers/gpu/drm/radeon/radeon.h +++ b/drivers/gpu/drm/radeon/radeon.h | |||
@@ -162,6 +162,7 @@ struct radeon_fence_driver { | |||
162 | struct list_head created; | 162 | struct list_head created; |
163 | struct list_head emited; | 163 | struct list_head emited; |
164 | struct list_head signaled; | 164 | struct list_head signaled; |
165 | bool initialized; | ||
165 | }; | 166 | }; |
166 | 167 | ||
167 | struct radeon_fence { | 168 | struct radeon_fence { |
@@ -202,8 +203,9 @@ struct radeon_surface_reg { | |||
202 | struct radeon_mman { | 203 | struct radeon_mman { |
203 | struct ttm_bo_global_ref bo_global_ref; | 204 | struct ttm_bo_global_ref bo_global_ref; |
204 | struct ttm_global_reference mem_global_ref; | 205 | struct ttm_global_reference mem_global_ref; |
205 | bool mem_global_referenced; | ||
206 | struct ttm_bo_device bdev; | 206 | struct ttm_bo_device bdev; |
207 | bool mem_global_referenced; | ||
208 | bool initialized; | ||
207 | }; | 209 | }; |
208 | 210 | ||
209 | struct radeon_bo { | 211 | struct radeon_bo { |