At present assert() is not supported with tiny-printf, so when DEBUG is
enabled a build error is generated for each assert().
Add an __assert_fail() function to correct this. It prints a message and
then hangs.
Signed-off-by: Simon Glass <sjg@chromium.org>
return ret;
}
+
+void __assert_fail(const char *assertion, const char *file, unsigned line,
+ const char *function)
+{
+ /* This will not return */
+ printf("%s:%u: %s: Assertion `%s' failed.", file, line, function,
+ assertion);
+ hang();
+}