iris: make blorp pin the binder
authorKenneth Graunke <kenneth@whitecape.org>
Mon, 23 Apr 2018 18:01:00 +0000 (11:01 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:06 +0000 (10:26 -0800)
src/gallium/drivers/iris/iris_binder.c
src/gallium/drivers/iris/iris_blorp.c

index b989a9c0ca75b4819a0a0c36441949f466562ea4..408e2007ae24d78874afa15c121f199a56871c76 100644 (file)
@@ -33,6 +33,9 @@ void *
 iris_binder_reserve(struct iris_binder *binder, unsigned size,
                     uint32_t *out_offset)
 {
+   /* XXX: if we ever make this allocate a new BO, then make binder_reserve
+    * return the BO, so at least verify use_pinned_bo gets the right one
+    */
    /* XXX: Implement a real ringbuffer, for now just croak if run out */
    assert(size > 0);
    assert(binder->insert_point + size <= BINDER_SIZE);
index c61fb1b483e2d5935b54d61e634b1099f7f4bb14..6b43a86a658b39fe2cd48a752f7196253137ee71 100644 (file)
@@ -132,6 +132,7 @@ blorp_alloc_binding_table(struct blorp_batch *blorp_batch,
    uint32_t *bt_map = iris_binder_reserve(&ice->state.binder,
                                           num_entries * sizeof(uint32_t),
                                           bt_offset);
+   iris_use_pinned_bo(batch, ice->state.binder.bo, false);
 
    for (unsigned i = 0; i < num_entries; i++) {
       surface_maps[i] = stream_state(batch, ice->state.surface_uploader,