diff options
Diffstat (limited to 'lib/libdrm/intel/intel_decode.c')
-rw-r--r-- | lib/libdrm/intel/intel_decode.c | 22 |
1 files changed, 9 insertions, 13 deletions
diff --git a/lib/libdrm/intel/intel_decode.c b/lib/libdrm/intel/intel_decode.c index b24861b16..e0a516644 100644 --- a/lib/libdrm/intel/intel_decode.c +++ b/lib/libdrm/intel/intel_decode.c @@ -3811,7 +3811,7 @@ decode_3d_i830(struct drm_intel_decode *ctx) return 1; } -struct drm_intel_decode * +drm_public struct drm_intel_decode * drm_intel_decode_context_alloc(uint32_t devid) { struct drm_intel_decode *ctx; @@ -3823,12 +3823,8 @@ drm_intel_decode_context_alloc(uint32_t devid) ctx->devid = devid; ctx->out = stdout; - if (IS_GEN11(devid)) - ctx->gen = 11; - else if (IS_GEN10(devid)) - ctx->gen = 10; - else if (IS_GEN9(devid)) - ctx->gen = 9; + if (intel_get_genx(devid, &ctx->gen)) + ; else if (IS_GEN8(devid)) ctx->gen = 8; else if (IS_GEN7(devid)) @@ -3849,20 +3845,20 @@ drm_intel_decode_context_alloc(uint32_t devid) return ctx; } -void +drm_public void drm_intel_decode_context_free(struct drm_intel_decode *ctx) { free(ctx); } -void +drm_public void drm_intel_decode_set_dump_past_end(struct drm_intel_decode *ctx, int dump_past_end) { ctx->dump_past_end = !!dump_past_end; } -void +drm_public void drm_intel_decode_set_batch_pointer(struct drm_intel_decode *ctx, void *data, uint32_t hw_offset, int count) { @@ -3871,7 +3867,7 @@ drm_intel_decode_set_batch_pointer(struct drm_intel_decode *ctx, ctx->base_count = count; } -void +drm_public void drm_intel_decode_set_head_tail(struct drm_intel_decode *ctx, uint32_t head, uint32_t tail) { @@ -3879,7 +3875,7 @@ drm_intel_decode_set_head_tail(struct drm_intel_decode *ctx, ctx->tail = tail; } -void +drm_public void drm_intel_decode_set_output_file(struct drm_intel_decode *ctx, FILE *output) { @@ -3893,7 +3889,7 @@ drm_intel_decode_set_output_file(struct drm_intel_decode *ctx, * \param count number of DWORDs to decode in the batch buffer * \param hw_offset hardware address for the buffer */ -void +drm_public void drm_intel_decode(struct drm_intel_decode *ctx) { int ret; |