aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2009-10-12 00:21:19 -0400
committerDave Airlie <airlied@redhat.com>2009-10-12 00:21:42 -0400
commit39deb2d67515086f08a672e7574716ca0d3883a5 (patch)
treed80d9d99f5f6628c8229c0900a41001ac187ce82 /drivers/gpu
parentceeb50279b3d05eb7ea2b67e90acb2110d09325f (diff)
drm/radeon/kms: fix use of index before proper initialisation.
With the adjust table introduction, we need to fill out index before getting the table version. Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/radeon/atombios_crtc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/radeon/atombios_crtc.c b/drivers/gpu/drm/radeon/atombios_crtc.c
index 7522af1b9e46..3409aa3cbee4 100644
--- a/drivers/gpu/drm/radeon/atombios_crtc.c
+++ b/drivers/gpu/drm/radeon/atombios_crtc.c
@@ -454,6 +454,7 @@ void atombios_crtc_set_pll(struct drm_crtc *crtc, struct drm_display_mode *mode)
454 radeon_compute_pll(pll, adjusted_clock, &pll_clock, &fb_div, &frac_fb_div, 454 radeon_compute_pll(pll, adjusted_clock, &pll_clock, &fb_div, &frac_fb_div,
455 &ref_div, &post_div, pll_flags); 455 &ref_div, &post_div, pll_flags);
456 456
457 index = GetIndexIntoMasterTable(COMMAND, SetPixelClock);
457 atom_parse_cmd_header(rdev->mode_info.atom_context, index, &frev, 458 atom_parse_cmd_header(rdev->mode_info.atom_context, index, &frev,
458 &crev); 459 &crev);
459 460
@@ -513,7 +514,6 @@ void atombios_crtc_set_pll(struct drm_crtc *crtc, struct drm_display_mode *mode)
513 } 514 }
514 515
515 printk("executing set pll\n"); 516 printk("executing set pll\n");
516 index = GetIndexIntoMasterTable(COMMAND, SetPixelClock);
517 atom_execute_table(rdev->mode_info.atom_context, index, (uint32_t *)&args); 517 atom_execute_table(rdev->mode_info.atom_context, index, (uint32_t *)&args);
518} 518}
519 519