uint32_t size,
uint32_t *out_offset,
bool rw);
+ void (*emit_buffer_surface_state)(struct brw_context *brw,
+ uint32_t *out_offset,
+ drm_intel_bo *bo,
+ unsigned buffer_offset,
+ unsigned surface_format,
+ unsigned buffer_size,
+ unsigned pitch,
+ unsigned mocs,
+ bool rw);
/** Upload a SAMPLER_STATE table. */
void (*upload_sampler_state_table)(struct brw_context *brw,
unsigned buffer_offset,
unsigned surface_format,
unsigned buffer_size,
- unsigned pitch)
+ unsigned pitch,
+ unsigned mocs,
+ bool rw)
{
uint32_t *surf = brw_state_batch(brw, AUB_TRACE_SURFACE_STATE,
6 * 4, 32, out_offset);
if (bo) {
drm_intel_bo_emit_reloc(brw->batch.bo, *out_offset + 4,
bo, buffer_offset,
- I915_GEM_DOMAIN_SAMPLER, 0);
+ I915_GEM_DOMAIN_SAMPLER,
+ (rw ? I915_GEM_DOMAIN_SAMPLER : 0));
}
}
tObj->BufferOffset,
brw_format,
size / texel_size,
- texel_size);
+ texel_size,
+ 0,
+ false);
}
static void
gen4_emit_buffer_surface_state(brw, out_offset, bo, offset,
BRW_SURFACEFORMAT_R32G32B32A32_FLOAT,
- elements, stride);
+ elements, stride, 0, false);
}
/**
brw->vtbl.update_null_renderbuffer_surface =
brw_update_null_renderbuffer_surface;
brw->vtbl.create_constant_surface = brw_create_constant_surface;
+ brw->vtbl.emit_buffer_surface_state = gen4_emit_buffer_surface_state;
}
gen7_update_null_renderbuffer_surface;
brw->vtbl.create_constant_surface = gen7_create_constant_surface;
brw->vtbl.create_raw_surface = gen7_create_raw_surface;
+ brw->vtbl.emit_buffer_surface_state = gen7_emit_buffer_surface_state;
}