git: e39e6bef6725 - main - arm/allwinner: fix variables initialization in clkng
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 20 Sep 2023 17:38:16 UTC
The branch main has been updated by manu: URL: https://cgit.FreeBSD.org/src/commit/?id=e39e6bef6725bde54f94aac7f0cda47c2170dc48 commit e39e6bef6725bde54f94aac7f0cda47c2170dc48 Author: Nicolas Provost <dev@npsoft.fr> AuthorDate: 2023-09-20 08:49:31 +0000 Commit: Emmanuel Vadot <manu@FreeBSD.org> CommitDate: 2023-09-20 17:37:50 +0000 arm/allwinner: fix variables initialization in clkng Signed-off-by: Nicolas Provost <dev@npsoft.fr> Pull-Request: https://github.com/freebsd/freebsd-src/pull/849 --- sys/arm/allwinner/clkng/aw_clk_m.c | 2 +- sys/arm/allwinner/clkng/aw_clk_nm.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/arm/allwinner/clkng/aw_clk_m.c b/sys/arm/allwinner/clkng/aw_clk_m.c index 1d3d5a9878f7..2728ff230a9f 100644 --- a/sys/arm/allwinner/clkng/aw_clk_m.c +++ b/sys/arm/allwinner/clkng/aw_clk_m.c @@ -135,7 +135,7 @@ static uint64_t aw_clk_m_find_best(struct aw_clk_m_sc *sc, uint64_t fparent, uint64_t *fout, uint32_t *factor_m) { - uint64_t cur, best; + uint64_t cur, best = 0; uint32_t m, max_m, min_m; *factor_m = 0; diff --git a/sys/arm/allwinner/clkng/aw_clk_nm.c b/sys/arm/allwinner/clkng/aw_clk_nm.c index a1cba2db5f76..61592eb04de1 100644 --- a/sys/arm/allwinner/clkng/aw_clk_nm.c +++ b/sys/arm/allwinner/clkng/aw_clk_nm.c @@ -136,7 +136,7 @@ static uint64_t aw_clk_nm_find_best(struct aw_clk_nm_sc *sc, uint64_t fparent, uint64_t *fout, uint32_t *factor_n, uint32_t *factor_m) { - uint64_t cur, best; + uint64_t cur, best = 0; uint32_t m, n, max_m, max_n, min_m, min_n; *factor_n = *factor_m = 0;