diff options
author | Andrzej Hajda <a.hajda@samsung.com> | 2014-09-30 16:49:56 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-10-03 10:38:56 +0200 |
commit | 1bcecfacde6269dc6cee9a098bc454222d441ff9 (patch) | |
tree | 1bb6021abc55846fcf9f0b4f44510e39afdbe8ed /drivers/gpu/drm/drm_drv.c | |
parent | 5a11f7f829a8d1b5c1c4774afcd263a2066d3179 (diff) | |
download | lwn-1bcecfacde6269dc6cee9a098bc454222d441ff9.tar.gz lwn-1bcecfacde6269dc6cee9a098bc454222d441ff9.zip |
drm/core: use helper to check driver features
The patch replaces direct access to driver_features field
by calls to helper function.
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/drm_drv.c')
-rw-r--r-- | drivers/gpu/drm/drm_drv.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c index 8889f8ec50ab..bc3da32d4585 100644 --- a/drivers/gpu/drm/drm_drv.c +++ b/drivers/gpu/drm/drm_drv.c @@ -595,7 +595,7 @@ struct drm_device *drm_dev_alloc(struct drm_driver *driver, goto err_ht; } - if (driver->driver_features & DRIVER_GEM) { + if (drm_core_check_feature(dev, DRIVER_GEM)) { ret = drm_gem_init(dev); if (ret) { DRM_ERROR("Cannot initialize graphics execution manager (GEM)\n"); @@ -625,7 +625,7 @@ static void drm_dev_release(struct kref *ref) { struct drm_device *dev = container_of(ref, struct drm_device, ref); - if (dev->driver->driver_features & DRIVER_GEM) + if (drm_core_check_feature(dev, DRIVER_GEM)) drm_gem_destroy(dev); drm_legacy_ctxbitmap_cleanup(dev); |