diff dyncallback/dyncall_callback_mips.c @ 152:d48a8b8d2ef9

- integrated all headers containing DCCallback definition into the translation units used (arm64 already avoided this pointless header, so following that style) - some cleanups, removal of unnecessary includes, etc.
author cslag
date Sat, 22 Oct 2016 15:55:54 +0200
parents 8a6111c2a84a
children 030fbb70aa1b
line wrap: on
line diff
--- a/dyncallback/dyncall_callback_mips.c	Sat Sep 17 14:31:54 2016 +0200
+++ b/dyncallback/dyncall_callback_mips.c	Sat Oct 22 15:55:54 2016 +0200
@@ -6,7 +6,7 @@
  Description: Callback - Implementation Header for MIPS
  License:
 
-   Copyright (c) 2013-2015 Daniel Adler <dadler@uni-goettingen.de>,
+   Copyright (c) 2013-2016 Daniel Adler <dadler@uni-goettingen.de>,
                            Tassilo Philipp <tphilipp@potion-studios.com>
 
    Permission to use, copy, modify, and distribute this software for any
@@ -25,9 +25,20 @@
 
 
 #include "dyncall_callback.h"
-#include "dyncall_callback_mips.h"
+#include "dyncall_alloc_wx.h"
+#include "dyncall_thunk.h"
+
+/* Callback symbol. */
+extern void dcCallbackThunkEntry();
 
-extern void dcCallbackThunkEntry();
+/* might want to make use of __packed__ or so @@@ */
+struct DCCallback              /*       mips32      |       mips64      */
+{                              /* ------------------+------------------ */
+  DCThunk            thunk;    /* offset  0 size 20 | offset  0 size 56 */
+  DCCallbackHandler* handler;  /* offset 20 size  4 | offset 56 size  8 */
+  void*              userdata; /* offset 24 size  4 | offset 64 size  8 */
+};
+
 
 void dcbInitCallback(DCCallback* pcb, const char* signature, DCCallbackHandler* handler, void* userdata)
 {