linux/drivers/gpu/drm/amd/display/dc/calcs
Arnd Bergmann 1f3493faa8 drm/amdgpu/display: fix integer arithmetic problem
gcc warns about an ambiguous integer calculation:

drivers/gpu/drm/amd/amdgpu/../display/dc/calcs/dce_calcs.c: In function 'calculate_bandwidth':
drivers/gpu/drm/amd/amdgpu/../display/dc/calcs/dce_calcs.c:534:5: error: this decimal constant is unsigned only in ISO C90 [-Werror]
     data->lb_line_pitch = bw_ceil2(bw_mul(bw_div(bw_frc_to_fixed(2401171875, 100000000), bw_int_to_fixed(3)), bw_ceil2(data->source_width_in_lb, bw_int_to_fixed(8))), bw_int_to_fixed(48));
     ^~~~

Marking the constant as explicitly unsigned makes it work fine everywhere
without warnings.

Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-11-02 13:44:41 -04:00
..
bw_fixed.c amdgpu/dc: allow inlining constant int to fixed a lot better. 2017-09-29 13:03:35 -04:00
custom_float.c drm/amd/display: Enable regamma 25 segments and use double buffer. 2017-09-26 17:14:18 -04:00
dce_calcs.c drm/amdgpu/display: fix integer arithmetic problem 2017-11-02 13:44:41 -04:00
dcn_calc_auto.c drm/amd/display: fix PHYCLK in formula. 2017-09-26 18:16:13 -04:00
dcn_calc_auto.h drm/amdgpu/display: Add calcs code for DCN 2017-09-26 18:06:47 -04:00
dcn_calc_math.c drm/amd/display: Restructuring and cleaning up DML 2017-10-21 16:45:24 -04:00
dcn_calc_math.h Revert "amdgpu/dc: inline a bunch of float operations." 2017-10-21 16:45:17 -04:00
dcn_calcs.c drm/amd/display: add performance trace macro to dc 2017-10-21 16:50:00 -04:00
Makefile drm/amd/display: Ignore wrong tautological warning 2017-10-21 16:48:10 -04:00