Skip to content

Commit

Permalink
drm/kms: fix fb cmap allocation to use modeset->crtc not crtc
Browse files Browse the repository at this point in the history
crtc may be undefined at this point.

Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Ben Skeggs authored and Dave Airlie committed Dec 8, 2009
1 parent 447aeb9 commit b0a007d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/drm_fb_helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -908,7 +908,7 @@ int drm_fb_helper_single_fb_probe(struct drm_device *dev,

if (new_fb) {
info->var.pixclock = 0;
ret = fb_alloc_cmap(&info->cmap, crtc->gamma_size, 0);
ret = fb_alloc_cmap(&info->cmap, modeset->crtc->gamma_size, 0);
if (ret)
return ret;
if (register_framebuffer(info) < 0) {
Expand Down

0 comments on commit b0a007d

Please sign in to comment.