#define asynsend(ep, msg) asynsend3(ep, msg, 0)
int asynsend3(endpoint_t ep, message *msg, int flags);
int asyn_geterror(endpoint_t *dst, message *msg, int *err);
+int senda_reload(void);
#define ASSERT(c) if(!(c)) { panic("%s:%d: assert %s failed", __FILE__, __LINE__, #c); }
int i, r, src_ind, dst_ind;
unsigned flags;
static int inside = 0;
- int len, needack = 0;
+ int needack = 0;
/* Debug printf() causes asynchronous sends? */
if (inside) /* Panic will not work either then, so exit */
*/
next_slot++;
+ /* Reload. */
+ inside = 0;
+ r = senda_reload();
+
+ return r;
+}
+
+/*===========================================================================*
+ * senda_reload *
+ *===========================================================================*/
+int senda_reload()
+{
+ int len;
+
assert(next_slot >= first_slot);
len = next_slot - first_slot;
assert(first_slot + len <= ASYN_NR);
assert(len >= 0);
- inside = 0;
-
/* Tell the kernel to rescan the table */
return ipc_senda(&msgtable[first_slot], len);
}