]> git.baikalelectronics.ru Git - kernel.git/commit
drm/vmwgfx: Don't refcount cotable lookups during command buffer validation
authorThomas Hellstrom <thellstrom@vmware.com>
Wed, 26 Sep 2018 14:29:49 +0000 (16:29 +0200)
committerThomas Hellstrom <thellstrom@vmware.com>
Fri, 28 Sep 2018 06:57:08 +0000 (08:57 +0200)
commitb510cc6591994b5aed4f6056a201579b1065973d
treee26303fbb82b5c14f7fe502926ffb52befb02a5c
parentf062b1ac2775c5ef7247a25cd6c559b5da654865
drm/vmwgfx: Don't refcount cotable lookups during command buffer validation

The typical pattern of these lookups are
-Lookup
-Put on validate list if not already there.
-Unreference
And since we are the exclusive user of the context during lookup time,
we can be sure that the resource will stay alive during the sequence.
So avoid taking a reference during lookup, and also avoid unreferencing
when done. There are two users outside of command buffer validation and
those are refcounted explicitly.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Sinclair Yeh <syeh@vmware.com>
drivers/gpu/drm/vmwgfx/vmwgfx_context.c
drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c
drivers/gpu/drm/vmwgfx/vmwgfx_shader.c
drivers/gpu/drm/vmwgfx/vmwgfx_so.c