diff options
author | Ilia Mirkin <[email protected]> | 2016-01-04 19:48:08 -0500 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2016-01-05 01:29:49 -0500 |
commit | a1d664a0b7dbd8bbab0ff7a179e8960c25a52c0b (patch) | |
tree | 2130ae72303c3e87ed640175a2e8865298bf070a /src/mesa/drivers/dri | |
parent | 2123bfcc9c8b375ba46bb59d493ddeac1b7291a6 (diff) |
Revert "i965/wm: use proper API buffer size for the surfaces."
This reverts commit 8cf2e892fca20c4776b4a07c39918343cb2d4e0e. It's
entirely bogus to attempt to store anything about the binding in the
buffer object itself, which might be bound any number of times.
Signed-off-by: Ilia Mirkin <[email protected]>
Cc: Samuel Iglesias Gonsálvez <[email protected]>
Cc: Marta Lofstedt <[email protected]>
Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 12 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_buffer_objects.c | 1 |
2 files changed, 4 insertions, 9 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c index 7da4a404668..76dc5775121 100644 --- a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c +++ b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c @@ -946,14 +946,12 @@ brw_upload_ubo_surfaces(struct brw_context *brw, } else { struct intel_buffer_object *intel_bo = intel_buffer_object(binding->BufferObject); - GLsizeiptrARB size = MIN2(binding->BufferObject->BufferRangeSize, - binding->BufferObject->Size - binding->Offset); drm_intel_bo *bo = intel_bufferobj_buffer(brw, intel_bo, binding->Offset, - size); + binding->BufferObject->Size - binding->Offset); brw_create_constant_surface(brw, bo, binding->Offset, - size, + binding->BufferObject->Size - binding->Offset, &ubo_surf_offsets[i]); } } @@ -970,14 +968,12 @@ brw_upload_ubo_surfaces(struct brw_context *brw, } else { struct intel_buffer_object *intel_bo = intel_buffer_object(binding->BufferObject); - GLsizeiptrARB size = MIN2(binding->BufferObject->BufferRangeSize, - binding->BufferObject->Size - binding->Offset); drm_intel_bo *bo = intel_bufferobj_buffer(brw, intel_bo, binding->Offset, - size); + binding->BufferObject->Size - binding->Offset); brw_create_buffer_surface(brw, bo, binding->Offset, - size, + binding->BufferObject->Size - binding->Offset, &ssbo_surf_offsets[i]); } } diff --git a/src/mesa/drivers/dri/i965/intel_buffer_objects.c b/src/mesa/drivers/dri/i965/intel_buffer_objects.c index b26c939c214..7a5b3fca595 100644 --- a/src/mesa/drivers/dri/i965/intel_buffer_objects.c +++ b/src/mesa/drivers/dri/i965/intel_buffer_objects.c @@ -198,7 +198,6 @@ brw_buffer_data(struct gl_context *ctx, (void) target; intel_obj->Base.Size = size; - intel_obj->Base.BufferRangeSize = size; intel_obj->Base.Usage = usage; intel_obj->Base.StorageFlags = storageFlags; |