summaryrefslogtreecommitdiff
path: root/src/mesa/pipe/cell/spu
diff options
context:
space:
mode:
authorIan Romanick <idr@us.ibm.com>2008-01-25 14:46:43 -0800
committerIan Romanick <idr@us.ibm.com>2008-01-25 14:47:20 -0800
commitbd8bf60b6f2402895e7159a4df644f8a4a307cf5 (patch)
treeb577c4a57a12cedddc8e589211694298abf141b5 /src/mesa/pipe/cell/spu
parent1e0d30a515e4cac891b6c590f12a33e0e8a8e295 (diff)
Work around parameter differences for main in different SDK versions
Diffstat (limited to 'src/mesa/pipe/cell/spu')
-rw-r--r--src/mesa/pipe/cell/spu/spu_main.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/mesa/pipe/cell/spu/spu_main.c b/src/mesa/pipe/cell/spu/spu_main.c
index 880f8de550..2b88c54576 100644
--- a/src/mesa/pipe/cell/spu/spu_main.c
+++ b/src/mesa/pipe/cell/spu/spu_main.c
@@ -616,13 +616,21 @@ one_time_init(void)
}
+/* In some versions of the SDK the SPE main takes 'unsigned long' as a
+ * parameter. In others it takes 'unsigned long long'. Use a define to
+ * select between the two.
+ */
+#ifdef SPU_MAIN_PARAM_LONG_LONG
+typedef unsigned long long main_param_t
+#else
+typedef unsigned long main_param_t
+#endif
+
/**
* SPE entrypoint.
- * Note: example programs declare params as 'unsigned long long' but
- * that doesn't work.
*/
int
-main(unsigned long speid, unsigned long argp)
+main(main_param_t speid, main_param_t argp)
{
int tag = 0;