[PATCH 0/6] Common functions for GEM (v2)

Rob Clark rob.clark at linaro.org
Mon Sep 12 12:21:20 PDT 2011


From: Rob Clark <rob at ti.com>

In the process of adding GEM support for omapdrm driver, I noticed that
I was adding code for creating/freeing mmap offsets which was virtually
identical to what was already duplicated in i915 and gma500 drivers.
And the code for attach/detatch_pages was quite similar as well.

Rather than duplicating the code a 3rd time, it seemed like a good idea
to move it to the GEM core.

Note that I don't actually have a way to test psb or i915, but the
changes seem straightforward enough.

v1: initial patches
v2: rebase + add common get/put_pages functions

Rob Clark (6):
  drm/gem: add functions for mmap offset creation
  drm/i915: use common functions for mmap offset creation
  drm/gma500: use common functions for mmap offset creation
  drm/gem: add functions to get/put pages
  drm/i915: use common functions for get/put pages
  drm/gma500: use common functions for get/put pages

 drivers/gpu/drm/drm_gem.c         |  156 +++++++++++++++++++++++++++++++++++++
 drivers/gpu/drm/i915/i915_gem.c   |  136 +++-----------------------------
 drivers/staging/gma500/gem.c      |    2 +-
 drivers/staging/gma500/gem_glue.c |   61 +--------------
 drivers/staging/gma500/gem_glue.h |    1 -
 drivers/staging/gma500/gtt.c      |   47 +++--------
 include/drm/drmP.h                |    6 ++
 7 files changed, 188 insertions(+), 221 deletions(-)

-- 
1.7.5.4



More information about the dri-devel mailing list