Don't map the GEM uvm_aobj copy-on-write -- what was I thinking?
Do transfer the GEM object reference to the uvm_aobj reference -- these are not the same thing. (There's another uvm object whose references are the same thing as the GEM object references, but that's not the uao.) With these changes, it looks like the GPU is no longer trying to draw graphics all over kernel data structures. Wish I had that month of debugging back!
This commit is contained in:
parent
368fe5a982
commit
24c81ef173
@ -1490,9 +1490,11 @@ i915_gem_mmap_ioctl(struct drm_device *dev, void *data,
|
||||
obj->gemo_shm_uao, args->offset, 0,
|
||||
UVM_MAPFLAG((VM_PROT_READ | VM_PROT_WRITE),
|
||||
(VM_PROT_READ | VM_PROT_WRITE), UVM_INH_COPY, UVM_ADV_NORMAL,
|
||||
UVM_FLAG_COPYONW));
|
||||
0));
|
||||
if (ret)
|
||||
return ret;
|
||||
uao_reference(obj->gemo_shm_uao);
|
||||
drm_gem_object_unreference_unlocked(obj);
|
||||
#else
|
||||
addr = vm_mmap(obj->filp, 0, args->size,
|
||||
PROT_READ | PROT_WRITE, MAP_SHARED,
|
||||
|
Loading…
Reference in New Issue
Block a user