summaryrefslogtreecommitdiff
path: root/src/sna/kgem.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-01-20 18:02:41 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2013-01-20 18:10:58 +0000
commit208ca91a31182e8ddad36e6a735c725362cbd071 (patch)
treedbb7c500c71161add0e8131e4a858b6cb4eef811 /src/sna/kgem.h
parent9a3e3abfe9b624af2354c5a69778aee3024fe46c (diff)
sna/gen7: Place the vsync commands in the same cacheline
Do as told; both the LRI and WAIT_FOR_EVENT need to be in the same cacheline for an unspecified reason. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/kgem.h')
-rw-r--r--src/sna/kgem.h9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/sna/kgem.h b/src/sna/kgem.h
index d2b89f54..b345b491 100644
--- a/src/sna/kgem.h
+++ b/src/sna/kgem.h
@@ -420,9 +420,9 @@ static inline bool kgem_check_batch_with_surfaces(struct kgem *kgem,
kgem_check_exec(kgem, num_surfaces);
}
-static inline uint32_t *kgem_get_batch(struct kgem *kgem, int num_dwords)
+static inline uint32_t *kgem_get_batch(struct kgem *kgem)
{
- if (!kgem_check_batch(kgem, num_dwords)) {
+ if (kgem->nreloc) {
unsigned mode = kgem->mode;
_kgem_submit(kgem);
_kgem_set_mode(kgem, mode);
@@ -431,11 +431,6 @@ static inline uint32_t *kgem_get_batch(struct kgem *kgem, int num_dwords)
return kgem->batch + kgem->nbatch;
}
-static inline void kgem_advance_batch(struct kgem *kgem, int num_dwords)
-{
- kgem->nbatch += num_dwords;
-}
-
bool kgem_check_bo(struct kgem *kgem, ...) __attribute__((sentinel(0)));
bool kgem_check_bo_fenced(struct kgem *kgem, struct kgem_bo *bo);
bool kgem_check_many_bo_fenced(struct kgem *kgem, ...) __attribute__((sentinel(0)));