Global functions for promise management.

By introducing a global callback function, workq events can now be added
to promises.  A global function will allow creation of simple promises,
optionally with a callback function.