drm: Fix fb leaks and WARN spew in get/set_prop ioctls
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 22 Apr 2016 20:10:28 +0000 (22:10 +0200)
committerDave Airlie <airlied@redhat.com>
Tue, 26 Apr 2016 23:53:54 +0000 (09:53 +1000)
commit1649c33ba34299f66d4f5b5a86964897a2923851
treecb50f076596b1e6d309af94ed89ad08535cb50e4
parent05981422ea178c908e451a97ac71dad886c27691
drm: Fix fb leaks and WARN spew in get/set_prop ioctls

Dave Airlie had at least the refcount leak fixed in a later patch (but
that patch does other things which need a bit more work). But we still
have the trouble that silly userspace could hit the WARN_ON in
drm_mode_object_find.

Fix this all up to make sure we don't leak objects, and don't spew
into demsg.

Fixes: d0f37cf62979 ("drm/mode: move framebuffer reference into object.")
Testcase: igt/kms_addfb_basic/invalid-*-prop*
Cc: Dave Airlie <airlied@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/drm_crtc.c