Skip to content

Commit

Permalink
nouveau: add stub dma-buf mmap functionality.
Browse files Browse the repository at this point in the history
This just adds a stub until we have some users in place to test
this with.

Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Dave Airlie committed May 31, 2012
1 parent 2dad9d4 commit e1bbc4b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/gpu/drm/nouveau/nouveau_prime.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ static void nouveau_gem_kunmap(struct dma_buf *dma_buf, unsigned long page_num,

}

static int nouveau_gem_prime_mmap(struct dma_buf *dma_buf, struct vm_area_struct *vma)
{
return -EINVAL;
}

static const struct dma_buf_ops nouveau_dmabuf_ops = {
.map_dma_buf = nouveau_gem_map_dma_buf,
.unmap_dma_buf = nouveau_gem_unmap_dma_buf,
Expand All @@ -69,6 +74,7 @@ static const struct dma_buf_ops nouveau_dmabuf_ops = {
.kmap_atomic = nouveau_gem_kmap_atomic,
.kunmap = nouveau_gem_kunmap,
.kunmap_atomic = nouveau_gem_kunmap_atomic,
.mmap = nouveau_gem_prime_mmap,
};

static int
Expand Down

0 comments on commit e1bbc4b

Please sign in to comment.