dol: initial dol commit
[jump.git] / dol / src / dol / visitor / rtems / lib / dol.h
diff --git a/dol/src/dol/visitor/rtems/lib/dol.h b/dol/src/dol/visitor/rtems/lib/dol.h
new file mode 100644 (file)
index 0000000..f07b246
--- /dev/null
@@ -0,0 +1,26 @@
+#ifndef __DOL_H__
+#define __DOL_H__
+
+//structure for local memory of process
+typedef struct _local_states *LocalState;
+
+//structure for process
+struct _process;
+
+//
+typedef void (*ProcessInit)(struct _process*);
+typedef int (*ProcessFire)(struct _process*);
+typedef void *WPTR;
+
+typedef struct _process {
+    LocalState     local;
+    ProcessInit    init;
+    ProcessFire    fire;
+    WPTR           wptr;
+} DOLProcess;
+
+void DOL_read(void *port, void *buf, int len, DOLProcess *process);
+void DOL_write(void *port, void *buf, int len, DOLProcess *process);
+void DOL_detach(DOLProcess *process);
+
+#endif