drm/msm: a6xx: Fix improper u64 division
authorSean Paul <[email protected]>
Mon, 8 Oct 2018 18:24:14 +0000 (14:24 -0400)
committerRob Clark <[email protected]>
Tue, 9 Oct 2018 00:16:01 +0000 (20:16 -0400)
commit16f37102181e23ec4bec88fe1cfdd6c3c24dd1ed
treea073db2f7f9f9b919bd91248fb27762e3a7fdb77
parent0f5427219bdf3e3d0ba94e4fbefe623a57616825
drm/msm: a6xx: Fix improper u64 division

This patch uses the proper do_div() macro to perform u64 division and
guards against overflow if the result is too large for the unsigned long
return type

Fixes: a2c3c0a54d4c drm/msm/a6xx: Add devfreq support for a6xx
Cc: Sharat Masetty <[email protected]>
Signed-off-by: Sean Paul <[email protected]>
Signed-off-by: Rob Clark <[email protected]>
drivers/gpu/drm/msm/adreno/a6xx_gpu.c