[igt-dev] [PATCH i-g-t v31 12/32] lib/igt_draw: remove libdrm dependency
Chris Wilson
chris at chris-wilson.co.uk
Wed Aug 26 16:04:53 UTC 2020
Quoting Zbigniew Kempczyński (2020-08-20 07:30:10)
> Change rendercopy to use intel_bb to remove libdrm dependency.
>
> Signed-off-by: Dominik Grzegorzek <dominik.grzegorzek at intel.com>
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
> ---
> lib/igt_draw.c | 155 ++++++++++++++++++++++++-------------------------
> lib/igt_draw.h | 8 +--
> 2 files changed, 79 insertions(+), 84 deletions(-)
>
> diff --git a/lib/igt_draw.c b/lib/igt_draw.c
> index f2340127..462738ef 100644
> --- a/lib/igt_draw.c
> +++ b/lib/igt_draw.c
> @@ -27,6 +27,7 @@
> #include "igt_draw.h"
>
> #include "drmtest.h"
> +#include "intel_bufops.h"
> #include "intel_batchbuffer.h"
> #include "intel_chipset.h"
> #include "igt_core.h"
> @@ -61,8 +62,8 @@
> /* Some internal data structures to avoid having to pass tons of parameters
> * around everything. */
> struct cmd_data {
> - drm_intel_bufmgr *bufmgr;
> - drm_intel_context *context;
> + struct buf_ops *bops;
> + uint32_t ctx;
> };
>
> struct buf_data {
> @@ -264,8 +265,7 @@ static void set_pixel(void *_ptr, int index, uint32_t color, int bpp)
> }
> }
>
> -static void switch_blt_tiling(struct intel_batchbuffer *batch, uint32_t tiling,
> - bool on)
> +static void switch_blt_tiling(struct intel_bb *ibb, uint32_t tiling, bool on)
> {
> uint32_t bcs_swctrl;
>
> @@ -273,26 +273,22 @@ static void switch_blt_tiling(struct intel_batchbuffer *batch, uint32_t tiling,
> if (tiling != I915_TILING_Y)
> return;
>
> - igt_require(batch->gen >= 6);
> + igt_require(ibb->gen >= 6);
That remains me, did you see the patch to make ibb use an unsigned gen
to avoid treating future platforms as ancient?
-Chris
More information about the igt-dev
mailing list