Commit 5e6dde7e authored by Michel Dänzer's avatar Michel Dänzer Committed by Dave Airlie

drm/radeon/kms: Move radeon_get_clock_info() call out of radeon_clocks_init().

Someone on IRC reported problems after commit
95a8f1bf ('drm/radeon/kms: Move
radeon_clocks_init() call back after getting VRAM info.'). And indeed, at least
some ASIC vram_info hooks use the clock info obtained by
radeon_get_clock_info(). So, move that call out of radeon_clocks_init(), ahead
of the radeon_vram_info() call.

[airlied - fixup missing r600/rv770 calls]
Signed-off-by: default avatarMichel Dänzer <daenzer@vmware.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>

drm/radeon/kms: fix get clock info calls for r600/rv770 init path.

These were missed when it got split out.
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent 445282db
...@@ -1537,6 +1537,7 @@ int r600_init(struct radeon_device *rdev) ...@@ -1537,6 +1537,7 @@ int r600_init(struct radeon_device *rdev)
r600_scratch_init(rdev); r600_scratch_init(rdev);
/* Initialize surface registers */ /* Initialize surface registers */
radeon_surface_init(rdev); radeon_surface_init(rdev);
radeon_get_clock_info(rdev->ddev);
r = radeon_clocks_init(rdev); r = radeon_clocks_init(rdev);
if (r) if (r)
return r; return r;
......
...@@ -386,7 +386,6 @@ int radeon_clocks_init(struct radeon_device *rdev) ...@@ -386,7 +386,6 @@ int radeon_clocks_init(struct radeon_device *rdev)
{ {
int r; int r;
radeon_get_clock_info(rdev->ddev);
r = radeon_static_clocks_init(rdev->ddev); r = radeon_static_clocks_init(rdev->ddev);
if (r) { if (r) {
return r; return r;
...@@ -617,7 +616,8 @@ int radeon_device_init(struct radeon_device *rdev, ...@@ -617,7 +616,8 @@ int radeon_device_init(struct radeon_device *rdev,
radeon_combios_asic_init(rdev->ddev); radeon_combios_asic_init(rdev->ddev);
} }
} }
/* Get vram informations */ /* Get clock & vram information */
radeon_get_clock_info(rdev->ddev);
radeon_vram_info(rdev); radeon_vram_info(rdev);
/* Initialize clocks */ /* Initialize clocks */
r = radeon_clocks_init(rdev); r = radeon_clocks_init(rdev);
......
...@@ -917,6 +917,7 @@ int rv770_init(struct radeon_device *rdev) ...@@ -917,6 +917,7 @@ int rv770_init(struct radeon_device *rdev)
r600_scratch_init(rdev); r600_scratch_init(rdev);
/* Initialize surface registers */ /* Initialize surface registers */
radeon_surface_init(rdev); radeon_surface_init(rdev);
radeon_get_clock_info(rdev->ddev);
r = radeon_clocks_init(rdev); r = radeon_clocks_init(rdev);
if (r) if (r)
return r; return r;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment