summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/soc/nvidia/tegra124/clock.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/soc/nvidia/tegra124/clock.c b/src/soc/nvidia/tegra124/clock.c
index 6877c04b98..bb0343d432 100644
--- a/src/soc/nvidia/tegra124/clock.c
+++ b/src/soc/nvidia/tegra124/clock.c
@@ -13,6 +13,7 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*/
+#include <assert.h>
#include <arch/clock.h>
#include <device/mmio.h>
#include <console/console.h>
@@ -377,6 +378,7 @@ clock_display(u32 frequency)
printk(BIOS_WARNING, "%s: Failed to match output frequency %u, "
"best difference is %u.\n", __func__, frequency,
best_diff);
+ assert(plld.m != 0);
rounded_rate = (ref / plld.m * plld.n) >> plld.p;
}