diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2020-09-04 17:39:19 +0300 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2020-09-11 11:47:19 +0300 |
commit | dad75a5208ec88779d9ccd2c95ef5de659209208 (patch) | |
tree | 90fff985de63bda54c18a39ca81048f90bfee6f8 /drivers/gpu/drm/armada/armada_fbdev.c | |
parent | 90ad200b4cbc92e160c3f3331bb999f87cc0fbfd (diff) | |
download | linux-dad75a5208ec88779d9ccd2c95ef5de659209208.tar.xz |
drm/armada: Don't use drm_device->dev_private
Upcasting using a container_of macro is more typesafe, faster and
easier for the compiler to optimize.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Cc: Russell King <linux@armlinux.org.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20200904143941.110665-3-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu/drm/armada/armada_fbdev.c')
-rw-r--r-- | drivers/gpu/drm/armada/armada_fbdev.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/armada/armada_fbdev.c b/drivers/gpu/drm/armada/armada_fbdev.c index 0c4601275507..38f5170c0fea 100644 --- a/drivers/gpu/drm/armada/armada_fbdev.c +++ b/drivers/gpu/drm/armada/armada_fbdev.c @@ -117,7 +117,7 @@ static const struct drm_fb_helper_funcs armada_fb_helper_funcs = { int armada_fbdev_init(struct drm_device *dev) { - struct armada_private *priv = dev->dev_private; + struct armada_private *priv = drm_to_armada_dev(dev); struct drm_fb_helper *fbh; int ret; @@ -151,7 +151,7 @@ int armada_fbdev_init(struct drm_device *dev) void armada_fbdev_fini(struct drm_device *dev) { - struct armada_private *priv = dev->dev_private; + struct armada_private *priv = drm_to_armada_dev(dev); struct drm_fb_helper *fbh = priv->fbdev; if (fbh) { |