From: Christian Gmeiner Date: Wed, 8 Jan 2014 07:24:25 +0000 (+0100) Subject: imx6: make use of lldiv(..) X-Git-Tag: v2014.01~13^2~4 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=5a66016987cd1c77468709070c989cced721b107;p=u-boot imx6: make use of lldiv(..) Commit 762a88ccf8540948fbf8c31b40a29d1e0684a25b introduces a 64-bit division without using the lldiv() function, which pulls in previously unused libgcc stuff. Signed-off-by: Måns Rullgård Signed-off-by: Christian Gmeiner Acked-by: Stefano Babic --- diff --git a/arch/arm/cpu/armv7/mx6/clock.c b/arch/arm/cpu/armv7/mx6/clock.c index fcc4f352c3..f12bba2944 100644 --- a/arch/arm/cpu/armv7/mx6/clock.c +++ b/arch/arm/cpu/armv7/mx6/clock.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -123,7 +124,7 @@ static u32 mxc_get_pll_pfd(enum pll_clocks pll, int pfd_num) return 0; } - return (freq * 18) / ((div & ANATOP_PFD_FRAC_MASK(pfd_num)) >> + return lldiv(freq * 18, (div & ANATOP_PFD_FRAC_MASK(pfd_num)) >> ANATOP_PFD_FRAC_SHIFT(pfd_num)); }