3aac4502fd3f80dcf7e65dbf6edd8676893c1f46 |
|
01-Jul-2014 |
Maarten Lankhorst <maarten.lankhorst@canonical.com> |
dma-buf: use reservation objects This allows reservation objects to be used in dma-buf. it's required for implementing polling support on the fences that belong to a dma-buf. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com> Acked-by: Mauro Carvalho Chehab <m.chehab@samsung.com> #drivers/media/v4l2-core/ Acked-by: Thomas Hellstrom <thellstrom@vmware.com> #drivers/gpu/drm/ttm Acked-by: Sumit Semwal <sumit.semwal@linaro.org> Acked-by: Daniel Vetter <daniel@ffwll.ch> Signed-off-by: Vincent Stehlé <vincent.stehle@laposte.net> #drivers/gpu/drm/armada/ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|
0d3215e3857ab679f74c9b26b7e711955c9d0438 |
|
19-Mar-2014 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Add a ttm_ref_object_exists function A function to be used to check whether a caller has put a ref object (opened) a struct ttm_base_object Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
|
c66f854338253e603a4fb6817069ee23eacf0ae3 |
|
24-Jan-2014 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Fix TTM object open regression Commit drm/ttm: ttm object security fixes for render nodes introduced a regression where, if a TTM object was opened multiple times from the same open file, the caller would spin uninterruptibly in the kernel. Fix this. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
|
05efb1abecce6e36457ae1a7be29ded7ac52292a |
|
18-Dec-2013 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: ttm object security fixes for render nodes When a client looks up a ttm object, don't look it up through the device hash table, but rather from the file hash table. That makes sure that the client has indeed put a reference on the object, or in gem terms, has opened the object; either using prime or using the global "name". To avoid a performance loss, make sure the file hash table entries can be looked up from under an RCU lock, and as a consequence, replace the rwlock with a spinlock, since we never need to take it in read mode only anymore. Finally add a ttm object lookup function for the device hash table, that is intended to be used when we put a ref object on a base object or, in gem terms, when we open the object. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
|
65981f7681abdf92b25942222b629b9c512d0705 |
|
13-Nov-2013 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Add a minimal prime implementation for ttm base objects Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
|
bcf73a10837e9695f5ca7e3e65bf6ce850692d41 |
|
13-Sep-2013 |
Prarit Bhargava <prarit@redhat.com> |
drm, ttm Fix uninitialized warning Fix uninitialized warning. drivers/gpu/drm/ttm/ttm_object.c: In function ‘ttm_base_object_lookup’: drivers/gpu/drm/ttm/ttm_object.c:213:10: error: ‘base’ may be used uninitialized in this function [-Werror=maybe-uninitialized] kref_put(&base->refcount, ttm_release_base); ^ drivers/gpu/drm/ttm/ttm_object.c:221:26: note: ‘base’ was declared here struct ttm_base_object *base; Signed-off-by: Prarit Bhargava <prarit@redhat.com> Reviewed-by: Rob Clark <robdclark@gmail.com> Reviewed-by: David Herrmann <dh.herrmann@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
5293908afa04b651cc8a7e85ba0938b71f97c2f8 |
|
20-Nov-2012 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Use the hashtab _rcu interface for ttm_objects Also move a kref_init() out of spinlocked region Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
ae8df2ae8aa27bfeb8d1b99e8adaac5810a97fa8 |
|
20-Nov-2012 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Fix locking in an error path Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
cdad05216c2b2edfe92a9f87d6ae51aab277f3b2 |
|
06-Nov-2012 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm, drm/vmwgfx: Use RCU locking for object lookups v3 The mostly used lookup+get put+potential_destroy path of TTM objects is converted to use RCU locks. This will substantially decrease the amount of locked bus cycles during normal operation. Since we use kfree_rcu to free the objects, no rcu synchronization is needed at module unload time. v2: Don't touch include/linux/kref.h v3: Adapt to kref_get_unless_zero return value change Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
760285e7e7ab282c25b5e90816f7c47000557f4f |
|
02-Oct-2012 |
David Howells <dhowells@redhat.com> |
UAPI: (Scripted) Convert #include "..." to #include <path/...> in drivers/gpu/ Convert #include "..." to #include <path/...> in drivers/gpu/. Signed-off-by: David Howells <dhowells@redhat.com> Acked-by: Dave Airlie <airlied@redhat.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Acked-by: Dave Jones <davej@redhat.com>
|
25d0479a5925562fbf999afb5a8daa3f501c729d |
|
17-Mar-2012 |
Joe Perches <joe@perches.com> |
drm/ttm: Use pr_fmt and pr_<level> Use the more current logging style. Add pr_fmt and remove the TTM_PFX uses. Coalesce formats and align arguments. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
60063497a95e716c9a689af3be2687d261f115b4 |
|
27-Jul-2011 |
Arun Sharma <asharma@fb.com> |
atomic: use <linux/atomic.h> This allows us to move duplicated code in <asm/atomic.h> (atomic_inc_not_zero() for now) to <linux/atomic.h> Signed-off-by: Arun Sharma <asharma@fb.com> Reviewed-by: Eric Dumazet <eric.dumazet@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: David Miller <davem@davemloft.net> Cc: Eric Dumazet <eric.dumazet@gmail.com> Acked-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
|
cdb650a4b5eaf1c0aedbfd7dd6afd6d465c3b0a0 |
|
27-Feb-2011 |
Paul Bolle <pebolle@tiscali.nl> |
drm: minor kref_put() nits There's no need to pass kref_put() the address of a function (just the function will do just fine) nor to cast its unused return to void. Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
|
dd5fde6041d7ea30fcfedcc159a4cec8b01f73b2 |
|
26-Jan-2010 |
Richard Kennedy <richard@rsk.demon.co.uk> |
drm/ttm: remove padding from ttm_ref_object on 64bit builds Re-order structure ttm_ref_object to remove 8 bytes of alignment padding on 64 bit builds, so shrinking its size from 72 to 64 bytes allowing it to fit into a smaller slab. Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk> Acked-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|
88071539a3f5195f9e9dae38a3e35b3ce4b9f9fc |
|
06-Dec-2009 |
Thomas Hellstrom <thellstrom@vmware.com> |
drm/ttm: Add user-space objects. Add objects needed for user-space to maintain reference counts on ttm objects. This is used by the vmwgfx driver which allows user-space to maintain map-counts on dma buffers, lock-counts on the ttm lock and ref-counts on gpu surfaces, gpu contexts and dma buffer. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
|