> -----Original Message----- > From: amd-gfx [mailto:amd-gfx-bounces at lists.freedesktop.org] On Behalf > Of Hristo Venev > Sent: Saturday, December 10, 2016 5:29 AM > To: amd-gfx at lists.freedesktop.org > Subject: drm/amdgpu/display: Multiple fixed-point implementations > > There are at least three implementations of fixed-point arithmetic in > drm/amdgpu/display: fixed31_32 (signed 32-32), fixed32_32 (unsigned 32- > 32) and bw_fixed (signed 40-24). I don't think fixed-point arithmetic > implementations belong in drivers. > > There already are two implementations of fixed-point in drm: fixed20_12 > (unsigned 20-12) and drm_fixp (signed 32-32). The latter could be used > instead of fixed31_32. > > Maybe we could use a standard fixed-point interface and share the > source code between most (or all) of the implementations. This is one > of the things that can be done before merging DC and is not too driver- > specific. What do you guys think? Sure. It would be nice to unify them especially if other drivers need them at some point. Alex