git: 768787bee30d - main - mtk: Initialize mask correctly.
Warner Losh
imp at FreeBSD.org
Fri Jun 11 20:30:47 UTC 2021
The branch main has been updated by imp:
URL: https://cgit.FreeBSD.org/src/commit/?id=768787bee30dd86f5060f1083745955e2cbcf28f
commit 768787bee30dd86f5060f1083745955e2cbcf28f
Author: Priit Trees <trees at neti.ee>
AuthorDate: 2021-06-11 20:12:08 +0000
Commit: Warner Losh <imp at FreeBSD.org>
CommitDate: 2021-06-11 20:12:08 +0000
mtk: Initialize mask correctly.
Initialization of mask is missing. Fixes a compile issue.
Reviewed by: imp@
Pull Request: https://github.com/freebsd/freebsd-src/pull/459
---
sys/mips/mediatek/mtk_clock.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sys/mips/mediatek/mtk_clock.c b/sys/mips/mediatek/mtk_clock.c
index 83433fbd8ff9..915207b755af 100644
--- a/sys/mips/mediatek/mtk_clock.c
+++ b/sys/mips/mediatek/mtk_clock.c
@@ -123,6 +123,8 @@ mtk_clock_get_info(device_t dev, int index, struct fdt_clock_info *info)
if (index < 0 || index > 31 || info == NULL)
return (EINVAL);
+ mask = (1u << index);
+
if (mtk_sysctl_get(SYSCTL_CLKCFG1) & mask)
info->flags = FDT_CIFLAG_RUNNING;
else
More information about the dev-commits-src-all
mailing list