[PATCH 0/6] clk: Fix some error detection

Tom Rini trini at konsulko.com
Thu Dec 4 20:31:48 CET 2025


On Tue, 21 Oct 2025 17:08:24 +0100, Andrew Goodbody wrote:

> The function clk_get_rate() returns a ulong with 0 meaning an invalid
> clock rate and also negative error codes being returned for other
> errors. But being an unsigned return value this cannot simply be tested
> for with a < 0 test. Instead use the IS_ERR_VALUE() macro to check for
> negative errors appearing as very large positive values. Fix those
> places that test for <= 0. Also fix some places checking the return of
> clk_register() that incorrectly used ERR_PTR().
> 
> [...]

Applied to u-boot/next, thanks!

[1/6] mmc: hi6220_dw_mmc: Fix error detection for clk_get_rate
      commit: e24a7b3b172379b50a7fa96ab4634de109c3e432
[2/6] mmc: fsl_esdhc_imx: Cannot test unsigned to be < 0
      commit: 42d30f9447c136d2c1f46c8a12e6058e3cddc3b6
[3/6] clk: microchip: mpfs: Fix error detection
      commit: ae4f60801f344aa26e3f2d1ffe6f6227be6f16a2
[4/6] i2c: npcm: Fix error detection
      commit: eb13583b9de27005703ab085d5ef45fcdbb1d4fb
[5/6] i2c: imx_lpi2c: Fix error detection
      commit: 40ad377c1619eb9b83d088a96f40b86a907c8c19
[6/6] timer: imx-gpt: Fix error detection
      commit: ce219307a21fe7166b13542ba923ee09aef7f2f5
-- 
Tom




More information about the U-Boot mailing list