diff options
author | Patrik Jakobsson <patrik.r.jakobsson@gmail.com> | 2014-01-06 02:39:10 +0100 |
---|---|---|
committer | Patrik Jakobsson <patrik.r.jakobsson@gmail.com> | 2014-03-17 20:11:59 +0100 |
commit | c269c6852bc4b0c3e1d755c4449f4307aa57292b (patch) | |
tree | c6a6c4548b5cd2266888eb6e36ca77b3de8fcca3 /drivers/gpu/drm/gma500/gem.c | |
parent | drm/gma500: Remove unused ioctls (diff) | |
download | linux-c269c6852bc4b0c3e1d755c4449f4307aa57292b.tar.xz linux-c269c6852bc4b0c3e1d755c4449f4307aa57292b.zip |
drm/gma500: Add backing type and base align to psb_gem_create()
We'll need this for our gem create ioctl in a later patch.
Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/gma500/gem.c')
-rw-r--r-- | drivers/gpu/drm/gma500/gem.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/gma500/gem.c b/drivers/gpu/drm/gma500/gem.c index 1e33a71e4167..d0243c088272 100644 --- a/drivers/gpu/drm/gma500/gem.c +++ b/drivers/gpu/drm/gma500/gem.c @@ -98,8 +98,8 @@ unlock: * it so that userspace can speak about it. This does the core work * for the various methods that do/will create GEM objects for things */ -static int psb_gem_create(struct drm_file *file, - struct drm_device *dev, uint64_t size, uint32_t *handlep) +int psb_gem_create(struct drm_file *file, struct drm_device *dev, u64 size, + u32 *handlep, int stolen, u32 align) { struct gtt_range *r; int ret; @@ -109,7 +109,7 @@ static int psb_gem_create(struct drm_file *file, /* Allocate our object - for now a direct gtt range which is not stolen memory backed */ - r = psb_gtt_alloc_range(dev, size, "gem", 0); + r = psb_gtt_alloc_range(dev, size, "gem", 0, PAGE_SIZE); if (r == NULL) { dev_err(dev->dev, "no memory for %lld byte GEM object\n", size); return -ENOSPC; @@ -153,7 +153,8 @@ int psb_gem_dumb_create(struct drm_file *file, struct drm_device *dev, { args->pitch = ALIGN(args->width * ((args->bpp + 7) / 8), 64); args->size = args->pitch * args->height; - return psb_gem_create(file, dev, args->size, &args->handle); + return psb_gem_create(file, dev, args->size, &args->handle, 0, + PAGE_SIZE); } /** |