msm: kgsl: Store process mem entries in a rbtree

The list of memory objects attached to a process gets searched quite
a lot during normal operation of the driver.  For processes with a
lot of memory allocations, the linear search through the list is O(N)
and uses a lot more CPU during critical loops than it should. Change
the mem entry list to a rbtree for faster search speeds.

Change-Id: Ic0dedbad1b25d9d77f56f93696b2fe933fbad333
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
diff --git a/drivers/gpu/msm/kgsl_device.h b/drivers/gpu/msm/kgsl_device.h
index 2eacf22..69964e3 100644
--- a/drivers/gpu/msm/kgsl_device.h
+++ b/drivers/gpu/msm/kgsl_device.h
@@ -216,7 +216,7 @@
 	unsigned int refcnt;
 	pid_t pid;
 	spinlock_t mem_lock;
-	struct list_head mem_list;
+	struct rb_root mem_rb;
 	struct kgsl_pagetable *pagetable;
 	struct list_head list;
 	struct kobject kobj;