[U-Boot] [PATCH 01/19] video: Add stb TrueType font renderer

Måns Rullgård mans at mansr.com
Thu Jan 21 18:05:55 CET 2016


Tom Rini <trini at konsulko.com> writes:

>> > style does not comply with U-Boot but I think it is best to leave alone to
>> > permit the source to be synced later if needed.
>> >
>> > The only change is to fix a reference to fabs() which should route through
>> > a macro to allow U-Boot to provide its own version.
>> 
>> This seems to be using floating-point quite a bit.  Unless I missed a
>> recent change, that's not allowed in u-boot.
>
> You are generally speaking, correct.  I am wondering if we don't need to
> make exceptions, from time to time.  For example, when we can easily
> correct general math problems by using something from <linux/math64.h>
> that's one thing and should be done.
>
> On the other hand, we have this, which is adding a nice looking font for
> the cases where our console is not a serial port but a screen and in
> some cases a rather nice high DPI one too.  So under the assumption that
> no, we can't find a font we can borrow that doesn't also use floating
> point, maybe we allow this, BUT with some caveats needing to be added
> such as noting that hey, what happens if you 'go' some benchmark that
> does FP stuff?  Well, it better be save/restoring, yes?

On some CPUs you also need to explicitly enable the FPU, and some rely
on software completion of certain operations (usually involving
subnormals).  Of course we shouldn't let that prevent other systems
having nice features.  We just need to be a bit careful about when we
enable them.

-- 
Måns Rullgård


More information about the U-Boot mailing list