From: Michal Sojka Subject: Implemented synchronous and asynchronous sending The main goal of this big change is to avoid delays caused by CPU scheduler when rescheduling from application thread to VRES TX thread. According to our fwp-timing.c experiment, these delays can by even several milliseconds long. Now, whenever VRES capacity allows, send operation is invoked directly from application thread. Only if the budget is insufficient, the message can be queued for sending later by VRES thread, provided that asynchronous send was requested. In case of synchronous send, the application thread is blocked until the budget is replenished. Besides the above change, the code was cleaned up a lot. Signed-off-by: Michal Sojka