diff options
author | Fabian Frederick <fabf@skynet.be> | 2014-09-14 20:40:20 +0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-09-24 14:09:27 +0400 |
commit | c39aa6a1e32aab4826c613866024cbdd4933631a (patch) | |
tree | 2abd342e99f5a718f02e02eefe019aa301ab8acf /drivers/gpu/drm/gma500 | |
parent | f38e34ac54569756963827434d4b18b9ad9d8b95 (diff) | |
download | linux-c39aa6a1e32aab4826c613866024cbdd4933631a.tar.xz |
drm/gma500: use container_of to resolve psb_fbdev from drm_fb_helper
Use container_of instead of casting first structure member.
Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/gma500')
-rw-r--r-- | drivers/gpu/drm/gma500/framebuffer.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/gma500/framebuffer.c b/drivers/gpu/drm/gma500/framebuffer.c index d0dd3bea8aa5..ddd90ddbc200 100644 --- a/drivers/gpu/drm/gma500/framebuffer.c +++ b/drivers/gpu/drm/gma500/framebuffer.c @@ -540,7 +540,8 @@ static void psbfb_gamma_get(struct drm_crtc *crtc, u16 *red, static int psbfb_probe(struct drm_fb_helper *helper, struct drm_fb_helper_surface_size *sizes) { - struct psb_fbdev *psb_fbdev = (struct psb_fbdev *)helper; + struct psb_fbdev *psb_fbdev = + container_of(helper, struct psb_fbdev, psb_fb_helper); struct drm_device *dev = psb_fbdev->psb_fb_helper.dev; struct drm_psb_private *dev_priv = dev->dev_private; int bytespp; |