From: Tom Rini Date: Sat, 21 Nov 2020 08:04:08 -0500 Subject: [PATCHv2 01/25] lib: rational: copy the rational fraction lib routines from Linux In-Reply-To: <20201120112326.10350-2-t-kristo@ti.com> References: <20201120112326.10350-1-t-kristo@ti.com> <20201120112326.10350-2-t-kristo@ti.com> Message-ID: <20201121130408.GU32272@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Fri, Nov 20, 2020 at 01:23:02PM +0200, Tero Kristo wrote: > Copy the best rational approximation calculation routines from Linux. > Typical usecase for these routines is to calculate the M/N divider > values for PLLs to reach a specific clock rate. > > This is based on linux kernel commit: > "lib/math/rational.c: fix possible incorrect result from rational > fractions helper" > (sha1: 323dd2c3ed0641f49e89b4e420f9eef5d3d5a881) > > Signed-off-by: Tero Kristo Reviewed-by: Tom Rini -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: