mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 02:58:05 +02:00
panfrost: Only access blitter from per-gen
Now the blitter may be compiled per-gen legally. Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11785>
This commit is contained in:
parent
88dc4db6be
commit
57da082a20
3 changed files with 14 additions and 13 deletions
|
|
@ -3690,6 +3690,15 @@ screen_destroy(struct pipe_screen *pscreen)
|
|||
pan_blitter_cleanup(dev);
|
||||
}
|
||||
|
||||
static void
|
||||
preload(struct panfrost_batch *batch, struct pan_fb_info *fb)
|
||||
{
|
||||
struct panfrost_device *dev = pan_device(batch->ctx->base.screen);
|
||||
|
||||
pan_preload_fb(&batch->pool.base, &batch->scoreboard, fb, batch->tls.gpu,
|
||||
pan_is_bifrost(dev) ? batch->tiler_ctx.bifrost : 0);
|
||||
}
|
||||
|
||||
void
|
||||
panfrost_cmdstream_screen_init(struct panfrost_screen *screen)
|
||||
{
|
||||
|
|
@ -3700,6 +3709,7 @@ panfrost_cmdstream_screen_init(struct panfrost_screen *screen)
|
|||
screen->vtbl.emit_fbd = emit_fbd;
|
||||
screen->vtbl.emit_fragment_job = emit_fragment_job;
|
||||
screen->vtbl.screen_destroy = screen_destroy;
|
||||
screen->vtbl.preload = preload;
|
||||
|
||||
pan_blitter_init(dev, &screen->blitter.bin_pool.base,
|
||||
&screen->blitter.desc_pool.base);
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@
|
|||
#include "drm-uapi/panfrost_drm.h"
|
||||
|
||||
#include "pan_bo.h"
|
||||
#include "pan_blitter.h"
|
||||
#include "pan_context.h"
|
||||
#include "util/hash_table.h"
|
||||
#include "util/ralloc.h"
|
||||
|
|
@ -664,16 +663,6 @@ panfrost_batch_to_fb_info(const struct panfrost_batch *batch,
|
|||
}
|
||||
}
|
||||
|
||||
static void
|
||||
panfrost_batch_draw_wallpaper(struct panfrost_batch *batch,
|
||||
struct pan_fb_info *fb)
|
||||
{
|
||||
struct panfrost_device *dev = pan_device(batch->ctx->base.screen);
|
||||
|
||||
pan_preload_fb(&batch->pool.base, &batch->scoreboard, fb, batch->tls.gpu,
|
||||
pan_is_bifrost(dev) ? batch->tiler_ctx.bifrost : 0);
|
||||
}
|
||||
|
||||
static int
|
||||
panfrost_batch_submit_ioctl(struct panfrost_batch *batch,
|
||||
mali_ptr first_job_desc,
|
||||
|
|
@ -864,8 +853,7 @@ panfrost_batch_submit(struct panfrost_batch *batch,
|
|||
|
||||
panfrost_batch_to_fb_info(batch, &fb, rts, &zs, &s, false);
|
||||
|
||||
panfrost_batch_draw_wallpaper(batch, &fb);
|
||||
|
||||
screen->vtbl.preload(batch, &fb);
|
||||
|
||||
if (!pan_is_bifrost(dev)) {
|
||||
mali_ptr polygon_list = panfrost_batch_get_polygon_list(batch);
|
||||
|
|
|
|||
|
|
@ -66,6 +66,9 @@ struct panfrost_vtable {
|
|||
|
||||
/* General destructor */
|
||||
void (*screen_destroy)(struct pipe_screen *);
|
||||
|
||||
/* Preload framebuffer */
|
||||
void (*preload)(struct panfrost_batch *, struct pan_fb_info *);
|
||||
};
|
||||
|
||||
struct panfrost_screen {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue