drm: Check for drm_device->dev in drm_set_busid
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 21 Jun 2017 13:04:29 +0000 (15:04 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 21 Jun 2017 15:38:43 +0000 (17:38 +0200)
commit22a884cfe5a49b6fd63f10ff137906028b4cf923
treeea040bdb084663d16aeea1139e0f260fb1e09a1a
parentc284a0bdb18d73d5480ca53598e8fead412c6653
drm: Check for drm_device->dev in drm_set_busid

I've failed to remember that we have virtual drivers like vgem which
have no underlying struct device. Fix this asap.

Reported-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Fixes: 5c484cee7ef9 ("drm: Remove drm_driver->set_busid hook")
Cc: Thierry Reding <treding@nvidia.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170621130429.20537-1-daniel.vetter@ffwll.ch
drivers/gpu/drm/drm_ioctl.c