diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2012-12-17 23:04:25 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2012-12-17 23:13:41 +0000 |
commit | f522fbe7c98ffad86126c3666b2d9f7e616480b8 (patch) | |
tree | cef866946282e969943c247f7e8ac93a00cb0511 /src/sna/kgem.h | |
parent | 6c50cf4809816dbbd93d54f589a79b0dab996180 (diff) |
sna: Refine check for an unset context switch
So it appears that we end up performing a context switch on an empty
batch, but already has a mode. This is caught later, too late, by
assertions. However, we can change the guards slightly to prevent those
assertions without altering the code too greatly. And I can then think
how to detect where we are setting a mode on the batch but doing no
work - which is likely masking a bigger bug.
Reported-by: Jiri Slaby <jirislaby@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=47597
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/kgem.h')
-rw-r--r-- | src/sna/kgem.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sna/kgem.h b/src/sna/kgem.h index c23b9e33..c5199c2d 100644 --- a/src/sna/kgem.h +++ b/src/sna/kgem.h @@ -354,7 +354,7 @@ static inline void kgem_set_mode(struct kgem *kgem, #endif if (kgem->nexec && bo->exec == NULL && kgem_ring_is_idle(kgem, kgem->ring)) - kgem_submit(kgem); + _kgem_submit(kgem); if (kgem->mode == mode) return; |