I'm certain that we (currently) depend on the heap allocator calling this function when an allocation fails during init.

No other PIOS code calls this function directly but it could easily trigger it indirectly be (previously) calling pvPortMalloc().  Now that *this* is the heap allocator, we will equally depend on this notifying systemmod of the failure.

If you really don't like this, I can set an (internal) flag in this file and export a query function so the underrun state can be read by systemmod.c after it has finished calling all of the module initialize functions.  That will remove the feature that the application could be notified synchronously though.  Not a huge problem but thought I'd point it out for consideration.