* [PATCH] drm/radeon: fix 64 bit divide in SI spm code
@ 2013-08-01 13:03 alexdeucher
0 siblings, 0 replies; only message in thread
From: alexdeucher @ 2013-08-01 13:03 UTC (permalink / raw)
To: dri-devel; +Cc: Alex Deucher
From: Alex Deucher <alexander.deucher@amd.com>
Forgot to use the appropriate math64 function.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
This is already in my -fixes queue, but for those that are running into
issues, here's the fix.
drivers/gpu/drm/radeon/si_dpm.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/gpu/drm/radeon/si_dpm.c b/drivers/gpu/drm/radeon/si_dpm.c
index 7ad22e8..4182557 100644
--- a/drivers/gpu/drm/radeon/si_dpm.c
+++ b/drivers/gpu/drm/radeon/si_dpm.c
@@ -1767,7 +1767,7 @@ static void si_calculate_leakage_for_v_and_t_formula(const struct ni_leakage_coe
s64 temperature, t_slope, t_intercept, av, bv, t_ref;
s64 tmp;
- i_leakage = drm_int2fixp(ileakage) / 100;
+ i_leakage = div64_s64(drm_int2fixp(ileakage), 100);
vddc = div64_s64(drm_int2fixp(v), 1000);
temperature = div64_s64(drm_int2fixp(t), 1000);
--
1.7.7.5
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-08-01 13:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-01 13:03 [PATCH] drm/radeon: fix 64 bit divide in SI spm code alexdeucher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox