diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-05-26 08:23:45 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-05-26 20:44:59 +0100 |
commit | 2a0dc7ed4961d5bda08bb583a7a6a2cc633b27e4 (patch) | |
tree | a269f967fc4c1ef0c921e54ffd6841291d63b36c /src/sna/sna.h | |
parent | 05f149285b429c7b3f25ac8049477230aaef512c (diff) |
sna/dri2: Move scanout processing from frame event to global
The scanout is a global property, track it as so. The primary benefit to
this is it strengthens our assertions that we never hand out an active
scanout for use as a back buffer.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna.h')
-rw-r--r-- | src/sna/sna.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/sna/sna.h b/src/sna/sna.h index f88690c4..7a1b6932 100644 --- a/src/sna/sna.h +++ b/src/sna/sna.h @@ -315,6 +315,10 @@ struct sna { #if HAVE_DRI2 void *flip_pending; + struct { + struct kgem_bo *bo; + uint32_t name; + } scanout[2]; #endif } dri2; @@ -496,6 +500,7 @@ void sna_dri2_page_flip_handler(struct sna *sna, struct drm_event_vblank *event) void sna_dri2_vblank_handler(struct sna *sna, struct drm_event_vblank *event); void sna_dri2_pixmap_update_bo(struct sna *sna, PixmapPtr pixmap); void sna_dri2_destroy_window(WindowPtr win); +void sna_dri2_reset_scanout(struct sna *sna); void sna_dri2_close(struct sna *sna, ScreenPtr pScreen); #else static inline bool sna_dri2_open(struct sna *sna, ScreenPtr pScreen) { return false; } @@ -503,6 +508,7 @@ static inline void sna_dri2_page_flip_handler(struct sna *sna, struct drm_event_ static inline void sna_dri2_vblank_handler(struct sna *sna, struct drm_event_vblank *event) { } static inline void sna_dri2_pixmap_update_bo(struct sna *sna, PixmapPtr pixmap) { } static inline void sna_dri2_destroy_window(WindowPtr win) { } +static inline void sna_dri2_reset_scanout(struct sna *sna) { } static inline void sna_dri2_close(struct sna *sna, ScreenPtr pScreen) { } #endif |